Forum Xamarin Test Cloud (Read Only)

Setting the Initial set up method

I want a set up method to run once per test fixture. I tried this, but it runs on every test. Is there an attribute for SetUp of the TestFixture or do I have to put it in the constructor?

[SetUp] public void RunBeforeAnyTests() { // TODO: If the iOS app being tested is included in the solution then open // the Unit Tests window, right click Test Apps, select Add App Project // and select the app projects that should be tested. app = ConfigureApp .iOS // TODO: Update this path to point to your iOS app and uncomment the // code if the app is not included in the solution. .AppBundle ("../../../xxx/bin/iPhoneSimulator/Debug/xxx.app") .PreferIdeSettings() .StartApp (Xamarin.UITest.Configuration.AppDataMode.Clear);

Posts

Sign In or Register to comment.