Closes #7 Added a simple validation package we can expand on. For now we can use it to validate links that get sent to the bot and make sure that: 1. It's an actual url 2. It's a url for a service we support Also added a make file to run tests and other tasks we might need in the future. Added a github action to run tests. Reviewed-on: #19 Co-authored-by: Javier Feliz <me@javierfeliz.com> Co-committed-by: Javier Feliz <me@javierfeliz.com>
21 lines
347 B
YAML
21 lines
347 B
YAML
name: Run Go Tests
|
|
|
|
on:
|
|
pull_request:
|
|
branches: [master]
|
|
|
|
jobs:
|
|
test:
|
|
name: Run Tests
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout Code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v4
|
|
with:
|
|
go-version: '1.22'
|
|
|
|
- name: Run Tests
|
|
run: make test |