Beispiel #1
0
        public async Task CheckAccountAsync()
        {
            var accounts = await accountProvider.AccountsAsync();

            Assert.NotEmpty(accounts);
            Assert.IsType <List <Account> >(accounts);
        }
Beispiel #2
0
        public async Task CheckCreateTechnologyAsync(string nameTech)
        {
            var accounts = await accountProvider.AccountsAsync();

            Account    account    = accounts.FirstOrDefault();
            Technology technology = new Technology
            {
                Name = nameTech
            };

            var created = await technologyProvider.CreateTechnologyAsync(technology, account);

            Assert.NotNull(created);
            Assert.IsType <Technology>(created);
            Assert.True(await technologyProvider.DeleteCreatedTEchnology(created.Id));
            Assert.True(await possibleRoleProvider.DeletePossibleRole(created.PossibleRoles));
            await technologyProvider.RemoveRoleCreated(technology.Roles);
        }
Beispiel #3
0
        public async Task CheckIfAreaisCreated(string nomerArea)
        {
            var accounts = await accountProvider.AccountsAsync();

            Account account = accounts.FirstOrDefault();

            Area area = new Area
            {
                Name = nomerArea,
            };

            var created = await areaProvider.CreateAreaAsync(area, account);

            Assert.NotNull(created);
            Assert.IsType <Area>(created);
            await possibleRoleProvider.DeletePossibleRole(created.PossibleRoles);

            await areaProvider.DeleteCreatedArea(created.Id);

            await areaProvider.RemoveRoleCreated(created.Roles);
        }
Beispiel #4
0
 public Task <ICollection <Account> > AccountsAsync()
 {
     return(provider.AccountsAsync());
 }