function clickDirectoryTreeContextMenuItem(windowId, path, id) {
  return remoteCall.callRemoteTestUtil('focus', windowId,
      [`[full-path-for-testing="${path}"]`]).then(function() {
    // Right click photos directory.
    return remoteCall.callRemoteTestUtil('fakeMouseRightClick', windowId,
        [`[full-path-for-testing="${path}"]`]);
  }).then(function() {
    // Wait for context menu.
    return remoteCall.waitForElement(windowId,
        `#directory-tree-context-menu > [command="#${id}"]:not([disabled])`);
  }).then(function() {
    // Click menu item.
    return remoteCall.callRemoteTestUtil('fakeMouseClick', windowId,
        [`#directory-tree-context-menu > [command="#${id}"]`]);
  });
}
/**
 * Clicks context menu item of id in directory tree.
 */
Clicks context menu item of id in directory tree.
Clicks context menu item of id in directory tree .
function clickDirectoryTreeContextMenuItem(windowId, path, id) {
  return remoteCall.callRemoteTestUtil('focus', windowId,
      [`[full-path-for-testing="${path}"]`]).then(function() {
    return remoteCall.callRemoteTestUtil('fakeMouseRightClick', windowId,
        [`[full-path-for-testing="${path}"]`]);
  }).then(function() {
    return remoteCall.waitForElement(windowId,
        `#directory-tree-context-menu > [command="#${id}"]:not([disabled])`);
  }).then(function() {
    return remoteCall.callRemoteTestUtil('fakeMouseClick', windowId,
        [`#directory-tree-context-menu > [command="#${id}"]`]);
  });
}
function clickDirectoryTreeContextMenuItem ( windowId , path , id ) { return remoteCall . callRemoteTestUtil ( 'focus' , windowId , [ ` ${ path } ` ] ) . then ( function ( ) { return remoteCall . callRemoteTestUtil ( 'fakeMouseRightClick' , windowId , [ ` ${ path } ` ] ) ; } ) . then ( function ( ) { return remoteCall . waitForElement ( windowId , ` ${ id } ` ) ; } ) . then ( function ( ) { return remoteCall . callRemoteTestUtil ( 'fakeMouseClick' , windowId , [ ` ${ id } ` ] ) ; } ) ; }
Clicks context menu item of id in directory tree.
Clicks context menu item of id in directory tree .
// Right click photos directory. // Wait for context menu. // Click menu item.