From 07777f5ff9e0bde26abd0288164e5f73b6da992a Mon Sep 17 00:00:00 2001 From: Chris Date: Wed, 4 Oct 2017 13:09:41 -0700 Subject: Fix races / finally remove global app for good (#7570) * finally remove global app for good * test compilation fixes * fix races * fix deadlock * wake up write pump so it doesn't take forever to clean up --- app/oauth_test.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'app/oauth_test.go') diff --git a/app/oauth_test.go b/app/oauth_test.go index d756c0abe..81f331657 100644 --- a/app/oauth_test.go +++ b/app/oauth_test.go @@ -12,6 +12,8 @@ import ( func TestOAuthRevokeAccessToken(t *testing.T) { th := Setup() + defer th.TearDown() + if err := th.App.RevokeAccessToken(model.NewRandomString(16)); err == nil { t.Fatal("Should have failed bad token") } @@ -46,6 +48,7 @@ func TestOAuthRevokeAccessToken(t *testing.T) { func TestOAuthDeleteApp(t *testing.T) { th := Setup() + defer th.TearDown() oldSetting := utils.Cfg.ServiceSettings.EnableOAuthServiceProvider defer func() { -- cgit v1.2.3-1-g7c22