Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Force MySQL Go test to fail on GitHub workflow if the MySQL test database is not available #107

Merged
merged 1 commit into from
Aug 1, 2024

Conversation

roger2hk
Copy link
Contributor

@roger2hk roger2hk commented Aug 1, 2024

#21

Run go test -v -race ./storage/mysql/... -is_mysql_test_optional=false
  go test -v -race ./storage/mysql/... -is_mysql_test_optional=false
  shell: /usr/bin/bash -e {0}
  env:
    DB_DATABASE: test_tessera
    DB_USER: root
    DB_PASSWORD: root
go: downloading go1.22.5 (linux/amd64)
go: downloading github.com/go-sql-driver/mysql v1.8.1
go: downloading github.com/transparency-dev/merkle v0.0.2
go: downloading k8s.io/klog/v2 v2.130.1
go: downloading github.com/transparency-dev/formats v0.0.0-20240715203801-9ff9b9e3905f
go: downloading golang.org/x/mod v0.19.0
go: downloading github.com/globocom/go-buffer v1.2.2
go: downloading golang.org/x/exp v0.0.0-20220827204233-334a2380cb91
go: downloading golang.org/x/crypto v0.25.0
go: downloading filippo.io/edwards25519 v1.1.0
go: downloading github.com/go-logr/logr v1.4.2
I0801 14:54:00.601791    4259 mysql_test.go:38] Successfully connected to MySQL test database
testing: warning: no tests to run
PASS
ok  	github.com/transparency-dev/trillian-tessera/storage/mysql	1.010s [no tests to run]

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 27.44%. Comparing base (46ec9c2) to head (a616826).
Report is 26 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #107      +/-   ##
==========================================
- Coverage   35.80%   27.44%   -8.37%     
==========================================
  Files          16       19       +3     
  Lines        1363     1771     +408     
==========================================
- Hits          488      486       -2     
- Misses        801     1211     +410     
  Partials       74       74              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@roger2hk roger2hk merged commit 4a6d2c3 into transparency-dev:main Aug 1, 2024
6 checks passed
@roger2hk roger2hk deleted the mysql-github-workflow branch August 1, 2024 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants