graphdb-workbench-tests 3.4.0-dynamic-guides-test → 3.5.0-reactodia-poc
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/e2e-legacy/cluster/cluster-states.spec.js +3 -3
- package/e2e-legacy/explore/visual-graph/node-info-panel.spec.js +58 -0
- package/e2e-legacy/explore/visual-graph/visual-graph-links-limit.spec.js +167 -0
- package/e2e-legacy/explore/visual-graph/visual.graph.spec.js +55 -78
- package/e2e-legacy/graphql/graphql-in-remote-location.spec.js +49 -0
- package/e2e-legacy/guides/navigation/navigation-guide.spec.js +64 -0
- package/e2e-legacy/guides/table-graph-explore/table-graph-explore-guide.spec.js +2 -1
- package/e2e-legacy/guides/ttyg/configure-agent/configure-agent-guide.spec.js +34 -26
- package/e2e-legacy/guides/ttyg/edit-agent/edit-ttyg-agent-guide.spec.js +1 -0
- package/e2e-legacy/guides/visual-graph/visual-graph-guide.spec.js +330 -124
- package/e2e-legacy/help/guides/guides-autostart.spec.js +36 -3
- package/e2e-legacy/help/guides/guides-confirm-cancel-dialog.js +83 -0
- package/e2e-legacy/home/cookie-policy/cookie-policy.spec.js +182 -0
- package/e2e-legacy/home/create-repository.spec.js +6 -0
- package/e2e-legacy/repository/attach-remote-location.spec.js +47 -12
- package/e2e-legacy/repository/url-with-repository-id-parameter.spec.js +1 -1
- package/e2e-legacy/resource/resource.spec.js +33 -13
- package/e2e-legacy/setup/aclmanagement/acl-management-with-selected repository.spec.js +44 -0
- package/e2e-legacy/sparql-editor/actions/execute-query.spec.js +2 -0
- package/e2e-legacy/sparql-editor/actions/expand-results-over-sameas.spec.js +8 -8
- package/e2e-legacy/sparql-editor/actions/include-inferred-statements.spec.js +4 -4
- package/e2e-legacy/sparql-editor/actions/inferred-sameas.spec.js +3 -3
- package/e2e-legacy/sparql-editor/yasr/toolbar/visual-graph-button.spec.js +90 -36
- package/e2e-legacy/sparql-editor/yasr/yasr.spec.js +80 -0
- package/e2e-legacy/ttyg/chat-panel.spec.js +9 -0
- package/e2e-legacy/ttyg/clone-agent.spec.js +22 -0
- package/e2e-legacy/ttyg/edit-agent.spec.js +17 -0
- package/e2e-security/setup/home/cookie-policy.spec.js +232 -6
- package/e2e-security/setup/users-and-access/turn-on-security-and-password-change.spec.js +72 -59
- package/fixtures/graph/graph-configurations.json +59 -0
- package/fixtures/guides/confirm-cancel-dialog/confirm-cancel-dialog-guide.json +15 -0
- package/fixtures/guides/navigation/navigation-guide.json +60 -0
- package/fixtures/guides/ttyg/configure-agent/configure-ttyg-agent-guide.json +6 -1
- package/fixtures/guides/visual-graph/visual-graph-config-guide.json +39 -0
- package/fixtures/ttyg/chats/explain-response-1.json +2 -48
- package/npm-shrinkwrap.json +32 -33
- package/package.json +1 -1
- package/steps/cookie-policy/cookie-consent-banner-steps.js +21 -0
- package/steps/cookie-policy/cookie-policy-modal.steps.js +56 -0
- package/steps/graphql/create-graphql-endpoint-steps.js +8 -0
- package/steps/graphql/graphql-endpoint-management-steps.js +8 -0
- package/steps/graphql/graphql-playground-steps.js +8 -0
- package/steps/guides/guide-dialog-steps.js +56 -2
- package/steps/guides/movies-guide-steps.js +2 -1
- package/steps/header-steps.js +13 -0
- package/steps/home-steps.js +4 -27
- package/steps/login-steps.js +1 -0
- package/steps/main-menu-steps.js +1 -0
- package/steps/repositories/attach-repository-steps.js +16 -0
- package/steps/repository-steps.js +24 -0
- package/steps/resource/resource-steps.js +0 -8
- package/steps/setup/acl-management-steps.js +12 -0
- package/steps/setup/settings-steps.js +1 -1
- package/steps/shared-modal-dialog-steps.js +45 -0
- package/steps/sparql-editor-steps.js +18 -4
- package/steps/ttyg/ttyg-agent-settings-modal.steps.js +1 -1
- package/steps/visual-graph-split-button-steps.js +45 -0
- package/steps/visual-graph-steps.js +69 -3
- package/steps/yasgui/yasr-steps.js +30 -6
- package/stubs/cluster/remote-location-stubs.js +4 -0
- package/stubs/graph-config-stubs.js +17 -0
- package/stubs/guides/guides-stubs.js +8 -0
- package/stubs/repositories/repositories-stubs.js +22 -0
- package/stubs/security-stubs.js +4 -0
- package/stubs/sparql-stubs.js +10 -0
- package/support/commands.js +1 -0
- package/support/e2e-security.js +1 -1
- package/support/repository-commands.js +22 -3
- package/support/settings-commands.js +18 -2
- package/support/url-commands.js +13 -0
- package/e2e-legacy/home/cookie-policy.spec.js +0 -108
|
@@ -2,7 +2,12 @@ import {UserAndAccessSteps} from "../../../steps/setup/user-and-access-steps";
|
|
|
2
2
|
import {LicenseStubs} from "../../../stubs/license-stubs";
|
|
3
3
|
import {LoginSteps} from "../../../steps/login-steps";
|
|
4
4
|
import {ModalDialogSteps} from "../../../steps/modal-dialog-steps";
|
|
5
|
-
import
|
|
5
|
+
import {MainMenuSteps} from '../../../steps/main-menu-steps.js';
|
|
6
|
+
import {CookieConsentBannerSteps} from '../../../steps/cookie-policy/cookie-consent-banner-steps.js';
|
|
7
|
+
import ImportSteps from '../../../steps/import/import-steps.js';
|
|
8
|
+
import {CookiePolicyModalSteps} from '../../../steps/cookie-policy/cookie-policy-modal.steps.js';
|
|
9
|
+
import {SettingsSteps} from '../../../steps/setup/settings-steps.js';
|
|
10
|
+
import {HeaderSteps} from '../../../steps/header-steps.js';
|
|
6
11
|
|
|
7
12
|
Cypress.env('set_default_user_data', false);
|
|
8
13
|
|
|
@@ -15,7 +20,7 @@ describe('Cookie policy', () => {
|
|
|
15
20
|
cy.switchOffFreeAccess(true);
|
|
16
21
|
cy.switchOffSecurity(true);
|
|
17
22
|
});
|
|
18
|
-
cy.setDefaultUserData(
|
|
23
|
+
cy.setDefaultUserData(undefined);
|
|
19
24
|
LicenseStubs.stubFreeLicense();
|
|
20
25
|
repository = 'cypress-test-cookie-policy-security-' + Date.now();
|
|
21
26
|
cy.createRepository({id: repository});
|
|
@@ -26,10 +31,231 @@ describe('Cookie policy', () => {
|
|
|
26
31
|
cy.loginAsAdmin().then(() => {
|
|
27
32
|
cy.switchOffFreeAccess(true);
|
|
28
33
|
cy.switchOffSecurity(true);
|
|
29
|
-
cy.setDefaultUserData();
|
|
34
|
+
cy.setDefaultUserData(undefined);
|
|
30
35
|
});
|
|
31
36
|
});
|
|
32
37
|
|
|
38
|
+
// Scenario 5
|
|
39
|
+
it('should hide cookie consent banner when security is ON and user is logged out', () => {
|
|
40
|
+
// Given I open user and access page in prod mode
|
|
41
|
+
UserAndAccessSteps.visitInProdMode();
|
|
42
|
+
// Then the cookie policy banner should be visible
|
|
43
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('exist').and('be.visible');
|
|
44
|
+
// When I enable security
|
|
45
|
+
UserAndAccessSteps.toggleSecurity();
|
|
46
|
+
// Then I should be logged out
|
|
47
|
+
LoginSteps.getLoginPage().should('be.visible');
|
|
48
|
+
// And the cookie policy banner should be hidden
|
|
49
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
50
|
+
// When I login with admin
|
|
51
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
52
|
+
// Then the cookie policy banner should be visible
|
|
53
|
+
UserAndAccessSteps.getUsersTable().should('be.visible');
|
|
54
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('exist').and('be.visible');
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
// Scenario 6
|
|
58
|
+
it('should give cookie consent when security is ON', () => {
|
|
59
|
+
// Given I open user and access page in prod mode
|
|
60
|
+
UserAndAccessSteps.visitInProdMode();
|
|
61
|
+
// When I enable security
|
|
62
|
+
UserAndAccessSteps.toggleSecurity();
|
|
63
|
+
// Then I should be logged out
|
|
64
|
+
LoginSteps.getLoginPage().should('be.visible');
|
|
65
|
+
// When I login with admin
|
|
66
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
67
|
+
// Then I should see the users and access page
|
|
68
|
+
UserAndAccessSteps.getUsersTable().should('be.visible');
|
|
69
|
+
// Then the cookie policy banner should be visible
|
|
70
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('be.visible');
|
|
71
|
+
// When I click OK in the cookie consent banner
|
|
72
|
+
CookieConsentBannerSteps.giveCookieConsent();
|
|
73
|
+
// Then the cookie policy banner should be hidden
|
|
74
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
75
|
+
// When I open another page
|
|
76
|
+
MainMenuSteps.clickOnMenuImport();
|
|
77
|
+
ImportSteps.getView().should('be.visible');
|
|
78
|
+
// Then the cookie policy banner should be hidden
|
|
79
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
80
|
+
// When I reload the page
|
|
81
|
+
cy.reload();
|
|
82
|
+
// Then the cookie policy banner should be hidden
|
|
83
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
84
|
+
});
|
|
85
|
+
|
|
86
|
+
// Scenario 7
|
|
87
|
+
it('should update cookie policy and give cookie consent when security is ON', () => {
|
|
88
|
+
// Given I open user and access page in prod mode
|
|
89
|
+
UserAndAccessSteps.visitInProdMode();
|
|
90
|
+
// And I enable security
|
|
91
|
+
UserAndAccessSteps.toggleSecurity();
|
|
92
|
+
// And I login with admin
|
|
93
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
94
|
+
// When I click on the cookie policy link in the banner
|
|
95
|
+
CookieConsentBannerSteps.clickCookiePolicyLink();
|
|
96
|
+
// Then I see the cookie policy
|
|
97
|
+
CookiePolicyModalSteps.getDialogComponent().should('be.visible');
|
|
98
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(true, true);
|
|
99
|
+
// When I toggle off the analytics cookie checkbox
|
|
100
|
+
CookiePolicyModalSteps.toggleStatisticCookies();
|
|
101
|
+
// And I close the dialog
|
|
102
|
+
CookiePolicyModalSteps.closeDialog();
|
|
103
|
+
CookiePolicyModalSteps.getDialog().should('not.exist');
|
|
104
|
+
// When I reload the page
|
|
105
|
+
cy.reload();
|
|
106
|
+
// Then I expect to see that analytic cookies are not allowed and third party cookies are allowed
|
|
107
|
+
CookieConsentBannerSteps.clickCookiePolicyLink();
|
|
108
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(false, true);
|
|
109
|
+
// And I close the cookie policy dialog
|
|
110
|
+
CookiePolicyModalSteps.closeDialog();
|
|
111
|
+
// When I open my settings page
|
|
112
|
+
MainMenuSteps.clickOnMySettings();
|
|
113
|
+
// And I open cookie policy modal using the button in the my settings widget
|
|
114
|
+
SettingsSteps.clickCookiePolicyLink();
|
|
115
|
+
// Then I should see the cookie policy
|
|
116
|
+
CookiePolicyModalSteps.getDialogComponent().should('be.visible');
|
|
117
|
+
// And I expect to see that analytic cookies are not allowed and third party cookies are allowed
|
|
118
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(false, true);
|
|
119
|
+
// When I toggle off third party cookies checkbox
|
|
120
|
+
CookiePolicyModalSteps.toggleThirdPartyCookies();
|
|
121
|
+
// And I close the modal
|
|
122
|
+
CookiePolicyModalSteps.closeDialog();
|
|
123
|
+
// When I reopen modal from the widget
|
|
124
|
+
SettingsSteps.clickCookiePolicyLink();
|
|
125
|
+
// Then I expect to see that analytic cookies are not allowed and third party cookies are not allowed
|
|
126
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(false, false);
|
|
127
|
+
CookiePolicyModalSteps.closeDialog();
|
|
128
|
+
// When I click OK in the banner
|
|
129
|
+
CookieConsentBannerSteps.giveCookieConsent();
|
|
130
|
+
// Then I expect the banner to be hidden
|
|
131
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
132
|
+
// When I reload the page
|
|
133
|
+
cy.reload();
|
|
134
|
+
// Then I expect the banner to be hidden
|
|
135
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
136
|
+
// When I logout
|
|
137
|
+
LoginSteps.logout();
|
|
138
|
+
// Then I should see the login page
|
|
139
|
+
LoginSteps.getLoginPage().should('be.visible');
|
|
140
|
+
// And the cookie policy banner should be hidden
|
|
141
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
142
|
+
// When I login with admin
|
|
143
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
144
|
+
// Then the cookie policy banner should be hidden
|
|
145
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
146
|
+
// When I open cookie policy modal from the widget
|
|
147
|
+
SettingsSteps.clickCookiePolicyLink();
|
|
148
|
+
// Then I expect to see that analytic cookies are not allowed and third party cookies are not allowed
|
|
149
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(false, false);
|
|
150
|
+
// When I toggle on third party cookies checkbox
|
|
151
|
+
CookiePolicyModalSteps.toggleThirdPartyCookies();
|
|
152
|
+
// And I close the modal
|
|
153
|
+
CookiePolicyModalSteps.closeDialog();
|
|
154
|
+
// When I reload the page
|
|
155
|
+
cy.reload();
|
|
156
|
+
// Then I expect to see that analytic cookies are not allowed and third party cookies are allowed
|
|
157
|
+
SettingsSteps.clickCookiePolicyLink();
|
|
158
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(false, true);
|
|
159
|
+
});
|
|
160
|
+
|
|
161
|
+
// Scenario 8
|
|
162
|
+
it('should update cookie policy and give cookie consent when security is ON and free access is ON', () => {
|
|
163
|
+
// Given I open user and access page in prod mode
|
|
164
|
+
UserAndAccessSteps.visitInProdMode();
|
|
165
|
+
// And I enable security
|
|
166
|
+
UserAndAccessSteps.toggleSecurity();
|
|
167
|
+
// And I login with admin
|
|
168
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
169
|
+
// And I enable free access
|
|
170
|
+
UserAndAccessSteps.toggleFreeAccess();
|
|
171
|
+
UserAndAccessSteps.clickFreeWriteAccessRepo(repository);
|
|
172
|
+
ModalDialogSteps.clickOKButton();
|
|
173
|
+
// Then the cookie policy banner should be visible
|
|
174
|
+
CookieConsentBannerSteps.getCookieConsentBanner().and('be.visible');
|
|
175
|
+
// When I click on the cookie policy link in the banner
|
|
176
|
+
CookieConsentBannerSteps.clickCookiePolicyLink();
|
|
177
|
+
// Then I see the cookie policy
|
|
178
|
+
CookiePolicyModalSteps.getDialogComponent().should('be.visible');
|
|
179
|
+
// And I expect to see that analytic and third party cookies are allowed
|
|
180
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(true, true);
|
|
181
|
+
// When I toggle off the analytics cookie checkbox
|
|
182
|
+
// The policy is saved on the server
|
|
183
|
+
CookiePolicyModalSteps.toggleStatisticCookies();
|
|
184
|
+
// And I close the dialog
|
|
185
|
+
CookiePolicyModalSteps.closeDialog();
|
|
186
|
+
CookiePolicyModalSteps.getDialog().should('not.exist');
|
|
187
|
+
// When I logout
|
|
188
|
+
HeaderSteps.logout();
|
|
189
|
+
// Then I should still see the user and access page but I have no access to it which is unimportant for this test
|
|
190
|
+
cy.url().should('include', '/users');
|
|
191
|
+
// And the cookie policy banner should be visible
|
|
192
|
+
CookieConsentBannerSteps.getCookieConsentBanner().and('be.visible');
|
|
193
|
+
// When I click on the cookie policy link in the banner
|
|
194
|
+
CookieConsentBannerSteps.clickCookiePolicyLink();
|
|
195
|
+
// Then I see the cookie policy
|
|
196
|
+
CookiePolicyModalSteps.getDialogComponent().should('be.visible');
|
|
197
|
+
// And I expect to see that analytic cookies are allowed and third party cookies are allowed
|
|
198
|
+
// (using browser data, because user is logged out)
|
|
199
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(true, true);
|
|
200
|
+
// And I close the cookie policy modal
|
|
201
|
+
CookiePolicyModalSteps.closeDialog();
|
|
202
|
+
// When I open another page
|
|
203
|
+
MainMenuSteps.clickOnMenuImport();
|
|
204
|
+
// Then the cookie policy banner should be visible
|
|
205
|
+
CookieConsentBannerSteps.getCookieConsentBanner().and('be.visible');
|
|
206
|
+
// When I give cookie consent
|
|
207
|
+
CookieConsentBannerSteps.giveCookieConsent();
|
|
208
|
+
// Then the cookie policy banner should be hidden
|
|
209
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
210
|
+
// When I open another page
|
|
211
|
+
MainMenuSteps.clickOnSparqlMenu();
|
|
212
|
+
cy.url().should('include', '/sparql');
|
|
213
|
+
// Then the cookie policy banner should be hidden
|
|
214
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
215
|
+
// When I reload the page
|
|
216
|
+
cy.reload();
|
|
217
|
+
// Then the cookie policy banner should be hidden
|
|
218
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
219
|
+
// When I login with admin
|
|
220
|
+
HeaderSteps.login();
|
|
221
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
222
|
+
cy.url().should('include', '/sparql');
|
|
223
|
+
// Then the cookie policy banner should be visible (because consent is saved on the server, but user has no changes persisted on server, so defaults are considered)
|
|
224
|
+
CookieConsentBannerSteps.getCookieConsentBanner().and('be.visible');
|
|
225
|
+
// When I click on the cookie policy link in the banner
|
|
226
|
+
CookieConsentBannerSteps.clickCookiePolicyLink();
|
|
227
|
+
// Then I see the cookie policy
|
|
228
|
+
CookiePolicyModalSteps.getDialogComponent().should('be.visible');
|
|
229
|
+
// And I expect to see that analytic cookies are allowed and third party cookies are allowed
|
|
230
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(false, true);
|
|
231
|
+
// When I toggle off third party cookies checkbox
|
|
232
|
+
CookiePolicyModalSteps.toggleThirdPartyCookies();
|
|
233
|
+
// And I close the modal
|
|
234
|
+
CookiePolicyModalSteps.closeDialog();
|
|
235
|
+
// When I reopen modal from the banner button
|
|
236
|
+
CookieConsentBannerSteps.clickCookiePolicyLink();
|
|
237
|
+
// Then I expect to see that analytic cookies are allowed and third party cookies are not allowed
|
|
238
|
+
CookiePolicyModalSteps.validateCookiePolicyDialog(false, false);
|
|
239
|
+
CookiePolicyModalSteps.closeDialog();
|
|
240
|
+
// When I logout
|
|
241
|
+
HeaderSteps.logout();
|
|
242
|
+
// And the cookie policy banner should be hidden (using browser data)
|
|
243
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
244
|
+
// When I login with admin
|
|
245
|
+
HeaderSteps.login();
|
|
246
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
247
|
+
// Then the cookie policy banner should be visible (consent is persisted with the user on server)
|
|
248
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('be.visible');
|
|
249
|
+
// When I give cookie consent
|
|
250
|
+
CookieConsentBannerSteps.giveCookieConsent();
|
|
251
|
+
// Then the cookie policy banner should be hidden
|
|
252
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
253
|
+
// When I reload the page
|
|
254
|
+
cy.reload();
|
|
255
|
+
// Then the cookie policy banner should be hidden
|
|
256
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
257
|
+
});
|
|
258
|
+
|
|
33
259
|
it('should show the consent popup if free access is on and the user is on the login page', () => {
|
|
34
260
|
// Given: Security is enabled and free access is on
|
|
35
261
|
UserAndAccessSteps.visitInProdMode();
|
|
@@ -44,7 +270,7 @@ describe('Cookie policy', () => {
|
|
|
44
270
|
// When: The user visits the login page
|
|
45
271
|
LoginSteps.visitInProdMode();
|
|
46
272
|
// Then: The cookie policy popup should be shown
|
|
47
|
-
|
|
273
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('exist').and('be.visible');
|
|
48
274
|
});
|
|
49
275
|
|
|
50
276
|
it('should not show the consent popup if free access is off and the user is on the login page', () => {
|
|
@@ -57,8 +283,8 @@ describe('Cookie policy', () => {
|
|
|
57
283
|
// When: The user logs out and visits the login page
|
|
58
284
|
LoginSteps.logout();
|
|
59
285
|
// Then: The cookie policy popup should not be shown
|
|
60
|
-
|
|
286
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
61
287
|
LoginSteps.visitInProdMode();
|
|
62
|
-
|
|
288
|
+
CookieConsentBannerSteps.getCookieConsentBanner().should('not.exist');
|
|
63
289
|
});
|
|
64
290
|
});
|
|
@@ -3,6 +3,7 @@ import {UserAndAccessSteps} from "../../../steps/setup/user-and-access-steps";
|
|
|
3
3
|
import {LoginSteps} from "../../../steps/login-steps";
|
|
4
4
|
import {ToasterSteps} from "../../../steps/toaster-steps";
|
|
5
5
|
import {HeaderSteps} from '../../../steps/header-steps.js';
|
|
6
|
+
import HomeSteps from '../../../steps/home-steps.js';
|
|
6
7
|
|
|
7
8
|
describe('Turn on Security', () => {
|
|
8
9
|
|
|
@@ -11,76 +12,88 @@ describe('Turn on Security', () => {
|
|
|
11
12
|
cy.switchOnSecurity();
|
|
12
13
|
});
|
|
13
14
|
|
|
14
|
-
afterEach(() =>{
|
|
15
|
+
afterEach(() => {
|
|
15
16
|
cy.loginAsAdmin();
|
|
16
17
|
cy.switchOffSecurity(true);
|
|
17
18
|
})
|
|
18
19
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
20
|
+
it('should enable security and show login screen', () => {
|
|
21
|
+
// Navigate to Users & Access
|
|
22
|
+
UserAndAccessSteps.visit();
|
|
23
|
+
// Verify we are redirected to login page
|
|
24
|
+
cy.url().should('include', '/login');
|
|
25
|
+
HeaderSteps.getHeader().should('not.exist');
|
|
26
|
+
MainMenuSteps.getMainMenu().should('not.exist');
|
|
27
|
+
});
|
|
27
28
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
29
|
+
it('should reject wrong credentials and accept admin/root', () => {
|
|
30
|
+
// Attempt login with invalid credentials
|
|
31
|
+
LoginSteps.visitLoginPage();
|
|
32
|
+
LoginSteps.loginWithUser('wrongUser', 'wrongPass');
|
|
33
|
+
// Expect error message
|
|
34
|
+
ToasterSteps.verifyNewToasterError('Wrong credentials');
|
|
34
35
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
36
|
+
// Login with correct admin credentials
|
|
37
|
+
LoginSteps.visitLoginPage();
|
|
38
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
39
|
+
cy.url().should('include', '/');
|
|
40
|
+
});
|
|
40
41
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
42
|
+
it('should show toaster after logging out', () => {
|
|
43
|
+
UserAndAccessSteps.visit();
|
|
44
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
45
|
+
// Verify we are logged in
|
|
46
|
+
UserAndAccessSteps.getUsersCatalogContainer().should('be.visible');
|
|
47
|
+
// Log out
|
|
48
|
+
HeaderSteps.logout();
|
|
49
|
+
cy.url().should('include', '/login');
|
|
50
|
+
// Verify toaster message
|
|
51
|
+
ToasterSteps.verifySuccess('Signed out');
|
|
52
|
+
})
|
|
47
53
|
|
|
48
|
-
|
|
49
|
-
|
|
54
|
+
describe('Password Change', () => {
|
|
55
|
+
afterEach(() => {
|
|
56
|
+
// Reset password back to original value for test isolation
|
|
57
|
+
UserAndAccessSteps.visit();
|
|
58
|
+
UserAndAccessSteps.openEditUserPage('admin');
|
|
59
|
+
UserAndAccessSteps.typePassword('root');
|
|
60
|
+
UserAndAccessSteps.typeConfirmPasswordField('root');
|
|
61
|
+
UserAndAccessSteps.confirmUserEdit();
|
|
62
|
+
UserAndAccessSteps.getUsersCatalogContainer().should('be.visible');
|
|
63
|
+
})
|
|
50
64
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
65
|
+
it('should change admin password and enforce new credentials', () => {
|
|
66
|
+
// Navigate to Users & Access after login
|
|
67
|
+
UserAndAccessSteps.visit();
|
|
68
|
+
// Verify we are redirected to login page
|
|
69
|
+
cy.url().should('include', '/login');
|
|
70
|
+
// Login with admin credentials
|
|
71
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
72
|
+
// Verify we are logged in
|
|
73
|
+
UserAndAccessSteps.getUsersCatalogContainer().should('be.visible');
|
|
56
74
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
cy.url().should('include', '/login');
|
|
75
|
+
// Open edit page for admin user
|
|
76
|
+
UserAndAccessSteps.openEditUserPage('admin');
|
|
60
77
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
78
|
+
// Change password to a new value
|
|
79
|
+
let newPassword = 'MyNewP@ssw0rd!';
|
|
80
|
+
UserAndAccessSteps.typePassword(newPassword);
|
|
81
|
+
UserAndAccessSteps.typeConfirmPasswordField(newPassword);
|
|
82
|
+
UserAndAccessSteps.confirmUserEdit();
|
|
64
83
|
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
MainMenuSteps.clickOnUsersAndAccess();
|
|
69
|
-
// Open edit page for admin user
|
|
70
|
-
UserAndAccessSteps.openEditUserPage('admin');
|
|
71
|
-
newPassword = 'root';
|
|
72
|
-
UserAndAccessSteps.typePassword(newPassword);
|
|
73
|
-
UserAndAccessSteps.typeConfirmPasswordField(newPassword);
|
|
74
|
-
UserAndAccessSteps.confirmUserEdit();
|
|
75
|
-
});
|
|
84
|
+
// Log out
|
|
85
|
+
LoginSteps.logout();
|
|
86
|
+
cy.url().should('include', '/login');
|
|
76
87
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
88
|
+
// Attempt login with old password
|
|
89
|
+
LoginSteps.loginWithUser('admin', 'root');
|
|
90
|
+
ToasterSteps.verifyNewToasterError('Wrong credentials');
|
|
91
|
+
|
|
92
|
+
// Attempt login with new password
|
|
93
|
+
LoginSteps.visitLoginPage();
|
|
94
|
+
LoginSteps.loginWithUser('admin', newPassword);
|
|
95
|
+
// Verify we are logged in and we are on the home page
|
|
96
|
+
HomeSteps.getView().should('be.visible');
|
|
97
|
+
});
|
|
98
|
+
});
|
|
86
99
|
});
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id": "de99fd5de7f94ef98f1875dff55fc1c9",
|
|
4
|
+
"name": "Graph Config 1",
|
|
5
|
+
"startMode": "search",
|
|
6
|
+
"owner": "admin",
|
|
7
|
+
"startQueryIncludeInferred": true,
|
|
8
|
+
"startQuerySameAs": true,
|
|
9
|
+
"startGraphQuery": "# CONSTRUCT or DESCRIBE query. The results will be rendered visually as a graph of triples.\nCONSTRUCT WHERE {\n\t?s ?p ?o\n} LIMIT 10",
|
|
10
|
+
"startIRI": null,
|
|
11
|
+
"startIRILabel": null,
|
|
12
|
+
"expandQuery": null,
|
|
13
|
+
"resourceQuery": null,
|
|
14
|
+
"predicateLabelQuery": null,
|
|
15
|
+
"resourcePropertiesQuery": null,
|
|
16
|
+
"shared": false,
|
|
17
|
+
"description": null,
|
|
18
|
+
"hint": null,
|
|
19
|
+
"repositoryId": "A_test"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"id": "94cab6579df445c68c454b2156013811",
|
|
23
|
+
"name": "Graph Config 1",
|
|
24
|
+
"startMode": "search",
|
|
25
|
+
"owner": "admin",
|
|
26
|
+
"startQueryIncludeInferred": true,
|
|
27
|
+
"startQuerySameAs": true,
|
|
28
|
+
"startGraphQuery": "# CONSTRUCT or DESCRIBE query. The results will be rendered visually as a graph of triples.\nCONSTRUCT WHERE {\n\t?s ?p ?o\n} LIMIT 10",
|
|
29
|
+
"startIRI": null,
|
|
30
|
+
"startIRILabel": null,
|
|
31
|
+
"expandQuery": null,
|
|
32
|
+
"resourceQuery": null,
|
|
33
|
+
"predicateLabelQuery": null,
|
|
34
|
+
"resourcePropertiesQuery": null,
|
|
35
|
+
"shared": false,
|
|
36
|
+
"description": null,
|
|
37
|
+
"hint": null,
|
|
38
|
+
"repositoryId": null
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"id": "94cab6579df445c68c454b2156013661",
|
|
42
|
+
"name": "Graph Config 1",
|
|
43
|
+
"startMode": "query",
|
|
44
|
+
"owner": "admin",
|
|
45
|
+
"startQueryIncludeInferred": true,
|
|
46
|
+
"startQuerySameAs": true,
|
|
47
|
+
"startGraphQuery": "# CONSTRUCT or DESCRIBE query. The results will be rendered visually as a graph of triples.\nCONSTRUCT WHERE {\n\t?s ?p ?o\n} LIMIT 10",
|
|
48
|
+
"startIRI": null,
|
|
49
|
+
"startIRILabel": null,
|
|
50
|
+
"expandQuery": null,
|
|
51
|
+
"resourceQuery": null,
|
|
52
|
+
"predicateLabelQuery": null,
|
|
53
|
+
"resourcePropertiesQuery": null,
|
|
54
|
+
"shared": false,
|
|
55
|
+
"description": null,
|
|
56
|
+
"hint": null,
|
|
57
|
+
"repositoryId": null
|
|
58
|
+
}
|
|
59
|
+
]
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"guideName": {
|
|
4
|
+
"en": "Navigate microfrontends"
|
|
5
|
+
},
|
|
6
|
+
"guideDescription": {
|
|
7
|
+
"en": "Navigate microfrontends"
|
|
8
|
+
},
|
|
9
|
+
"steps": [
|
|
10
|
+
{
|
|
11
|
+
"guideBlockName": "read-only-element",
|
|
12
|
+
"options": {
|
|
13
|
+
"url": "404",
|
|
14
|
+
"elementSelector": "[guide-selector=\"not-found-banner\"]",
|
|
15
|
+
"title": "Navigation",
|
|
16
|
+
"content": "This is a 404 page"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"guideBlockName": "clickable-element",
|
|
21
|
+
"options": {
|
|
22
|
+
"url": "404",
|
|
23
|
+
"elementSelector": "[guide-selector=\"go-back-home-btn\"]",
|
|
24
|
+
"title": "Navigation",
|
|
25
|
+
"disableNextFlow": true,
|
|
26
|
+
"content": "This is the go back home button"
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"guideBlockName": "clickable-element",
|
|
31
|
+
"options": {
|
|
32
|
+
"elementSelector": "[guide-selector=\"tutorial-container\"]",
|
|
33
|
+
"title": "Navigation",
|
|
34
|
+
"content": "This is the home page"
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"guideBlockName": "read-only-element",
|
|
39
|
+
"options": {
|
|
40
|
+
"url": "sparql-new",
|
|
41
|
+
"elementSelector": "[guide-selector=\"sparql-editor\"]",
|
|
42
|
+
"title": "Navigation",
|
|
43
|
+
"content": "This is the new sparql view"
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"guideBlockName": "read-only-element",
|
|
48
|
+
"options": {
|
|
49
|
+
"url": "import",
|
|
50
|
+
"elementSelector": "[guide-selector=\"uploadRdfFileButton\"]",
|
|
51
|
+
"title": "Navigation",
|
|
52
|
+
"content": "This is the import view"
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"guideBlockName": "guide-end"
|
|
57
|
+
}
|
|
58
|
+
]
|
|
59
|
+
}
|
|
60
|
+
]
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"guideName": {
|
|
4
|
+
"en": "Create visual graph config guide"
|
|
5
|
+
},
|
|
6
|
+
"steps": [
|
|
7
|
+
{
|
|
8
|
+
"guideBlockName": "visual-graph-config-create",
|
|
9
|
+
"options": {
|
|
10
|
+
"configDescription": "my description",
|
|
11
|
+
"configHint": "my hint",
|
|
12
|
+
"shareConfig": true,
|
|
13
|
+
"linkLimit": 200,
|
|
14
|
+
"expandIri": "http://www.w3.org/TR/2003/PR-owl-guide-20031209/wine#WineGrape",
|
|
15
|
+
"iriLabel": "WineGrape",
|
|
16
|
+
"tabConfig": [
|
|
17
|
+
{
|
|
18
|
+
"tabName": "startingPoint",
|
|
19
|
+
"startingPoint": "fixed",
|
|
20
|
+
"searchTerm": "MerlotGrape",
|
|
21
|
+
"iri": "http://www.w3.org/TR/2003/PR-owl-guide-20031209/wine#MerlotGrape"
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"tabName": "graphExpansion",
|
|
25
|
+
"query": "construct {\n ?node ?p ?o .\n ?s ?p ?node .\n} where {\n { ?node ?p ?o . }\n union\n { ?s ?p ?node . }\n}",
|
|
26
|
+
"queryExtraContent": "The graph expansion query defines what happens when a node is expanded in the visual graph. Expanding a node loads additional resources connected to it and adds them to the graph as new nodes and edges.",
|
|
27
|
+
"sampleQueryContent": "The <b>Sample queries</b> includes example graph expansion queries. <b>Unfiltered object properties</b> shows all object property connections of a node, while <b>Filtered object properties</b> shows only selected ones.",
|
|
28
|
+
"includeInferredData": true,
|
|
29
|
+
"expandResultsOverOwl": true
|
|
30
|
+
}
|
|
31
|
+
]
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"guideBlockName": "guide-end"
|
|
36
|
+
}
|
|
37
|
+
]
|
|
38
|
+
}
|
|
39
|
+
]
|