mirror of
https://github.com/EnixCoda/Gitako.git
synced 2026-03-11 08:54:44 +00:00
fix: selector of github file explorer
This commit is contained in:
parent
5664ea1de8
commit
2df0b6e515
2 changed files with 4 additions and 4 deletions
|
|
@ -11,7 +11,7 @@ describe(`in Gitako project page`, () => {
|
|||
// Expect Gitako sidebar to have expanded src to see contents
|
||||
await expectToFind(selectors.gitako.fileItemOf('src/components'))
|
||||
|
||||
await page.click(selectors.github.fileListItemOf('components'))
|
||||
await page.click(selectors.github.fileListItemLinkOf('components'))
|
||||
await waitForRedirect()
|
||||
|
||||
// Expect Gitako sidebar to have expanded components and see contents
|
||||
|
|
|
|||
|
|
@ -4,9 +4,9 @@ export const selectors = {
|
|||
fileContent: 'textarea[aria-label="file content"]',
|
||||
commitLinks: `main .TimelineItem-body ol li > div:nth-child(1) a[href*="/commit/"]`,
|
||||
// assume title contains `.` is file item
|
||||
fileListItemFileLinks: `#repo-content-turbo-frame [aria-labelledby="folders-and-files"] tr.react-directory-row td:not(.react-directory-row-name-cell-small-screen) .react-directory-filename-column .react-directory-truncate[title*="."] a`,
|
||||
fileListItemOf: (name: string) =>
|
||||
`#repo-content-turbo-frame [aria-labelledby="folders-and-files"] tr.react-directory-row td:not(.react-directory-row-name-cell-small-screen) [title="${name}"]`,
|
||||
fileListItemFileLinks: `table[aria-labelledby="folders-and-files"] tr.react-directory-row td.react-directory-row-name-cell-large-screen .react-directory-filename-column .react-directory-truncate a[aria-label$="(File)"]`,
|
||||
fileListItemLinkOf: (name: string) =>
|
||||
`table[aria-labelledby="folders-and-files"] tr.react-directory-row td.react-directory-row-name-cell-large-screen .react-directory-filename-column .react-directory-truncate a[title="${name}"]`,
|
||||
commitSummary: 'div.commit',
|
||||
navBarItemIssues: 'a[data-selected-links^="repo_issues "]',
|
||||
navBarItemPulls: 'a[data-selected-links^="repo_pulls "]',
|
||||
|
|
|
|||
Loading…
Reference in a new issue