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

go tests failing on develop #401

Open
colin-axner opened this issue Oct 9, 2020 · 2 comments
Open

go tests failing on develop #401

colin-axner opened this issue Oct 9, 2020 · 2 comments

Comments

@colin-axner
Copy link
Contributor

on latest develop, if I run:

go test
ERROR: 2020/10/09 16:43:21 oauth.go:148: viewOauthInit error: pretend unable to write state error
--- FAIL: TestViewOauthCallback (0.00s)
    --- FAIL: TestViewOauthCallback/success (0.00s)
        oauth_test.go:248: 
            	Error Trace:	oauth_test.go:248
            	Error:      	Received unexpected error:
            	            	/login
            	Test:       	TestViewOauthCallback/success
        oauth_test.go:249: 
            	Error Trace:	oauth_test.go:249
            	Error:      	Not equal: 
            	            	expected: 307
            	            	actual  : 200
            	Test:       	TestViewOauthCallback/success
2020/10/09 16:43:21 Loading testdata/config.ini configuration...
--- FAIL: TestUpdatesRoundTrip (1.09s)
    --- FAIL: TestUpdatesRoundTrip/Release_URL (0.00s)
        updates_test.go:36: Malformed Release URL: https://blog.writefreely.org/version-
FAIL
exit status 1
FAIL	github.com/writeas/writefreely	1.104s
@tokudan
Copy link

tokudan commented Oct 10, 2020

fails on 0.12 as well, not sure if it's related, as the error is different, but the location is similar.

running tests
=== RUN   TestUnmarshalActor
--- PASS: TestUnmarshalActor (0.00s)
=== RUN   TestOAuthDatastore
    database_test.go:12: skipping mysql tests
--- SKIP: TestOAuthDatastore (0.00s)
=== RUN   TestViewOauthInit
=== RUN   TestViewOauthInit/success
=== RUN   TestViewOauthInit/state_failure
ERROR: 2020/10/09 23:56:51 oauth.go:140: viewOauthInit error: pretend unable to write state error
--- PASS: TestViewOauthInit (0.00s)
    --- PASS: TestViewOauthInit/success (0.00s)
    --- PASS: TestViewOauthInit/state_failure (0.00s)
=== RUN   TestViewOauthCallback
=== RUN   TestViewOauthCallback/success
--- FAIL: TestViewOauthCallback (0.00s)
    --- FAIL: TestViewOauthCallback/success (0.00s)
panic: runtime error: invalid memory address or nil pointer dereference [recovered]
        panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x18 pc=0x95e3f1]

goroutine 11 [running]:
testing.tRunner.func1.1(0xa9eae0, 0xf12e50)
        /nix/store/jzbmhayw9vyizvf9q9kjlvpyfsb006zl-go-1.15.2/share/go/src/testing/testing.go:1076 +0x30d
testing.tRunner.func1(0xc000503080)
        /nix/store/jzbmhayw9vyizvf9q9kjlvpyfsb006zl-go-1.15.2/share/go/src/testing/testing.go:1079 +0x41a
panic(0xa9eae0, 0xf12e50)
        /nix/store/jzbmhayw9vyizvf9q9kjlvpyfsb006zl-go-1.15.2/share/go/src/runtime/panic.go:969 +0x175
github.com/writeas/writefreely.oauthHandler.viewOauthCallback(0xc00025e600, 0xc1f300, 0xc000211800, 0xc1ae20, 0xc00000f440, 0xc0000a6ec0, 0x9, 0x9, 0xc1fea0, 0xc0001ab650, ...)
        /build/source/oauth.go:324 +0x791
github.com/writeas/writefreely.TestViewOauthCallback.func1(0xc000503080)
        /build/source/oauth_test.go:247 +0x4ff
testing.tRunner(0xc000503080, 0xb907e8)
        /nix/store/jzbmhayw9vyizvf9q9kjlvpyfsb006zl-go-1.15.2/share/go/src/testing/testing.go:1127 +0xef
created by testing.(*T).Run
        /nix/store/jzbmhayw9vyizvf9q9kjlvpyfsb006zl-go-1.15.2/share/go/src/testing/testing.go:1178 +0x386
FAIL    github.com/writeas/writefreely  0.057s
FAIL

@thebaer
Copy link
Member

thebaer commented Oct 11, 2020

Thanks for the report -- if anyone is interested in fixing these tests, please feel free!

@colin-axner colin-axner mentioned this issue Oct 26, 2020
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants