-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
db: functional tests fail if run twice against same DB #265
Labels
Comments
Some steps to reproduce Window 1: $ rkt version
rkt version 0.15.0
appc version 0.7.4
$ sudo rkt run --interactive --net=host quay.io/coreos/postgres
... Window 2: $ ./git-version
09d8d8423cac115cfaf22ffde89c62e46a8f6cc9
$ DEX_TEST_DSN=postgres://postgres@localhost/postgres?sslmode=disable ./test
Running tests...
ok github.com/coreos/dex/connector 0.040s coverage: 22.7% of statements
ok github.com/coreos/dex/db 0.068s coverage: 6.4% of statements
ok github.com/coreos/dex/integration 3.191s coverage: 0.0% of statements
ok github.com/coreos/dex/pkg/crypto 0.008s coverage: 75.7% of statements
ok github.com/coreos/dex/pkg/flag 0.002s coverage: 97.5% of statements
ok github.com/coreos/dex/pkg/http 0.010s coverage: 72.1% of statements
ok github.com/coreos/dex/pkg/net 0.031s coverage: 71.4% of statements
ok github.com/coreos/dex/pkg/time 0.007s coverage: 100.0% of statements
ok github.com/coreos/dex/pkg/html 0.004s coverage: 78.9% of statements
ok github.com/coreos/dex/functional/repo 19.941s coverage: 60.0% of statements
ok github.com/coreos/dex/server 3.730s coverage: 48.3% of statements
ok github.com/coreos/dex/session 0.011s coverage: 75.3% of statements
ok github.com/coreos/dex/user 2.625s coverage: 37.4% of statements
ok github.com/coreos/dex/user/api 0.007s coverage: 82.4% of statements
ok github.com/coreos/dex/user/manager 0.505s coverage: 68.1% of statements
ok github.com/coreos/dex/email 0.004s coverage: 42.8% of statements
Checking gofmt...
Checking govet...
Success
$ DEX_TEST_DSN=postgres://postgres@localhost/postgres?sslmode=disable ./test
Running tests...
ok github.com/coreos/dex/connector 0.027s coverage: 22.7% of statements
ERROR: Failed purging : <nil>
ERROR: Failed purging : <nil>
ERROR: Failed purging : <nil>
ERROR: Failed purging : <nil>
ERROR: Failed purging : <nil>
--- FAIL: TestGetPlannedMigrations (0.09s)
migrate_test.go:40: expected non-empty migrations
FAIL
coverage: 6.4% of statements
FAIL github.com/coreos/dex/db 0.103s
ok github.com/coreos/dex/integration 2.922s coverage: 0.0% of statements
ok github.com/coreos/dex/pkg/crypto 0.012s coverage: 75.7% of statements
ok github.com/coreos/dex/pkg/flag 0.014s coverage: 97.5% of statements
ok github.com/coreos/dex/pkg/http 0.007s coverage: 72.1% of statements
ok github.com/coreos/dex/pkg/net 0.012s coverage: 71.4% of statements
ok github.com/coreos/dex/pkg/time 0.002s coverage: 100.0% of statements
ok github.com/coreos/dex/pkg/html 0.004s coverage: 78.9% of statements
ok github.com/coreos/dex/functional/repo 19.521s coverage: 60.0% of statements
ok github.com/coreos/dex/server 3.493s coverage: 48.3% of statements
ok github.com/coreos/dex/session 0.003s coverage: 75.3% of statements
ok github.com/coreos/dex/user 2.262s coverage: 37.4% of statements
ok github.com/coreos/dex/user/api 0.005s coverage: 82.4% of statements
ok github.com/coreos/dex/user/manager 0.519s coverage: 68.1% of statements
ok github.com/coreos/dex/email 0.005s coverage: 42.8% of statements
$ Restarting the Postgres database fixes the error. |
ericchiang
referenced
this issue
in ericchiang/dex
Mar 1, 2016
closed in #339 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think this has something to do with the migrations table not being dropped.
The text was updated successfully, but these errors were encountered: