dist/tgi-store-json-file.spec.js
function getAlphabetical() {
      try {
        storeBeingTested.getList(test.list, {}, {name: 1}, function (list, error) {
          if (typeof error != 'undefined') {
            callback(error);
            return;
          }
          // Verify each move returns true when move succeeds
          test.shouldBeTrue(list.moveFirst(), 'moveFirst');
          test.shouldBeTrue(!list.movePrevious(), 'movePrevious');
          test.shouldBeTrue(list.get('name') == 'Al Pacino', 'AP');
          test.shouldBeTrue(list.moveLast(), 'moveLast');
          test.shouldBeTrue(!list.moveNext(), 'moveNext');
          test.shouldBeTrue(list.get('name') == 'Tom Hanks', 'TH');
          callback(true);
        });
      }
      catch (err) {
        callback(err);
      }
    }
function getAlphabetical() {
      try {
        storeBeingTested.getList(test.list, {}, {name: 1}, function (list, error) {
          if (typeof error != 'undefined') {
            callback(error);
            return;
          }
          // Verify each move returns true when move succeeds
          test.shouldBeTrue(list.moveFirst(), 'moveFirst');
          test.shouldBeTrue(!list.movePrevious(), 'movePrevious');
          test.shouldBeTrue(list.get('name') == 'Al Pacino', 'AP');
          test.shouldBeTrue(list.moveLast(), 'moveLast');
          test.shouldBeTrue(!list.moveNext(), 'moveNext');
          test.shouldBeTrue(list.get('name') == 'Tom Hanks', 'TH');
          callback(true);
        });
      }
      catch (err) {
        callback(err);
      }
    }
function getAlphabetical ( ) { try { storeBeingTested . getList ( test . list , { } , { name : 1 } , function ( list , error ) { if ( typeof error != 'undefined' ) { callback ( error ) ; return ; } // Verify each move returns true when move succeeds test . shouldBeTrue ( list . moveFirst ( ) , 'moveFirst' ) ; test . shouldBeTrue ( ! list . movePrevious ( ) , 'movePrevious' ) ; test . shouldBeTrue ( list . get ( 'name' ) == 'Al Pacino' , 'AP' ) ; test . shouldBeTrue ( list . moveLast ( ) , 'moveLast' ) ; test . shouldBeTrue ( ! list . moveNext ( ) , 'moveNext' ) ; test . shouldBeTrue ( list . get ( 'name' ) == 'Tom Hanks' , 'TH' ) ; callback ( true ) ; } ) ; } catch ( err ) { callback ( err ) ; } }
Retrieve list alphabetically by name test order parameter
Retrieve list alphabetically by name test order parameter