Implement server invite codes (#37) #335
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Tests (Go) | |
| on: [push, pull_request] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: Set up Go | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version: '1.22.x' | |
| - name: Test CLI | |
| run: go test -v ./cli/... | |
| - name: Set up Docker | |
| uses: docker/setup-buildx-action@master | |
| - name: Start container | |
| run: | | |
| git submodule init | |
| git submodule update | |
| export YEETFILE_ENV_FILE=.tests.env | |
| docker volume create --name=yeetfile_data | |
| docker compose -f docker-compose-tests.yml rm -f | |
| docker compose -f docker-compose-tests.yml pull | |
| docker compose -f docker-compose-tests.yml --env-file .tests.env up --build -d | |
| docker compose -f docker-compose-tests.yml logs | |
| - name: Test API | |
| run: go test -v -tags server_test ./cli/api/... | |
| - name: Inspect logs | |
| if: failure() | |
| run: YEETFILE_ENV_FILE=.tests.env docker compose -f docker-compose-tests.yml logs | |