public void DisposingTwoTimesShouldBeOk() { var query = new CustomQuery <SingleKeyParentTable>(this.Fixture.Connector, this.Fixture.SelectClause); query.Dispose(); query.Dispose(); }
public void DisposingTwoTimesShouldBeOk() { var query = new CustomQuery <SingleKeyParentTable>(Fixture.Connector, Fixture.SelectClause); var result = query.Execute(); query.Dispose(); query.Dispose(); }
public void ShouldNotUseDisposedQueryObject() { var query = new CustomQuery <SingleKeyParentTable>(this.Fixture.Connector, this.Fixture.SelectClause); query.Dispose(); Action executeQuery = () => query.Execute(); executeQuery.ShouldThrow <NullReferenceException>(); }
public void QueryObjectMustBeReutilizable() { var query = new CustomQuery <SingleKeyParentTable>(Fixture.Connector, Fixture.SelectClause); var result = query.Execute(); var result2 = query.Execute(); result.Should().NotBeNull(); result2.Should().NotBeNull(); result2.Should().HaveSameCount(result); query.Dispose(); }