function testOpenTaskPicker(callback) {
  window.chrome.fileManagerPrivate.getFileTasks = function(entries, callback) {
    setTimeout(
        callback.bind(
            null,
            [
              {
                taskId: 'handler-extension-id1|app|any',
                isDefault: false,
                isGenericFileHandler: false,
                title: 'app 1',
              },
              {
                taskId: 'handler-extension-id2|app|any',
                isDefault: false,
                isGenericFileHandler: false,
                title: 'app 2',
              }
            ]),
        0);
  };

  var mockFileSystem = new MockFileSystem('volumeId');
  var mockEntry = new MockFileEntry(mockFileSystem, '/test.tiff');

  reportPromise(
      showDefaultTaskDialogCalled([mockEntry], ['image/tiff']), callback);
}
/**
 * Test case for opening task picker with an entry which doesn't have default
 * app but multiple apps that can open it.
 */
Test case for opening task picker with an entry which doesn't have default
app but multiple apps that can open it.
Test case for opening task picker with an entry which doesn ' t have default app but multiple apps that can open it .
function testOpenTaskPicker(callback) {
  window.chrome.fileManagerPrivate.getFileTasks = function(entries, callback) {
    setTimeout(
        callback.bind(
            null,
            [
              {
                taskId: 'handler-extension-id1|app|any',
                isDefault: false,
                isGenericFileHandler: false,
                title: 'app 1',
              },
              {
                taskId: 'handler-extension-id2|app|any',
                isDefault: false,
                isGenericFileHandler: false,
                title: 'app 2',
              }
            ]),
        0);
  };
  var mockFileSystem = new MockFileSystem('volumeId');
  var mockEntry = new MockFileEntry(mockFileSystem, '/test.tiff');
  reportPromise(
      showDefaultTaskDialogCalled([mockEntry], ['image/tiff']), callback);
}
function testOpenTaskPicker ( callback ) { window . chrome . fileManagerPrivate . getFileTasks = function ( entries , callback ) { setTimeout ( callback . bind ( null , [ { taskId : 'handler-extension-id1|app|any' , isDefault : false , isGenericFileHandler : false , title : 'app 1' , } , { taskId : 'handler-extension-id2|app|any' , isDefault : false , isGenericFileHandler : false , title : 'app 2' , } ] ) , 0 ) ; } ; var mockFileSystem = new MockFileSystem ( 'volumeId' ) ; var mockEntry = new MockFileEntry ( mockFileSystem , '/test.tiff' ) ; reportPromise ( showDefaultTaskDialogCalled ( [ mockEntry ] , [ 'image/tiff' ] ) , callback ) ; }
Test case for opening task picker with an entry which doesn't have default
 app but multiple apps that can open it.
Test case for opening task picker with an entry which doesn ' t have default app but multiple apps that can open it .