Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
scratch-www
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
scratch-www
Commits
e0778424
Commit
e0778424
authored
Aug 30, 2021
by
BryceLTaylor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add studio transfer test
parent
9b3768ac
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
43 additions
and
0 deletions
+43
-0
test/integration/studios-page.test.js
test/integration/studios-page.test.js
+43
-0
No files found.
test/integration/studios-page.test.js
View file @
e0778424
...
...
@@ -147,4 +147,47 @@ describe('studio management', () => {
let
promoteSuccessVisible
=
await
promoteSuccess
.
isDisplayed
();
await
expect
(
promoteSuccessVisible
).
toBe
(
true
);
});
test
(
'
transfer studio host
'
,
async
()
=>
{
// sign in as user2
await
signIn
(
username2
,
password
,
driver
);
await
findByXpath
(
'
//span[contains(@class, "profile-name")]
'
);
// for some reason the user isn't showing up without reloading the page
await
driver
.
get
(
curatorTab
);
// open kebab menu
let
user2href
=
'
/users/
'
+
username2
;
// click kebab menu on the user tile
let
kebabMenuXpath
=
`//a[@href = "
${
user2href
}
"]/`
+
'
following-sibling::div[@class="overflow-menu-container"]
'
;
await
clickXpath
(
kebabMenuXpath
+
'
/button[@class="overflow-menu-trigger"]
'
);
// click transfer in dropdown
await
clickXpath
(
'
//button[@class="studio-member-tile-menu-wide"]
'
);
await
findByXpath
(
'
//div[contains(@class, "transfer-info-title")]
'
);
// click next button
await
clickXpath
(
'
//button[contains(@class, "next-button")]
'
);
await
findByXpath
(
'
//div[@class="transfer-selection-heading"]
'
);
// click user tile
await
clickXpath
(
`//div[contains(text(), "
${
username3
}
")]`
);
await
findByXpath
(
'
//div[contains(@class, "transfer-host-name-selected")]
'
);
// click next button
await
clickXpath
(
'
//button[contains(@class, "next-button")]
'
);
await
findByXpath
(
'
//div[@class="transfer-outcome"]
'
);
// enter password
let
passwordInput
=
await
findByXpath
(
'
//input[@class="transfer-password-input"]
'
);
await
passwordInput
.
sendKeys
(
password
);
await
findByXpath
(
`//input[@value="
${
password
}
"]`
);
// click confirm
// await clickXpath('//button[contains(@class, "confirm-transfer-button")]')
await
clickXpath
(
'
//span[contains(text(), "Confirm")]/..
'
);
let
transferSuccess
=
await
findByXpath
(
'
//div[contains(@class, "alert-success")]
'
);
let
successVisible
=
await
transferSuccess
.
isDisplayed
();
await
expect
(
successVisible
).
toBe
(
true
);
});
});
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment