function linkTestsAndReturnFirst(tests) {
  if (tests && tests.length) {
    for (var index = 0; index < tests.length - 1; ++index) {
      tests[index].setNextTest(tests[index + 1]);
    }
    return tests[0];
  }
  return null;
}
// the first test in the link.
the first test in the link.
the first test in the link .
function linkTestsAndReturnFirst(tests) {
  if (tests && tests.length) {
    for (var index = 0; index < tests.length - 1; ++index) {
      tests[index].setNextTest(tests[index + 1]);
    }
    return tests[0];
  }
  return null;
}
function linkTestsAndReturnFirst ( tests ) { if ( tests && tests . length ) { for ( var index = 0 ; index < tests . length - 1 ; ++ index ) { tests [ index ] . setNextTest ( tests [ index + 1 ] ) ; } return tests [ 0 ] ; } return null ; }
the first test in the link.
the first test in the link .