Created
November 21, 2012 23:12
-
-
Save ayoung/4128456 to your computer and use it in GitHub Desktop.
ServiceStack init bug
This file contains 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
[SetUpFixture] | |
public class SetupFixture | |
{ | |
private AppHost _appHost; | |
private static bool _hasInitted; | |
[SetUp] | |
public void StartWebApi() | |
{ | |
if (_appHost == null) | |
{ | |
_appHost = new AppHost(); | |
} | |
if (!_hasInitted) | |
{ | |
_appHost.Init(); | |
_hasInitted = true; | |
} | |
_appHost.Start("http://*:3005/"); | |
} | |
[TearDown] | |
public void StopWebApi() | |
{ | |
_appHost.Stop(); | |
_appHost = null; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment