Esempio n. 1
0
        public static void AssemblyInit(TestContext context)
        {
            if (File.Exists("test.db"))
            {
                File.Delete("test.db");
            }
            var conn   = new TestAppConfig().DatabaseConnectionString;
            var runner = new MigrationRunner(DatabaseType.Sqlite, conn, false, typeof(TestInitializer).Assembly);

            runner.Run();
            BaseControllerTest.Init();
        }
Esempio n. 2
0
        public async Task GetWithInvalidKeyShouldReturnNoEntity()
        {
            HttpResponseMessage response = await Server.CreateRequest(GetUriPath() + "(5)").GetAsync();

            BaseControllerTest <MobileToken> .AssertEmptyResponse(response);
        }
Esempio n. 3
0
        public async Task GetShouldReturnNoElements()
        {
            HttpResponseMessage response = await Server.CreateRequest(GetUriPath()).GetAsync();

            BaseControllerTest <MobileToken> .AssertEmptyResponse(response); //MobileToken controller does not allow this call so it returns an empty list
        }