public void MockDbDataAdapterShouldThrowArgumentNullExceptionIfArgumentsNull() { MockDbDataAdapter sut; //Delegate - Rogzitem a muveletet< Action act = () => sut = new MockDbDataAdapter(null); act.Should().Throw <ArgumentNullException>(); }
public void MockDbDataAdapterShouldThrowArgumentNullExceptionIfFillMethodsArgumentsNull() { var sut = new MockDbDataAdapter(MockDataTableFactory.CreateDataTable()); //Delegate - Rogzitem a muveletet< Action act = () => sut.Fill(null); act.Should().Throw <ArgumentNullException>(); }
public void MockDbDataAdapterShouldReturnTable() { var sut = new MockDbDataAdapter(MockDataTableFactory.CreateDataTable()); var dataSet = new DataSet(); //Delegate - Rogzitem a muveletet< sut.Fill(dataSet); dataSet.Tables.Should().HaveCount(1); }
public void AddressDbDataAdapterRepositoryShouldReturnMockData() { var adapter = new MockDbDataAdapter(MockDataTableFactory.CreateDataTable()); var sut = new AddressDbDataAdapterRepository(adapter); var list = sut.GetAddresses(); list.Should().HaveCount(1, "Egy elemunk van a repoban") .And.Should().Equals(new Address { Email = GlobalStrings.TestEmailAddress }); }