anchor.diff:   * BSD-style license that can be found in the LICENSE file.
    */
   /**
  - * @assertion final Future<int> length
  - * Counts the elements in the stream. 
  + * @assertion Future<int> length
  + * Counts the elements in the stream.
    * @description Checks that correct number of elements is returned.
    * @author kaigorodov
    */
  
positive.code: import "../../../Utils/expect.dart";
  
  check(Iterable<int> data, int expected) {
    Stream s=new Stream.fromIterable(data);
    asyncStart();
    s.length.then((value){
      Expect.equals(expected, value);
      asyncEnd();
    });
  
negative.code: 
  main() {
    check([], 0);
    check([1, 2, 3, null], 4);
    check(new Iterable.generate(0, (int index) => index * 2), 0);
    check(new Iterable.generate(10, (int index) => index * 2), 10);
  }
  