graphdb-workbench-tests 3.4.0-TR2 → 3.4.0-TR4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Dockerfile +11 -0
- package/cypress-flaky.config.js +6 -20
- package/cypress.config.js +6 -45
- package/fixtures/locale-en.json +3342 -0
- package/fixtures/ttyg/agent/get-agent-defaults.json +2 -9
- package/fixtures/ttyg/chats/ask-question.json +2 -12
- package/fixtures/ttyg/chats/create/create-chat-response.json +14 -10
- package/fixtures/ttyg/chats/explain-response-1.json +48 -2
- package/fixtures/ttyg/chats/get-chat.json +1 -6
- package/{e2e-legacy → integration}/cluster/cluster-states.spec.js +3 -3
- package/{e2e-legacy/explore/class-hierarchy → integration/explore}/class.hierarchy.spec.js +1 -1
- package/{e2e-legacy/explore/class-relationships/class-relationships.spec.js → integration/explore/class.relationships.spec.js} +50 -20
- package/{e2e-legacy/explore/graphs-overview → integration/explore}/graphs.overview.spec.js +4 -4
- package/integration/explore/similarity-index/similarity-index-create.spec.js +333 -0
- package/integration/explore/similarity-index/similarity-index.spec.js +88 -0
- package/integration/explore/similarity-index/similarity.spec.js +628 -0
- package/{e2e-legacy → integration}/explore/visual-graph/graphs-config.spec.js +10 -5
- package/{e2e-legacy → integration}/explore/visual-graph/visual-graph-node-labels.spec.js +2 -14
- package/{e2e-legacy → integration}/explore/visual-graph/visual.graph.spec.js +96 -75
- package/{e2e-legacy → integration}/graphql/create-graphql-endpoint.spec.js +2 -0
- package/{e2e-legacy → integration}/graphql/edit-graphql-enpoint.spec.js +1 -1
- package/{e2e-legacy → integration}/graphql/filter-graphql-endpoints-on-management-view.spec.js +1 -1
- package/{e2e-legacy → integration}/graphql/graphql-endpoint-management-view.spec.js +4 -4
- package/{e2e-legacy → integration}/graphql/graphql-playground.spec.js +1 -1
- package/{e2e-legacy → integration}/graphql/import-graphql-endpoint-definitions.spec.js +6 -0
- package/integration/guides/movies-interactive-guide.spec.js +73 -0
- package/{e2e-legacy/help/guides/star-wars-interactive-guide.spec.js → integration/guides/star-wars-interactive-guide.js} +2 -3
- package/integration/home/cookie-policy.spec.js +90 -0
- package/integration/home/documentation-link.spec.js +60 -0
- package/{e2e-legacy → integration}/home/google-analytics.spec.js +6 -4
- package/{e2e-legacy → integration}/home/language-change.spec.js +2 -2
- package/integration/home/language-selector.spec.js +19 -0
- package/integration/home/rdf-resource-search.spec.js +177 -0
- package/integration/home/view-resource-autocomplete.spec.js +52 -0
- package/integration/home/workbench.home.spec.js +30 -0
- package/{e2e-legacy → integration}/import/import-server-files.spec.js +3 -5
- package/{e2e-legacy → integration}/import/import-user-data-file-upload.spec.js +13 -19
- package/{e2e-legacy → integration}/import/import-user-data-text-snippet.spec.js +2 -0
- package/{e2e-legacy → integration}/import/import-user-data-url.spec.js +23 -0
- package/{e2e-legacy → integration}/import/import-user-data.spec.js +4 -11
- package/{e2e-legacy → integration}/license/license.spec.js +4 -4
- package/{e2e-legacy → integration}/monitor/global-operation-statuses-component.spec.js +5 -12
- package/{e2e-legacy/monitor/backup-and-restore/backup-and-restore.spec.js → integration/monitor/monitor.backup-and-restore.spec.js} +2 -2
- package/integration/monitor/monitor.queries.spec.js +31 -0
- package/{e2e-legacy/monitor/system → integration/monitor}/monitor.resources.spec.js +2 -3
- package/{e2e-legacy → integration}/repository/ontop-repository.spec.js +1 -1
- package/{e2e-legacy → integration}/repository/repositories.spec.js +45 -37
- package/{e2e-legacy → integration}/resource/resource.spec.js +7 -17
- package/{e2e-legacy → integration}/setup/aclmanagement/create-rule.spec.js +0 -4
- package/{e2e-legacy/setup/autocomplete → integration/setup}/autocomplete.spec.js +7 -6
- package/{e2e-legacy → integration}/setup/connectors-lucene.spec.js +10 -26
- package/{e2e-legacy → integration}/setup/jdbc/jdbc-create.spec.js +4 -4
- package/integration/setup/my-settings.spec.js +289 -0
- package/{e2e-legacy/setup/namespaces → integration/setup}/namespaces.spec.js +5 -6
- package/{e2e-legacy/setup/plugins → integration/setup}/plugins.spec.js +3 -3
- package/{e2e-legacy/setup/rdf-rank → integration/setup}/rdf-rank.spec.js +5 -3
- package/{e2e-legacy/setup/sparql-template/sparql-template-create.spec.js → integration/setup/sparql-template-create.js} +8 -16
- package/{e2e-legacy/setup/sparql-template → integration/setup}/sparql-templates.spec.js +4 -4
- package/{e2e-legacy/setup/users-and-access → integration/setup}/user-and-access.spec.js +87 -184
- package/{e2e-legacy → integration}/sparql-editor/actions/expand-results-over-sameas.spec.js +12 -12
- package/{e2e-legacy → integration}/sparql-editor/actions/include-inferred-statements.spec.js +6 -6
- package/{e2e-legacy → integration}/sparql-editor/actions/inferred-sameas.spec.js +8 -10
- package/{e2e-legacy → integration}/sparql-editor/actions/show-saved-queries.spec.js +6 -1
- package/{e2e-legacy → integration}/sparql-editor/saved-query/abort-query.spec.js +1 -1
- package/{e2e-legacy → integration}/sparql-editor/saved-query/edit-query.spec.js +3 -3
- package/{e2e-legacy → integration}/sparql-editor/saved-query/readonly-query.spec.js +24 -15
- package/{e2e-legacy → integration}/sparql-editor/saved-query/share-query.spec.js +1 -32
- package/{e2e-legacy → integration}/sparql-editor/yasgui-tabs.spec.js +12 -2
- package/{e2e-legacy → integration}/sparql-editor/yasr/pagination.spec.js +18 -5
- package/{e2e-legacy → integration}/sparql-editor/yasr/table-plugin.spec.js +6 -1
- package/integration/sparql-editor/yasr/toolbar/visual-graph-button.spec.js +57 -0
- package/{e2e-legacy → integration}/ttyg/agent-list.spec.js +2 -53
- package/{e2e-legacy → integration}/ttyg/agent-select-menu.spec.js +2 -25
- package/{e2e-legacy → integration}/ttyg/chat-list.spec.js +14 -3
- package/{e2e-legacy → integration}/ttyg/chat-panel.spec.js +6 -74
- package/{e2e-legacy → integration}/ttyg/clone-agent.spec.js +2 -24
- package/{e2e-legacy → integration}/ttyg/create-agent.spec.js +66 -37
- package/{e2e-legacy → integration}/ttyg/create-chat.spec.js +4 -6
- package/{e2e-legacy → integration}/ttyg/delete-agent.spec.js +2 -1
- package/integration/ttyg/edit-agent.spec.js +99 -0
- package/{e2e-legacy → integration}/ttyg/ttyg-view.spec.js +2 -2
- package/{e2e-flaky → integration-flaky}/explore/visual.graph.spec.js +1 -4
- package/{e2e-flaky → integration-flaky}/import/import-server-files-operations.spec.js +2 -2
- package/{e2e-flaky → integration-flaky}/import/import-user-data-batch-operations.spec.js +3 -3
- package/{e2e-flaky → integration-flaky}/setup/sparql-template-create.js +18 -10
- package/integration-flaky/setup/users-and-access/security-and-free-access.spec.js +54 -0
- package/{e2e-flaky → integration-flaky}/sparql-editor/actions/execute-update-query.spec.js +12 -2
- package/{e2e-flaky → integration-flaky}/sparql-editor/actions/share-query.spec.js +7 -1
- package/{e2e-flaky → integration-flaky}/sparql-editor/yasr/table-plugin.spec.js +7 -3
- package/{e2e-legacy → integration-flaky}/ttyg/ttyg-permission.spec.js +17 -23
- package/npm-shrinkwrap.json +3815 -11004
- package/package.json +42 -58
- package/plugins/index.js +5 -10
- package/steps/application-steps.js +6 -8
- package/steps/class-views-steps.js +7 -35
- package/steps/cluster/cluster-page-steps.js +2 -12
- package/steps/error-steps.js +3 -15
- package/steps/explore/graphs-overview-steps.js +1 -21
- package/steps/explore/similarity-index-create-steps.js +3 -5
- package/steps/explore/similarity-indexes-steps.js +2 -16
- package/steps/graphql/graphql-endpoint-management-steps.js +2 -2
- package/steps/guides/guide-dialog-steps.js +2 -81
- package/steps/guides/guide-steps.js +2 -54
- package/steps/home-steps.js +77 -184
- package/steps/import/import-resource-message-dialog.js +1 -1
- package/steps/import/import-steps.js +16 -12
- package/steps/import/import-user-data-steps.js +1 -5
- package/steps/language-selector-steps.js +2 -2
- package/steps/license-steps.js +9 -91
- package/steps/login-steps.js +6 -31
- package/steps/main-menu-steps.js +19 -244
- package/steps/modal-dialog-steps.js +1 -32
- package/steps/monitoring/backup-and-restore-steps.js +3 -9
- package/steps/operations-statuses-component-steps.js +10 -5
- package/steps/repository-selector-steps.js +3 -3
- package/steps/repository-steps.js +18 -64
- package/steps/resource/resource-steps.js +2 -6
- package/steps/setup/acl-management-steps.js +2 -6
- package/steps/setup/autocomplete-steps.js +8 -23
- package/steps/setup/jdbc-steps.js +4 -18
- package/steps/setup/namespace-steps.js +7 -10
- package/steps/setup/plugins-steps.js +5 -12
- package/steps/setup/rdf-rank-steps.js +9 -23
- package/steps/setup/settings-steps.js +2 -101
- package/steps/setup/sparql-templates-steps.js +1 -19
- package/steps/setup/user-and-access-steps.js +16 -50
- package/steps/sparql-editor-steps.js +2 -8
- package/steps/sparql-steps.js +1 -13
- package/steps/toaster-steps.js +6 -18
- package/steps/ttyg/chat-panel-steps.js +2 -40
- package/steps/ttyg/ttyg-agent-settings-modal.steps.js +31 -136
- package/steps/ttyg/ttyg-view-steps.js +10 -80
- package/steps/visual-graph-steps.js +10 -106
- package/steps/yasgui/yasgui-loader.js +3 -3
- package/steps/yasgui/yasgui-steps.js +1 -1
- package/steps/yasgui/yasqe-steps.js +4 -35
- package/steps/yasgui/yasr-steps.js +3 -73
- package/stubs/autocomplete/autocomplete-stubs.js +0 -7
- package/stubs/environment-stubs.js +1 -9
- package/stubs/license-stubs.js +0 -51
- package/stubs/repositories/repositories-stubs.js +75 -180
- package/stubs/repositories-stub.js +73 -0
- package/stubs/security-stubs.js +0 -12
- package/stubs/similarity-index-stubs.js +0 -4
- package/stubs/ttyg/ttyg-stubs.js +15 -64
- package/stubs/yasgui/query-stubs.js +1 -5
- package/support/commands.js +1 -22
- package/support/{e2e.js → index.js} +3 -9
- package/support/repository-commands.js +4 -29
- package/support/settings-commands.js +1 -33
- package/support/user-commands.js +4 -9
- package/utils/html-util.js +4 -24
- package/.editorconfig +0 -17
- package/.nycrc +0 -10
- package/cypress-legacy.config.js +0 -47
- package/cypress-security.config.js +0 -36
- package/e2e-flaky/import/import-user-data-url.spec.js +0 -63
- package/e2e-legacy/explore/class-hierarchy/class-hierarchy-with-selected-repository-without-class-hierarchy.spec.js +0 -42
- package/e2e-legacy/explore/class-hierarchy/class-hierarchy-with-selected-repository.spec.js +0 -43
- package/e2e-legacy/explore/class-hierarchy/class-hierarchy-without-selected-repository.spec.js +0 -30
- package/e2e-legacy/explore/class-relationships/class-relationships-repository-with-data.spec.js +0 -42
- package/e2e-legacy/explore/class-relationships/class-relationships-with-selected-repository.spec.js +0 -39
- package/e2e-legacy/explore/class-relationships/class-relationships-without-selected-repository.spec.js +0 -21
- package/e2e-legacy/explore/graphs-overview/initial-state/graphs-overview-with-selected-repository.spec.js +0 -44
- package/e2e-legacy/explore/graphs-overview/initial-state/graphs-overview-without-selected-repository.spec.js +0 -32
- package/e2e-legacy/explore/similarity-index/similarity-index-with-repository.spec.js +0 -38
- package/e2e-legacy/explore/similarity-index/similarity-index-without-repository.spec.js +0 -21
- package/e2e-legacy/explore/visual-graph/node-info-panel.spec.js +0 -58
- package/e2e-legacy/explore/visual-graph/visual-graph-links-limit.spec.js +0 -140
- package/e2e-legacy/explore/visual-graph/visual-graph-with-selected-repository.js +0 -38
- package/e2e-legacy/explore/visual-graph/visual-graph-without-selected-repository.js +0 -21
- package/e2e-legacy/graphql/graphql-endpoint-management-with-endpoints.spec.js +0 -43
- package/e2e-legacy/graphql/graphql-endpoint-management-with-selected-repository.spec.js +0 -39
- package/e2e-legacy/graphql/graphql-endpoint-management-without-selected-repository.spec.js +0 -21
- package/e2e-legacy/graphql/graphql-playground-with-endpoints.spec.js +0 -40
- package/e2e-legacy/graphql/graphql-playground-with-selected-repository.spec.js +0 -38
- package/e2e-legacy/graphql/graphql-playground-without-selected-repository.spec.js +0 -22
- package/e2e-legacy/graphql/graphql-theme.spec.js +0 -73
- package/e2e-legacy/guides/autocomplete/enable-autocomplete-guide.spec.js +0 -49
- package/e2e-legacy/guides/class-hierarcy/class-hierarchy-guide.spec.js +0 -89
- package/e2e-legacy/guides/class-relations/class-relations-guide.spec.js +0 -76
- package/e2e-legacy/guides/connectors/connectors-guide.spec.js +0 -163
- package/e2e-legacy/guides/create-similarity-index/create-similarity-index-guide.spec.js +0 -74
- package/e2e-legacy/guides/download-guide-resource/download-guide-resource-guide.js +0 -55
- package/e2e-legacy/guides/execute-sparql-query/execute-sparql-query-guide.spec.js +0 -92
- package/e2e-legacy/guides/import-rdf-file/confirm-duplicate-rdf-file.spec.js +0 -63
- package/e2e-legacy/guides/import-rdf-file/import-rdf-file.spec.js +0 -105
- package/e2e-legacy/guides/main-menu/main-menu-guide.spec.js +0 -302
- package/e2e-legacy/guides/navigation/navigation-guide.spec.js +0 -64
- package/e2e-legacy/guides/rdf-rank/rdf-rank-guide.spec.js +0 -42
- package/e2e-legacy/guides/repositories/create-repository-guide.spec.js +0 -69
- package/e2e-legacy/guides/table-graph-explore/table-graph-explore-guide.spec.js +0 -167
- package/e2e-legacy/guides/ttyg/configure-agent/configure-agent-guide.spec.js +0 -157
- package/e2e-legacy/guides/ttyg/conversation/ttyg-conversation-guide.spec.js +0 -92
- package/e2e-legacy/guides/ttyg/edit-agent/edit-ttyg-agent-guide.spec.js +0 -88
- package/e2e-legacy/guides/visual-graph/visual-graph-guide.spec.js +0 -372
- package/e2e-legacy/guides/welcome/welcome-guide.spec.js +0 -36
- package/e2e-legacy/help/guides/guides-autostart.spec.js +0 -126
- package/e2e-legacy/help/guides/guides-confirm-cancel-dialog.js +0 -83
- package/e2e-legacy/help/guides/guides-with-repository.spec.js +0 -32
- package/e2e-legacy/help/guides/guides-without-repository.spec.js +0 -20
- package/e2e-legacy/help/guides/movies-interactive-guide.spec.js +0 -71
- package/e2e-legacy/help/rest-api-documentatio/rest-api-documentation-with-repository.spec.js +0 -32
- package/e2e-legacy/help/rest-api-documentatio/rest-api-documentation-without-repository.spec.js +0 -20
- package/e2e-legacy/help/system-information/system-information-with-repository.spec.js +0 -32
- package/e2e-legacy/help/system-information/system-information-without-repository.spec.js +0 -20
- package/e2e-legacy/home/cookie-policy/cookie-policy.spec.js +0 -182
- package/e2e-legacy/home/documentation-link.spec.js +0 -41
- package/e2e-legacy/home/home-page-with-selected-repository.spec.js +0 -69
- package/e2e-legacy/home/home-page-without-repositories.spec.js +0 -87
- package/e2e-legacy/home/home-page-without-selected-repository.spec.js +0 -59
- package/e2e-legacy/home/rdf-resource-search.spec.js +0 -160
- package/e2e-legacy/home/view-resource-autocomplete.spec.js +0 -65
- package/e2e-legacy/import/initial-state/import-page-with-selected-repositor.js +0 -51
- package/e2e-legacy/import/initial-state/import-page-with-selected-repository-without-imported-files.js +0 -45
- package/e2e-legacy/import/initial-state/import-page-without-selected-repository.spec.js +0 -28
- package/e2e-legacy/license/license-with-repository.spec.js +0 -113
- package/e2e-legacy/license/license-without-repository.spec.js +0 -103
- package/e2e-legacy/monitor/backup-and-restore/backup-and-restore-with-repository.spec.js +0 -36
- package/e2e-legacy/monitor/backup-and-restore/backup-and-restore-without-repository.spec.js +0 -25
- package/e2e-legacy/monitor/query-and-updates/queries-and-updates-with-repository.spec.js +0 -39
- package/e2e-legacy/monitor/query-and-updates/queries-and-updates-without-repository.spec.js +0 -21
- package/e2e-legacy/monitor/system/system-monitoring-with-repository.spec.js +0 -32
- package/e2e-legacy/monitor/system/system-monitoring-without-repository.spec.js +0 -20
- package/e2e-legacy/not-found/not-found.spec.js +0 -23
- package/e2e-legacy/repository/url-with-repository-id-parameter.spec.js +0 -181
- package/e2e-legacy/setup/aclmanagement/acl-management-with-selected repository.spec.js +0 -40
- package/e2e-legacy/setup/aclmanagement/acl-management-without-repositories.spec.js +0 -21
- package/e2e-legacy/setup/autocomplete/autocomplete-with-repository.spec.js +0 -40
- package/e2e-legacy/setup/autocomplete/autocomplete-without-repository.spec.js +0 -27
- package/e2e-legacy/setup/cluster/cluster-initial-state-with-cluster.spec.js +0 -34
- package/e2e-legacy/setup/cluster/cluster-initial-state-without-cluster.spec.js +0 -25
- package/e2e-legacy/setup/connectors/connectors-initial-state-with-selected-repository.spec.js +0 -41
- package/e2e-legacy/setup/connectors/connectors-initial-state-without-repositories.spec.js +0 -21
- package/e2e-legacy/setup/jdbc/jdbc-with-repository.spec.js +0 -39
- package/e2e-legacy/setup/jdbc/jdbc-without-repository.spec.js +0 -27
- package/e2e-legacy/setup/namespaces/namespaces-with-repository.spec.js +0 -44
- package/e2e-legacy/setup/namespaces/namespaces-without-repository.spec.js +0 -27
- package/e2e-legacy/setup/plugins/plugins-with-repository.spec.js +0 -38
- package/e2e-legacy/setup/plugins/plugins-without-repository.spec.js +0 -28
- package/e2e-legacy/setup/rdf-rank/rdf-rank-with-repository.spec.js +0 -40
- package/e2e-legacy/setup/rdf-rank/rdf-rank-without-repository.spec.js +0 -30
- package/e2e-legacy/setup/repositories/repositories-view-with-repositories.spec.js +0 -40
- package/e2e-legacy/setup/repositories/repositories-view-without-repositories.spec.js +0 -28
- package/e2e-legacy/setup/settings/my-settings-initial-state.spec.js +0 -86
- package/e2e-legacy/setup/settings/my-settings.spec.js +0 -207
- package/e2e-legacy/setup/sparql-template/sparql-template-with-repository.spec.js +0 -39
- package/e2e-legacy/setup/sparql-template/sparql-template-without-repository.spec.js +0 -29
- package/e2e-legacy/setup/users-and-access/users-and-access-initial-state.spec.js +0 -25
- package/e2e-legacy/sparql-editor/sparql-page-with-selected-repository.spec.js +0 -33
- package/e2e-legacy/sparql-editor/sparql-page-without-selected-repository.spec.js +0 -26
- package/e2e-legacy/sparql-editor/yasqe-themes.spec.js +0 -54
- package/e2e-legacy/sparql-editor/yasr/toolbar/visual-graph-button.spec.js +0 -106
- package/e2e-legacy/sparql-editor/yasr/yasr.spec.js +0 -80
- package/e2e-legacy/ttyg/edit-agent.spec.js +0 -178
- package/e2e-legacy/ttyg/ttyg-initial-state-with-configured-api-key.spec.js +0 -46
- package/e2e-legacy/ttyg/ttyg-initial-state-with-selected-repository.spec.js +0 -45
- package/e2e-legacy/ttyg/ttyg-initial-state-without-repositories.spec.js +0 -21
- package/e2e-security/repository/url-with-repository-id-parameter.spec.js +0 -57
- package/e2e-security/setup/home/cookie-policy.spec.js +0 -290
- package/e2e-security/setup/users-and-access/create-user-permissions.spec.js +0 -193
- package/e2e-security/setup/users-and-access/graphql-user.spec.js +0 -126
- package/e2e-security/setup/users-and-access/repo-admin-role.spec.js +0 -70
- package/e2e-security/setup/users-and-access/turn-on-security-and-password-change.spec.js +0 -99
- package/e2e-security/setup/users-and-access/user-and-access.spec.js +0 -87
- package/e2e-security/setup/users-and-access/users-and-access-initial-state.spec.js +0 -38
- package/eslint.config.js +0 -39
- package/fixtures/graph/graph-configurations.json +0 -59
- package/fixtures/guides/autocomplete/enable-autocomplete-guide.json +0 -12
- package/fixtures/guides/class-hierarchy/class-hierarchy-guide.json +0 -35
- package/fixtures/guides/class-relations/class-relations-guide.json +0 -33
- package/fixtures/guides/confirm-cancel-dialog/confirm-cancel-dialog-guide.json +0 -15
- package/fixtures/guides/connectors/connectors-guide.json +0 -66
- package/fixtures/guides/connectors/lucene-connector-guide.json +0 -120
- package/fixtures/guides/create-repository/create-repository-guide.json +0 -25
- package/fixtures/guides/create-similarity-index/create-similarity-index-guide.json +0 -36
- package/fixtures/guides/download-guide-resource/download-guide-resource-guide.json +0 -25
- package/fixtures/guides/download-resource.ttl +0 -629
- package/fixtures/guides/execute-sparql-query/execute-sparql-query-guide.json +0 -54
- package/fixtures/guides/import-rdf-file/confirm-duplicate-rdf-file-guide.json +0 -30
- package/fixtures/guides/import-rdf-file/import-rdf-file-guide.json +0 -21
- package/fixtures/guides/main-menu/main-menu-guide.json +0 -98
- package/fixtures/guides/navigation/navigation-guide.json +0 -60
- package/fixtures/guides/rdf-rank/rdf-rank-guide.json +0 -18
- package/fixtures/guides/table-graph-explore/table-graph-explore-guide.json +0 -51
- package/fixtures/guides/table-graph-explore/table-graph-explore-without-substeps-guide.json +0 -25
- package/fixtures/guides/ttyg/configure-agent/configure-ttyg-agent-guide.json +0 -74
- package/fixtures/guides/ttyg/conversation/ttyg-conversation-guide.json +0 -26
- package/fixtures/guides/ttyg/edit-ttyg-agent/edit-ttyg-agent-guide.json +0 -22
- package/fixtures/guides/visual-graph/visual-graph-config-guide.json +0 -39
- package/fixtures/guides/visual-graph/visual-graph-guide.json +0 -85
- package/fixtures/guides/welcome/welcome-guide.json +0 -18
- package/fixtures/repositories/free-access.json +0 -13
- package/fixtures/similarity/get-ttyg-similarity-instances.json +0 -10
- package/fixtures/ttyg/agent/get-agent-defaults-assistant-api.json +0 -44
- package/fixtures/ttyg/agent/get-agent-list-with-incompatible-agents.json +0 -79
- package/fixtures/ttyg/agent/get-similarity-indexes-for-another-repo.json +0 -8
- package/fixtures/ttyg/agent/get-similarity-indexes.json +0 -22
- package/fixtures/ttyg/chats/ask-question-cancel.json +0 -12
- package/fixtures/ttyg/chats/cancel-question-response.json +0 -1
- package/fixtures/ttyg/chats/create/question-response-after-chat-creation.json +0 -29
- package/fixtures/ttyg/chats/explain-response-3.json +0 -12
- package/steps/base-steps.js +0 -29
- package/steps/cookie-policy/cookie-consent-banner-steps.js +0 -21
- package/steps/cookie-policy/cookie-policy-modal.steps.js +0 -56
- package/steps/error-page-steps.js +0 -9
- package/steps/explore/class-relationships-steps.js +0 -64
- package/steps/graphql/playground-editor-steps.js +0 -46
- package/steps/header-steps.js +0 -22
- package/steps/monitoring/queries-and-updates-steps.js +0 -20
- package/steps/monitoring/system-monitoring-steps.js +0 -40
- package/steps/not-found/not-found-steps.js +0 -23
- package/steps/rdf-resource-search-steps.js +0 -55
- package/steps/rest-api-documentation-steps.js +0 -15
- package/steps/setup/connectors-steps.js +0 -32
- package/steps/shared-modal-dialog-steps.js +0 -45
- package/steps/system-information-steps.js +0 -70
- package/steps/widgets/active-repository-widget-steps.js +0 -29
- package/steps/widgets/license-widget-steps.js +0 -9
- package/steps/widgets/repository-errors-widget-steps.js +0 -21
- package/steps/widgets/saved-sparql-queries-widget-steps.js +0 -9
- package/stubs/browser-stubs.js +0 -21
- package/stubs/graph-config-stubs.js +0 -17
- package/stubs/guides/guides-stubs.js +0 -103
- package/stubs/saved-queries-stubs.js +0 -5
- package/stubs/sparql-stubs.js +0 -10
- package/support/connector-commands.js +0 -13
- package/support/e2e-security.js +0 -9
- package/support/url-commands.js +0 -13
- package/{e2e-legacy → integration}/cluster/cluster-configuration/cluster-configuration-multi-region.spec.js +0 -0
- package/{e2e-legacy → integration}/cluster/cluster-configuration/cluster-configuration-nodes.spec.js +0 -0
- package/{e2e-legacy → integration}/cluster/cluster-configuration/cluster-configuration-properties.spec.js +0 -0
- package/{e2e-legacy → integration}/cluster/cluster-configuration/cluster-configuration.spec.js +0 -0
- package/{e2e-legacy → integration}/cluster/cluster-legend.spec.js +0 -0
- package/{e2e-legacy → integration}/cluster/edit-cluster-nodes-modal.spec.js +0 -0
- package/{e2e-legacy → integration}/graphql/activate-deactivate-graphql-endpoint.spec.js +0 -0
- package/{e2e-legacy → integration}/graphql/delete-graphql-endpoint.spec.js +0 -0
- package/{e2e-legacy → integration}/graphql/export-graphql-endpoint-definition.spec.js +0 -0
- package/{e2e-legacy → integration}/graphql/set-default-graphql-endpoint.spec.js +0 -0
- package/{e2e-legacy/help/system-information → integration/help}/system-information.spec.js +0 -0
- package/{e2e-legacy → integration}/home/create-repository.spec.js +0 -0
- package/{e2e-legacy → integration}/import/import-server-files-batch-operations.spec.js +0 -0
- package/{e2e-legacy → integration}/import/import-user-data-settings-dialog.spec.js +0 -0
- package/{e2e-legacy → integration}/import/import-view.spec.js +0 -0
- package/{e2e-legacy → integration}/repository/attach-remote-location.spec.js +1 -1
- /package/{e2e-legacy → integration}/repository/repository-commands.spec.js +0 -0
- /package/{e2e-legacy → integration}/setup/aclmanagement/delete-rule.spec.js +0 -0
- /package/{e2e-legacy → integration}/setup/aclmanagement/edit-rule.spec.js +0 -0
- /package/{e2e-legacy → integration}/setup/aclmanagement/render-rules.spec.js +0 -0
- /package/{e2e-legacy → integration}/setup/aclmanagement/reorder-rules.spec.js +0 -0
- /package/{e2e-legacy → integration}/setup/aclmanagement/revert-rules.spec.js +0 -0
- /package/{e2e-legacy → integration}/setup/aclmanagement/scopes.spec.js +0 -0
- /package/{e2e-legacy → integration}/setup/aclmanagement/update-rules.spec.js +0 -0
- /package/{e2e-legacy → integration}/setup/jdbc/jdbc.spec.js +0 -0
- /package/{e2e-legacy → integration}/sparql-editor/actions/execute-query.spec.js +0 -0
- /package/{e2e-legacy → integration}/sparql-editor/actions/save-query.spec.js +0 -0
- /package/{e2e-legacy → integration}/sparql-editor/internationalization.spec.js +0 -0
- /package/{e2e-legacy → integration}/sparql-editor/saved-query/delete-query.spec.js +0 -0
- /package/{e2e-legacy → integration}/sparql-editor/sparql-editor.spec.js +0 -0
- /package/{e2e-legacy → integration}/sparql-editor/yasr/download-as.spec.js +0 -0
- /package/{e2e-flaky → integration-flaky}/import/import.server.files.spec.js +0 -0
- /package/{e2e-flaky → integration-flaky}/sparql-editor/lucene-connector.spec.js +0 -0
- /package/{e2e-flaky → integration-flaky}/sparql-editor/plugins/error-plugin.spec.js +0 -0
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import {GlobalOperationsStatusesStub} from "./global-operations-statuses-stub";
|
|
2
|
+
|
|
3
|
+
export class RepositoriesStub {
|
|
4
|
+
|
|
5
|
+
static stubOntopRepository(repositoryId) {
|
|
6
|
+
const alRepositoryResponse = `{
|
|
7
|
+
"":[{
|
|
8
|
+
"id": "${repositoryId}",
|
|
9
|
+
"title": "",
|
|
10
|
+
"uri": "http://b:9000/repositories/${repositoryId}",
|
|
11
|
+
"externalUrl": "http://b:9000/repositories/${repositoryId}",
|
|
12
|
+
"local": true,
|
|
13
|
+
"type": "ontop",
|
|
14
|
+
"sesameType": "graphdb:OntopRepository",
|
|
15
|
+
"location": "",
|
|
16
|
+
"readable": true,
|
|
17
|
+
"writable": true,
|
|
18
|
+
"unsupported": false,
|
|
19
|
+
"state": "RUNNING"
|
|
20
|
+
}]}`;
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
cy.intercept('GET', '/rest/repositories/all', {
|
|
24
|
+
statusCode: 200,
|
|
25
|
+
body: alRepositoryResponse
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* @param {string} repositoryId
|
|
31
|
+
* @param {[]}namespaces - An instance of array object have to be:
|
|
32
|
+
* {
|
|
33
|
+
* "prefix" : {
|
|
34
|
+
* "type" : "literal",
|
|
35
|
+
* "value" : "agg"
|
|
36
|
+
* },
|
|
37
|
+
* "namespace" : {
|
|
38
|
+
* "type" : "literal",
|
|
39
|
+
* "value" : "http://jena.apache.org/ARQ/function/aggregate#"
|
|
40
|
+
* }
|
|
41
|
+
* }
|
|
42
|
+
*/
|
|
43
|
+
static stubNameSpaces(repositoryId, namespaces = []) {
|
|
44
|
+
const namespacesResponse = `{
|
|
45
|
+
"head" : {
|
|
46
|
+
"vars" : [
|
|
47
|
+
"prefix",
|
|
48
|
+
"namespace"
|
|
49
|
+
]
|
|
50
|
+
},
|
|
51
|
+
"results" : {
|
|
52
|
+
"bindings" : ${JSON.stringify(namespaces)}
|
|
53
|
+
}
|
|
54
|
+
}`;
|
|
55
|
+
cy.intercept('GET', `/repositories/${repositoryId}/namespaces`, {
|
|
56
|
+
statusCode: 200,
|
|
57
|
+
body: namespacesResponse
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
static stubAutocomplete() {
|
|
62
|
+
cy.intercept(`/rest/autocomplete/enabled`, {
|
|
63
|
+
statusCode: 200,
|
|
64
|
+
body: {}
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
static stubBaseEndpoints(repositoryId, namespaces) {
|
|
69
|
+
RepositoriesStub.stubNameSpaces(repositoryId, namespaces);
|
|
70
|
+
RepositoriesStub.stubAutocomplete();
|
|
71
|
+
GlobalOperationsStatusesStub.stubNoOperationsResponse('starwars');
|
|
72
|
+
}
|
|
73
|
+
}
|
package/stubs/security-stubs.js
CHANGED
|
@@ -1,29 +1,17 @@
|
|
|
1
1
|
export class SecurityStubs {
|
|
2
2
|
|
|
3
|
-
static spyOnAuthenticatedUser() {
|
|
4
|
-
cy.intercept('/rest/security/authenticated-user').as('get-authenticated-user')
|
|
5
|
-
}
|
|
6
|
-
|
|
7
3
|
static stubUserSecurity(infer = true, sameAs = true, userName = 'admin') {
|
|
8
4
|
cy.intercept(`rest/security/users/${userName}`, (req) => {
|
|
9
5
|
req.reply(SecurityStubs.getAdminResponse(infer, sameAs));
|
|
10
6
|
}).as('security-get-admin');
|
|
11
7
|
}
|
|
12
8
|
|
|
13
|
-
static spyOnUserCreate() {
|
|
14
|
-
cy.intercept('POST', 'rest/security/users/*').as('create-user');
|
|
15
|
-
}
|
|
16
|
-
|
|
17
9
|
static stubInferAndSameAsDefaults() {
|
|
18
10
|
cy.intercept('rest/security/all', (req) => {
|
|
19
11
|
req.reply(SecurityStubs.getResponseSecurityEnabled());
|
|
20
12
|
}).as('security-all');
|
|
21
13
|
}
|
|
22
14
|
|
|
23
|
-
static spyOnUserUpdate(userName) {
|
|
24
|
-
cy.intercept('PATCH', `rest/security/users/${userName}`).as('updateUser');
|
|
25
|
-
}
|
|
26
|
-
|
|
27
15
|
static stubUpdateUserData(userName) {
|
|
28
16
|
cy.intercept('PATCH', `/rest/security/users/${userName}`, {
|
|
29
17
|
statusCode: 200,
|
|
@@ -29,8 +29,4 @@ export class SimilarityIndexStubs extends Stubs {
|
|
|
29
29
|
}).as('get-ttyg-similarity-indexes');
|
|
30
30
|
});
|
|
31
31
|
}
|
|
32
|
-
|
|
33
|
-
static stubTTYGSimilarityInstances(fixture = '/similarity/get-ttyg-similarity-instances.json', delay = 0) {
|
|
34
|
-
this.stubQueryResponse('/rest/similarity/**/indexes', fixture, 'get-ttyg-similarity-instances', delay);
|
|
35
|
-
}
|
|
36
32
|
}
|
package/stubs/ttyg/ttyg-stubs.js
CHANGED
|
@@ -86,18 +86,6 @@ export class TTYGStubs extends Stubs {
|
|
|
86
86
|
}).as('get-agent-list');
|
|
87
87
|
}
|
|
88
88
|
|
|
89
|
-
static getSimilarityIndexesForRepo(repositoryId, fixture = '/ttyg/agent/get-similarity-indexes.json', delay = 0) {
|
|
90
|
-
cy.intercept('GET', `rest/similarity/${repositoryId}/indexes`, {
|
|
91
|
-
fixture: fixture,
|
|
92
|
-
statusCode: 200,
|
|
93
|
-
delay: delay
|
|
94
|
-
}).as('get-similarity-indexes');
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
static stubAgentListWithIncompatibleGet(delay = 0) {
|
|
98
|
-
this.stubAgentListGet('/ttyg/agent/get-agent-list-with-incompatible-agents.json', delay);
|
|
99
|
-
}
|
|
100
|
-
|
|
101
89
|
static stubAgentGet(fixture = '/ttyg/agent/get-agent.json', delay = 0) {
|
|
102
90
|
cy.intercept('GET', '/rest/chat/agents/*', {
|
|
103
91
|
fixture: fixture,
|
|
@@ -106,10 +94,12 @@ export class TTYGStubs extends Stubs {
|
|
|
106
94
|
}).as('get-agent');
|
|
107
95
|
}
|
|
108
96
|
|
|
109
|
-
static stubAgentListGetError(
|
|
97
|
+
static stubAgentListGetError() {
|
|
110
98
|
cy.intercept('GET', '/rest/chat/agents', {
|
|
111
99
|
statusCode: 500,
|
|
112
|
-
|
|
100
|
+
response: {
|
|
101
|
+
error: 'Internal Server Error'
|
|
102
|
+
}
|
|
113
103
|
}).as('get-agent-list-error');
|
|
114
104
|
}
|
|
115
105
|
|
|
@@ -141,60 +131,30 @@ export class TTYGStubs extends Stubs {
|
|
|
141
131
|
}).as('delete-agent');
|
|
142
132
|
}
|
|
143
133
|
|
|
144
|
-
static stubAgentDefaultsGet(
|
|
134
|
+
static stubAgentDefaultsGet() {
|
|
145
135
|
cy.intercept('GET', '/rest/chat/agents/default', {
|
|
146
|
-
fixture,
|
|
136
|
+
fixture: '/ttyg/agent/get-agent-defaults.json',
|
|
147
137
|
statusCode: 200
|
|
148
138
|
}).as('get-agent-defaults');
|
|
149
139
|
}
|
|
150
140
|
|
|
151
141
|
static stubAnswerQuestion(fixture = '/ttyg/chats/ask-question.json') {
|
|
152
|
-
cy.intercept('POST', '/rest/chat/
|
|
142
|
+
cy.intercept('POST', '/rest/chat/conversations', {
|
|
153
143
|
fixture,
|
|
154
144
|
statusCode: 200
|
|
155
145
|
}).as('get-agent-defaults');
|
|
156
146
|
}
|
|
157
147
|
|
|
158
|
-
static
|
|
159
|
-
cy.
|
|
160
|
-
method: 'POST',
|
|
161
|
-
url: '/rest/chat/chats/**/question',
|
|
162
|
-
}, (req) => {
|
|
163
|
-
req.reply({
|
|
164
|
-
fixture,
|
|
165
|
-
statusCode: 200,
|
|
166
|
-
delay
|
|
167
|
-
});
|
|
168
|
-
}).as('get-cancelled-answer');
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
static stubCancelQuestion(fixture = '/ttyg/chats/cancel-question-response.json', delay = 1000) {
|
|
172
|
-
cy.intercept({
|
|
173
|
-
method: 'POST',
|
|
174
|
-
url: 'rest/chat/chats/**/cancel'
|
|
175
|
-
}, (req) => {
|
|
176
|
-
req.reply({
|
|
177
|
-
fixture,
|
|
178
|
-
statusCode: 200,
|
|
179
|
-
delay
|
|
180
|
-
});
|
|
181
|
-
}).as('get-cancel-response');
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
static stubCreateNewChat() {
|
|
185
|
-
cy.intercept('POST', '/rest/chat/chats', {
|
|
186
|
-
fixture: 'ttyg/chats/create/create-chat-response.json',
|
|
187
|
-
statusCode: 200
|
|
188
|
-
}).as('ask-first-chat-question');
|
|
189
|
-
|
|
190
|
-
cy.fixture('ttyg/chats/create/question-response-after-chat-creation.json').then((fixtureData) => {
|
|
148
|
+
static stubCrateNewChat(fixture = 'ttyg/chats/create/create-chat-response.json') {
|
|
149
|
+
cy.fixture(fixture).then((fixtureData) => {
|
|
191
150
|
const today = Math.floor(Date.now() / 1000) + '';
|
|
192
151
|
const body = JSON.stringify(fixtureData).replace(/"creationDate"/g, today);
|
|
193
|
-
cy.intercept('POST', '/rest/chat/
|
|
152
|
+
cy.intercept('POST', '/rest/chat/conversations', {
|
|
194
153
|
statusCode: 200,
|
|
195
154
|
body: JSON.parse(body)
|
|
196
155
|
}).as('create-chat');
|
|
197
156
|
});
|
|
157
|
+
|
|
198
158
|
}
|
|
199
159
|
|
|
200
160
|
static stubExplainResponse(fixture = '/ttyg/chats/explain-response-1.json') {
|
|
@@ -204,19 +164,10 @@ export class TTYGStubs extends Stubs {
|
|
|
204
164
|
}).as('explain-response');
|
|
205
165
|
}
|
|
206
166
|
|
|
207
|
-
static
|
|
208
|
-
cy.intercept('GET', 'rest/
|
|
167
|
+
static stubAutocompleteResponse(fixture = '/ttyg/autocomplete-response.json') {
|
|
168
|
+
cy.intercept('GET', '/rest/autocomplete/query?*', {
|
|
169
|
+
fixture,
|
|
209
170
|
statusCode: 200,
|
|
210
|
-
|
|
211
|
-
}).as('external-url');
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
static stubForApiType(type = 'default') {
|
|
215
|
-
const fixtures = {
|
|
216
|
-
default: '/ttyg/agent/get-agent-defaults.json',
|
|
217
|
-
assistants: '/ttyg/agent/get-agent-defaults-assistant-api.json'
|
|
218
|
-
};
|
|
219
|
-
this.stubAgentListGet('/ttyg/agent/get-agent-list-autocomplete-query.json');
|
|
220
|
-
this.stubAgentDefaultsGet(fixtures[type]);
|
|
171
|
+
}).as('autocomplete-suggestions');
|
|
221
172
|
}
|
|
222
173
|
}
|
|
@@ -85,7 +85,7 @@ export class QueryStubs {
|
|
|
85
85
|
}).as(`query-${page}_${offset}_${limit}_${returnResult}`);
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
static stubTotalQueryCount(repositoryId, totalElements, resultType) {
|
|
88
|
+
static stubTotalQueryCount(repositoryId, totalElements, resultType, delay = 0) {
|
|
89
89
|
const result = QueryStubs.createEmptyResponse(resultType);
|
|
90
90
|
result.results.bindings = [QueryStubs.createTotalResultsCount(resultType, totalElements)];
|
|
91
91
|
cy.intercept(`/repositories/${repositoryId}`, (req) => {
|
|
@@ -221,10 +221,6 @@ export class QueryStubs {
|
|
|
221
221
|
}
|
|
222
222
|
};
|
|
223
223
|
}
|
|
224
|
-
|
|
225
|
-
static interceptSavedQueryCreation() {
|
|
226
|
-
cy.intercept('POST', '/rest/sparql/saved-queries').as('saveQuery');
|
|
227
|
-
}
|
|
228
224
|
}
|
|
229
225
|
|
|
230
226
|
export class QueryStubDescription {
|
package/support/commands.js
CHANGED
|
@@ -6,9 +6,7 @@ import './settings-commands';
|
|
|
6
6
|
import './visual-graph-commands';
|
|
7
7
|
import './user-commands';
|
|
8
8
|
import './security-command';
|
|
9
|
-
import './connector-commands';
|
|
10
9
|
import 'cypress-wait-until';
|
|
11
|
-
import './url-commands.js';
|
|
12
10
|
|
|
13
11
|
/**
|
|
14
12
|
* Loads fixtures from the given paths recursively and returns them as an array.
|
|
@@ -84,26 +82,7 @@ Cypress.Commands.add("form_request", (url, formData) => {
|
|
|
84
82
|
* @author Sava Savov sava.savov@ontotext.com
|
|
85
83
|
*/
|
|
86
84
|
|
|
87
|
-
Cypress.Commands.add("hideToastContainer", () => {
|
|
85
|
+
Cypress.Commands.add("hideToastContainer", (url, formData) => {
|
|
88
86
|
cy.get('.toast-success')
|
|
89
87
|
.then((toastContainer) => toastContainer && toastContainer.remove());
|
|
90
88
|
});
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
/**
|
|
94
|
-
* Get element by testId. Can be chained to another cypress command, or used directly
|
|
95
|
-
*
|
|
96
|
-
* @Example
|
|
97
|
-
* MySteps.getSomething().getByTestId('my-test-id');
|
|
98
|
-
* Or
|
|
99
|
-
* cy.getByTestId('my-test-id');
|
|
100
|
-
*/
|
|
101
|
-
Cypress.Commands.add('getByTestId', {prevSubject: 'optional'}, (subject, testId) => {
|
|
102
|
-
return subject
|
|
103
|
-
? cy.wrap(subject).find(buildTestIdAttr(testId))
|
|
104
|
-
: cy.get(buildTestIdAttr(testId));
|
|
105
|
-
});
|
|
106
|
-
|
|
107
|
-
function buildTestIdAttr(testId) {
|
|
108
|
-
return `[data-test="${testId}"]`;
|
|
109
|
-
}
|
|
@@ -23,23 +23,16 @@ import 'cypress-real-events';
|
|
|
23
23
|
import 'cypress-file-upload';
|
|
24
24
|
import {LicenseStubs} from "../stubs/license-stubs";
|
|
25
25
|
import {SecurityStubs} from "../stubs/security-stubs";
|
|
26
|
-
// https://github.com/bahmutov/cypress-code-coverage
|
|
27
|
-
import '@bahmutov/cypress-code-coverage/support';
|
|
28
26
|
|
|
29
27
|
// Configures an environment variable with the key used for common actions (cmd on mac, ctrl on other OS).
|
|
30
28
|
// This variable must be used in all actions that type e.g. ctrl-a to select text.
|
|
31
29
|
Cypress.env('modifierKey', Cypress.platform === 'darwin' ? '{cmd}' : '{ctrl}');
|
|
32
30
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
const installLogsCollector = ('default' in ctr) ? ctr.default : ctr;
|
|
36
|
-
installLogsCollector();
|
|
31
|
+
require('cypress-failed-log');
|
|
32
|
+
require('cypress-terminal-report/src/installLogsCollector')();
|
|
37
33
|
|
|
38
34
|
// We don't want any tests to hit real Google
|
|
39
35
|
beforeEach(() => {
|
|
40
|
-
// Ensure no pre-set repository leaks between specs
|
|
41
|
-
cy.unsetRepository();
|
|
42
|
-
|
|
43
36
|
LicenseStubs.stubGoogleCalls();
|
|
44
37
|
// This env variable is set globally in the cypress.config.js and
|
|
45
38
|
// can be changed from within the spec files if needed like this
|
|
@@ -51,5 +44,6 @@ beforeEach(() => {
|
|
|
51
44
|
// for some reason.
|
|
52
45
|
// It'll be good to investigate it a bit sometime.
|
|
53
46
|
SecurityStubs.stubGetAdminUser();
|
|
47
|
+
// SecurityStubs.stubUpdateUserData('admin');
|
|
54
48
|
}
|
|
55
49
|
});
|
|
@@ -3,7 +3,7 @@ import repoTemplate from '../fixtures/repo-template.json';
|
|
|
3
3
|
export const REPOSITORIES_URL = '/rest/repositories';
|
|
4
4
|
const AUTOCOMPLETE_URL = '/rest/autocomplete/';
|
|
5
5
|
|
|
6
|
-
const PRESET_REPO = '
|
|
6
|
+
const PRESET_REPO = 'ls.repository-id';
|
|
7
7
|
|
|
8
8
|
Cypress.Commands.add('createRepository', (options = {}) => {
|
|
9
9
|
cy.request({
|
|
@@ -15,13 +15,10 @@ Cypress.Commands.add('createRepository', (options = {}) => {
|
|
|
15
15
|
}
|
|
16
16
|
}).then((response) => {
|
|
17
17
|
cy.waitUntil(() => response && response.status === 201); // 201 Created
|
|
18
|
-
cy.log('Created repository with ID:', options.id);
|
|
19
18
|
});
|
|
20
19
|
});
|
|
21
20
|
|
|
22
21
|
Cypress.Commands.add('deleteRepository', (id, secured = false) => {
|
|
23
|
-
// unset the repository before delete to avoid missing repo errors
|
|
24
|
-
unsetRepository();
|
|
25
22
|
// Note: Going through /rest/repositories because it would not fail if the repo is missing
|
|
26
23
|
const url = REPOSITORIES_URL + '/' + id;
|
|
27
24
|
|
|
@@ -42,29 +39,14 @@ Cypress.Commands.add('deleteRepository', (id, secured = false) => {
|
|
|
42
39
|
headers,
|
|
43
40
|
// Prevent Cypress from failing the test on non-2xx status codes
|
|
44
41
|
failOnStatusCode: false
|
|
45
|
-
})
|
|
46
|
-
cy.waitUntil(() => response);
|
|
47
|
-
});
|
|
42
|
+
});
|
|
48
43
|
});
|
|
49
44
|
|
|
50
45
|
Cypress.Commands.add('presetRepository', (id) => {
|
|
51
|
-
cy.setLocalStorage(
|
|
52
|
-
cy.waitUntil(() =>
|
|
53
|
-
cy.getLocalStorage(PRESET_REPO)
|
|
54
|
-
.then((preset) => {
|
|
55
|
-
const presetRepo = JSON.parse(preset);
|
|
56
|
-
return presetRepo && presetRepo.id === id
|
|
57
|
-
}));
|
|
58
|
-
cy.log('Pre-set repository:', id);
|
|
59
|
-
});
|
|
60
|
-
|
|
61
|
-
Cypress.Commands.add('unsetRepository', () => {
|
|
62
|
-
cy.removeLocalStorage(PRESET_REPO);
|
|
46
|
+
cy.setLocalStorage('ls.repository-id', id);
|
|
63
47
|
cy.waitUntil(() =>
|
|
64
48
|
cy.getLocalStorage(PRESET_REPO)
|
|
65
|
-
.then((preset) =>
|
|
66
|
-
return !preset;
|
|
67
|
-
}));
|
|
49
|
+
.then((preset) => preset && preset === id));
|
|
68
50
|
});
|
|
69
51
|
|
|
70
52
|
/**
|
|
@@ -96,8 +78,6 @@ Cypress.Commands.add('getNamespaces', (id) => {
|
|
|
96
78
|
});
|
|
97
79
|
});
|
|
98
80
|
|
|
99
|
-
Cypress.Commands.add('unsetRepository', () => unsetRepository())
|
|
100
|
-
|
|
101
81
|
const toggleAutocomplete = (repositoryId, enable) => {
|
|
102
82
|
cy.request({
|
|
103
83
|
method: 'POST',
|
|
@@ -121,8 +101,3 @@ const waitAutocomplete = function (repositoryId) {
|
|
|
121
101
|
}
|
|
122
102
|
}).then((response) => response.status === 200 && (response.body === 'READY' || response.body === 'NONE')));
|
|
123
103
|
};
|
|
124
|
-
|
|
125
|
-
const unsetRepository = () => {
|
|
126
|
-
cy.removeLocalStorage(PRESET_REPO);
|
|
127
|
-
cy.log('Unset repository');
|
|
128
|
-
}
|
|
@@ -1,12 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
* Sets the default user settings for the admin user, including cookie consent.
|
|
3
|
-
* @param {CookieConsent} cookieConsent - The value to set for cookie consent.
|
|
4
|
-
* - policyAccepted: boolean indicating whether the cookie policy has been accepted.
|
|
5
|
-
* - statistic: boolean indicating consent for statistical cookies.
|
|
6
|
-
* - thirdParty: boolean indicating consent for third-party cookies.
|
|
7
|
-
* - updatedAt: epoch timestamp of last update in seconds.
|
|
8
|
-
*/
|
|
9
|
-
Cypress.Commands.add('setDefaultUserData', (cookieConsent) => {
|
|
1
|
+
Cypress.Commands.add('setDefaultUserData', (cookieConsent = true) => {
|
|
10
2
|
const defaultUserSettings = {
|
|
11
3
|
'COOKIE_CONSENT': cookieConsent,
|
|
12
4
|
'DEFAULT_SAMEAS': true,
|
|
@@ -26,27 +18,3 @@ Cypress.Commands.add('setDefaultUserData', (cookieConsent) => {
|
|
|
26
18
|
cy.waitUntil(() => response && response.status === 200); // 201 Created
|
|
27
19
|
});
|
|
28
20
|
});
|
|
29
|
-
|
|
30
|
-
/**
|
|
31
|
-
* Sets the cookie consent in user settings for the admin user.
|
|
32
|
-
* @param {CookieConsent} cookieConsent - The value to set for cookie consent.
|
|
33
|
-
* - policyAccepted: boolean indicating whether the cookie policy has been accepted.
|
|
34
|
-
* - statistic: boolean indicating consent for statistical cookies.
|
|
35
|
-
* - thirdParty: boolean indicating consent for third-party cookies.
|
|
36
|
-
* - updatedAt: epoch timestamp of last update in seconds.
|
|
37
|
-
*/
|
|
38
|
-
Cypress.Commands.add('setCookieConsent', (cookieConsent ) => {
|
|
39
|
-
const defaultUserSettings = {
|
|
40
|
-
'COOKIE_CONSENT': cookieConsent
|
|
41
|
-
};
|
|
42
|
-
cy.request({
|
|
43
|
-
method: 'PATCH',
|
|
44
|
-
url: `rest/security/users/${encodeURIComponent('admin')}`,
|
|
45
|
-
body: {
|
|
46
|
-
"appSettings": defaultUserSettings,
|
|
47
|
-
'password': 'root'
|
|
48
|
-
}
|
|
49
|
-
}).then((response) => {
|
|
50
|
-
cy.waitUntil(() => response && response.status === 200); // 201 Created
|
|
51
|
-
});
|
|
52
|
-
});
|
package/support/user-commands.js
CHANGED
|
@@ -1,15 +1,7 @@
|
|
|
1
|
-
Cypress.Commands.add('createUser', (options = {}
|
|
2
|
-
let headers = {'Content-Type': 'application/json'};
|
|
3
|
-
if (secured) {
|
|
4
|
-
const authHeader = Cypress.env('adminToken');
|
|
5
|
-
headers = {...headers,
|
|
6
|
-
'Authorization': authHeader
|
|
7
|
-
}
|
|
8
|
-
}
|
|
1
|
+
Cypress.Commands.add('createUser', (options = {}) => {
|
|
9
2
|
cy.request({
|
|
10
3
|
method: 'POST',
|
|
11
4
|
url: `/rest/security/users/${options.username}`,
|
|
12
|
-
headers,
|
|
13
5
|
body: {
|
|
14
6
|
"password": options.password || "root",
|
|
15
7
|
"appSettings": {
|
|
@@ -20,6 +12,9 @@ Cypress.Commands.add('createUser', (options = {}, secured = false) => {
|
|
|
20
12
|
"DEFAULT_VIS_GRAPH_SCHEMA": true
|
|
21
13
|
},
|
|
22
14
|
"grantedAuthorities": options.grantedAuthorities || ["ROLE_USER", "WRITE_REPO_*", "READ_REPO_*"]
|
|
15
|
+
},
|
|
16
|
+
headers: {
|
|
17
|
+
'Content-Type': 'application/json'
|
|
23
18
|
}
|
|
24
19
|
}).then((response) => {
|
|
25
20
|
cy.waitUntil(() => response && response.status === 201); // 201 Created
|
package/utils/html-util.js
CHANGED
|
@@ -2,9 +2,8 @@ export class HtmlUtil {
|
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* Verifies that an element's content is truncated with an ellipsis by checking that
|
|
5
|
-
*
|
|
6
|
-
* This is used to assert that the element's text is overflowing
|
|
7
|
-
* and is being clipped with ellipsis.
|
|
5
|
+
* the scroll width of the element is greater than its offset width.
|
|
6
|
+
* This is used to assert that the element's text is overflowing and is being clipped with ellipsis.
|
|
8
7
|
*
|
|
9
8
|
* @param {Cypress.Chainable<JQuery<HTMLElement>>} element - The Cypress chainable element to check.
|
|
10
9
|
* @throws {AssertionError} If the element's content is not truncated with ellipsis.
|
|
@@ -15,27 +14,8 @@ export class HtmlUtil {
|
|
|
15
14
|
*/
|
|
16
15
|
static verifyEllipsis(element) {
|
|
17
16
|
element.should(($el) => {
|
|
18
|
-
|
|
17
|
+
const el = $el[0];
|
|
18
|
+
expect(el.scrollWidth).to.be.greaterThan(el.offsetWidth);
|
|
19
19
|
});
|
|
20
20
|
}
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* Verifies that an element's content is NOT truncated.
|
|
24
|
-
* Checks that the scroll dimensions are equal to the offset dimensions,
|
|
25
|
-
* indicating the content fits completely within the visible area.
|
|
26
|
-
*
|
|
27
|
-
* @param {Cypress.Chainable<JQuery<HTMLElement>>} element - The Cypress chainable element to check.
|
|
28
|
-
*/
|
|
29
|
-
static verifyNoEllipsis(element) {
|
|
30
|
-
element.should(($el) => {
|
|
31
|
-
expect(HtmlUtil.isOverflowing($el), 'Element content should fit fully (no ellipsis)').to.be.false;
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
static isOverflowing($el) {
|
|
36
|
-
const el = $el[0];
|
|
37
|
-
const isHorizontalOverflow = el.scrollWidth > el.offsetWidth;
|
|
38
|
-
const isVerticalOverflow = el.scrollHeight > el.offsetHeight;
|
|
39
|
-
return isHorizontalOverflow || isVerticalOverflow;
|
|
40
|
-
}
|
|
41
21
|
}
|
package/.editorconfig
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
root = true
|
|
2
|
-
|
|
3
|
-
[*]
|
|
4
|
-
|
|
5
|
-
indent_style = space
|
|
6
|
-
indent_size = 4
|
|
7
|
-
|
|
8
|
-
end_of_line = lf
|
|
9
|
-
charset = utf-8
|
|
10
|
-
trim_trailing_whitespace = true
|
|
11
|
-
insert_final_newline = true
|
|
12
|
-
|
|
13
|
-
[*.md]
|
|
14
|
-
trim_trailing_whitespace = false
|
|
15
|
-
|
|
16
|
-
[*.txt]
|
|
17
|
-
insert_final_newline = false
|
package/.nycrc
DELETED
package/cypress-legacy.config.js
DELETED
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { defineConfig } from 'cypress';
|
|
2
|
-
import setupPlugins from './plugins/index.js';
|
|
3
|
-
|
|
4
|
-
const isCoverage = process.env.COVERAGE === 'true';
|
|
5
|
-
|
|
6
|
-
const loadCodeCoverage = async (on, config) => {
|
|
7
|
-
const mod = await import('@bahmutov/cypress-code-coverage/plugin');
|
|
8
|
-
const plugin = ('default' in mod) ? mod.default : mod;
|
|
9
|
-
plugin(on, config);
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
export default defineConfig({
|
|
13
|
-
projectId: 'v35btb',
|
|
14
|
-
fixturesFolder: 'fixtures',
|
|
15
|
-
screenshotsFolder: 'report/screenshots',
|
|
16
|
-
videosFolder: 'report/videos',
|
|
17
|
-
video: true,
|
|
18
|
-
defaultCommandTimeout: 25000,
|
|
19
|
-
numTestsKeptInMemory: 10,
|
|
20
|
-
viewportWidth: 1600,
|
|
21
|
-
viewportHeight: 1200,
|
|
22
|
-
e2e: {
|
|
23
|
-
retries: {
|
|
24
|
-
runMode: 2,
|
|
25
|
-
openMode: 0
|
|
26
|
-
},
|
|
27
|
-
// We've imported your old cypress plugins here.
|
|
28
|
-
// You may want to clean this up later by importing these.
|
|
29
|
-
async setupNodeEvents(on, config) {
|
|
30
|
-
setupPlugins(on, config);
|
|
31
|
-
if (isCoverage) {
|
|
32
|
-
await loadCodeCoverage(on, config);
|
|
33
|
-
}
|
|
34
|
-
return config;
|
|
35
|
-
},
|
|
36
|
-
baseUrl: 'http://localhost:9000',
|
|
37
|
-
specPattern: 'e2e-legacy/**/*.{js,jsx,ts,tsx}',
|
|
38
|
-
supportFile: 'support/e2e.js',
|
|
39
|
-
reporter: "cypress-multi-reporters",
|
|
40
|
-
reporterOptions: {
|
|
41
|
-
configFile: 'cypress-reporter-config.json'
|
|
42
|
-
}
|
|
43
|
-
},
|
|
44
|
-
env: {
|
|
45
|
-
set_default_user_data: true
|
|
46
|
-
}
|
|
47
|
-
});
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { defineConfig } from 'cypress';
|
|
2
|
-
import setupPlugins from './plugins/index.js';
|
|
3
|
-
|
|
4
|
-
export default defineConfig({
|
|
5
|
-
projectId: 'v35btb',
|
|
6
|
-
fixturesFolder: 'fixtures',
|
|
7
|
-
screenshotsFolder: 'report/screenshots',
|
|
8
|
-
videosFolder: 'report/videos',
|
|
9
|
-
video: true,
|
|
10
|
-
defaultCommandTimeout: 25000,
|
|
11
|
-
numTestsKeptInMemory: 10,
|
|
12
|
-
viewportWidth: 1600,
|
|
13
|
-
viewportHeight: 1200,
|
|
14
|
-
e2e: {
|
|
15
|
-
retries: {
|
|
16
|
-
runMode: 2,
|
|
17
|
-
openMode: 0
|
|
18
|
-
},
|
|
19
|
-
// We've imported your old cypress plugins here.
|
|
20
|
-
// You may want to clean this up later by importing these.
|
|
21
|
-
async setupNodeEvents(on, config) {
|
|
22
|
-
setupPlugins(on, config);
|
|
23
|
-
return config;
|
|
24
|
-
},
|
|
25
|
-
baseUrl: 'http://localhost:9000',
|
|
26
|
-
specPattern: 'e2e-security/**/*.{js,jsx,ts,tsx}',
|
|
27
|
-
supportFile: 'support/e2e-security.js',
|
|
28
|
-
reporter: "cypress-multi-reporters",
|
|
29
|
-
reporterOptions: {
|
|
30
|
-
configFile: 'cypress-reporter-config.json'
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
env: {
|
|
34
|
-
set_default_user_data: true
|
|
35
|
-
}
|
|
36
|
-
});
|