Exemplo n.º 1
0
        public async Task CreateClasses_SendsInstructorsForSavingAsync()
        {
            //Given
            SaverStub           saverStub = new SaverStub();
            DataCreationUseCase useCase   = GetUseCase(saverStub);
            //When
            await useCase.CreateClassesAsync();

            //Then
            Assert.Equal(4, saverStub.Instructors.Count);
        }
Exemplo n.º 2
0
        public async Task CreateClasses_PersistsCreatedAssistantsAsync()
        {
            //Given
            SaverStub           saverStub = new SaverStub();
            DataCreationUseCase useCase   = GetUseCase(saverStub);
            //When
            await useCase.CreateClassesAsync();

            //Then
            Assert.Equal(8, saverStub.Assistants.Count);
        }
Exemplo n.º 3
0
        public async Task CreateClasses_CreatesDataStoreAsync()
        {
            //Given
            SaverStub           saverStub = new SaverStub();
            DataCreationUseCase useCase   = GetUseCase(saverStub);
            //When
            await useCase.CreateClassesAsync();

            //Then
            Assert.True(saverStub.DataSourceWasCreated);
        }
Exemplo n.º 4
0
        public async Task CreateClasses_PersistsCreatedEllCoachesAsync()
        {
            //Given
            SaverStub           saverStub = new SaverStub();
            DataCreationUseCase useCase   = GetUseCase(saverStub);
            //When
            await useCase.CreateClassesAsync();

            //Then
            Assert.Single(saverStub.EllCoaches);
        }