public void ShouldCheckIfDoesNotContain(DbItem item, DbItemChildCollection sut)
    {
      // act
      var result = sut.Contains(item);

      // assert
      result.Should().BeFalse();
    }
Exemplo n.º 2
0
        public void ShouldCopyTo([Frozen] DbItem item, [Greedy] DbItemChildCollection sut)
        {
            var array = new DbItem[3];

            sut.CopyTo(array, 0);

            array.Should().Contain(item);
        }
    public void ShouldAdd(DbItem item, DbItemChildCollection sut)
    {
      // act
      sut.Add(item);

      // assert
      sut.Count.Should().Be(1);
    }
    public void ShouldClear(DbItemChildCollection sut)
    {
      // act
      sut.Clear();

      // assert
      sut.Count.Should().Be(0);
    }
    public void ShouldCheckIfReadonly([Frozen] DbItem parent, ReadOnlyCollection<DbItem> items)
    {
      // arrange
      var sut = new DbItemChildCollection(parent, items);

      // act
      var result = sut.IsReadOnly;

      // assert
      result.Should().BeTrue();
    }
 public void ShouldCheckIfReadonly(DbItem parent, ReadOnlyCollection<DbItem> items)
 {
   var sut = new DbItemChildCollection(parent, items);
   sut.IsReadOnly.Should().BeTrue();
 }
 public void ShouldCheckIfDoesNotContain(DbItem item, DbItemChildCollection sut)
 {
   sut.Contains(item).Should().BeFalse();
 }
 public void ShouldClear(DbItemChildCollection sut)
 {
   sut.Clear();
   sut.Count.Should().Be(0);
 }
 public void ShouldAdd(DbItem item, DbItemChildCollection sut)
 {
   sut.Add(item);
   sut.Count.Should().Be(1);
 }
Exemplo n.º 10
0
 public void ShouldGetEnumerator(DbItemChildCollection sut)
 {
     ((IEnumerable)sut).GetEnumerator().Should().NotBeNull();
 }
Exemplo n.º 11
0
 public void ShouldCheckIfNotReadonly(DbItemChildCollection sut)
 {
     sut.IsReadOnly.Should().BeFalse();
 }
Exemplo n.º 12
0
        public void ShouldCheckIfReadonly(DbItem parent, ReadOnlyCollection <DbItem> items)
        {
            var sut = new DbItemChildCollection(parent, items);

            sut.IsReadOnly.Should().BeTrue();
        }
 public void ShouldCheckIfNotReadonly(DbItemChildCollection sut)
 {
   sut.IsReadOnly.Should().BeFalse();
 }
Exemplo n.º 14
0
 public void ShouldCheckIfContains([Frozen] DbItem item, [Greedy] DbItemChildCollection sut)
 {
     sut.Contains(item).Should().BeTrue();
 }
Exemplo n.º 15
0
 public void ShouldCheckIfDoesNotContain(DbItem item, DbItemChildCollection sut)
 {
     sut.Contains(item).Should().BeFalse();
 }
Exemplo n.º 16
0
 public void ShouldClear(DbItemChildCollection sut)
 {
     sut.Clear();
     sut.Count.Should().Be(0);
 }
Exemplo n.º 17
0
 public void ShouldAdd(DbItem item, DbItemChildCollection sut)
 {
     sut.Add(item);
     sut.Count.Should().Be(1);
 }
    public void ShouldCheckIfNotReadonly(DbItemChildCollection sut)
    {
      // act
      var result = sut.IsReadOnly;

      // assert
      result.Should().BeFalse();
    }
 public void ShouldGetEnumerator(DbItemChildCollection sut)
 {
   ((IEnumerable)sut).GetEnumerator().Should().NotBeNull();
 }
Exemplo n.º 20
0
 public void ShouldRemove([Frozen] DbItem item, [Greedy] DbItemChildCollection sut)
 {
     sut.Remove(item);
     sut.Count.Should().Be(2);
 }