[arvados-workbench2] updated: 2.4.0-160-g6aa9f73f

git repository hosting git at public.arvados.org
Wed Jul 27 18:12:48 UTC 2022


Summary of changes:
 cypress/integration/search.spec.js | 48 +++++++++++++++++++++++++++++++++++++-
 tools/run-integration-tests.sh     |  1 +
 2 files changed, 48 insertions(+), 1 deletion(-)

       via  6aa9f73fef64bbca1e3b71eb526946d69d014246 (commit)
      from  7eb16e136a720bdfda5a4d4782d9cce1d00f5ded (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 6aa9f73fef64bbca1e3b71eb526946d69d014246
Author: Stephen Smith <stephen at curii.com>
Date:   Wed Jul 27 14:12:34 2022 -0400

    19079: Add test for search context menu
    
    Arvados-DCO-1.1-Signed-off-by: Stephen Smith <stephen at curii.com>

diff --git a/cypress/integration/search.spec.js b/cypress/integration/search.spec.js
index 5434ca24..6f880e7f 100644
--- a/cypress/integration/search.spec.js
+++ b/cypress/integration/search.spec.js
@@ -126,4 +126,50 @@ describe('Search tests', function() {
                 });
         });
     });
-});
\ No newline at end of file
+
+    it.only('shows search context menu', function() {
+        const colName = `Collection ${Math.floor(Math.random() * Math.floor(999999))}`;
+
+        cy.createCollection(adminUser.token, {
+            name: colName,
+            owner_uuid: activeUser.user.uuid,
+            preserve_version: true,
+            manifest_text: ". 37b51d194a7513e45b56f6524f2d51f2+3 0:3:bar\n"
+        }).then(function(testCollection) {
+            cy.loginAs(activeUser);
+
+            cy.doSearch(colName);
+
+            // Stub new window
+            cy.window().then(win => {
+                cy.stub(win, 'open').as('Open')
+            });
+
+            cy.get('[data-cy=search-results]').contains(colName).rightclick();
+            cy.get('[data-cy=context-menu]').within((ctx) => {
+                // Check that there are 4 items in the menu
+                cy.get(ctx).children().should('have.length', 4);
+                cy.contains('Advanced');
+                cy.contains('Copy to clipboard');
+                cy.contains('Open in new tab');
+                cy.contains('View details');
+
+                cy.contains('Copy to clipboard').click();
+                cy.window().then((win) => {
+                    win.navigator.clipboard.readText().then((text) => {
+                        expect(text).to.endWith(`/collections/${testCollection.uuid}`);
+                    });
+                });
+
+            });
+
+
+            cy.get('[data-cy=search-results]').contains(colName).rightclick();
+            cy.get('[data-cy=context-menu]').within((ctx) => {
+                cy.contains('Open in new tab').click();
+                cy.get('@Open').should('have.been.calledOnceWith', `${window.location.origin}/collections/${testCollection.uuid}`)
+            });
+
+        });
+    });
+});
diff --git a/tools/run-integration-tests.sh b/tools/run-integration-tests.sh
index 0a9a0fc4..367ccecd 100755
--- a/tools/run-integration-tests.sh
+++ b/tools/run-integration-tests.sh
@@ -114,6 +114,7 @@ coproc arvboot (~/go/bin/arvados-server boot \
     -type test \
     -config ${TMPDIR}/arvados.yml \
     -no-workbench1 \
+    -no-workbench2 \
     -own-temporary-database \
     -timeout 20m 2> ${ARVADOS_LOG})
 trap cleanup ERR EXIT

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list