This repository was archived by the owner on Dec 11, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 969
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4690 from bsclifton/bookmark-manager-style-update
Style updates to bookmark manager per @bradleyrichter
- Loading branch information
Showing
10 changed files
with
130 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
/* global describe, it, before */ | ||
|
||
const Brave = require('../lib/brave') | ||
const {urlInput} = require('../lib/selectors') | ||
const {getTargetAboutUrl} = require('../../js/lib/appUrlUtil') | ||
const siteTags = require('../../js/constants/siteTags') | ||
const aboutBookmarksUrl = getTargetAboutUrl('about:bookmarks') | ||
|
||
describe('about:bookmarks', function () { | ||
Brave.beforeAll(this) | ||
|
||
const folderId = Math.random() | ||
const lastVisit = 1476140184441 | ||
const bookmarkTag = [siteTags.BOOKMARK] | ||
|
||
before(function * () { | ||
yield this.app.client | ||
.waitUntilWindowLoaded() | ||
.waitForUrl(Brave.newTabUrl) | ||
.waitForBrowserWindow() | ||
.waitForVisible(urlInput) | ||
.windowByUrl(Brave.browserWindowUrl) | ||
.addSite({ | ||
customTitle: 'demo1', | ||
folderId: folderId, | ||
parentFolderId: 0, | ||
tags: [siteTags.BOOKMARK_FOLDER] | ||
}, siteTags.BOOKMARK_FOLDER) | ||
.addSite({ location: 'https://brave.com', title: 'Brave', tags: bookmarkTag, parentFolderId: 0, lastAccessedTime: lastVisit }, siteTags.BOOKMARK) | ||
.addSite({ location: 'https://brave.com/test', title: 'Test', customTitle: 'customTest', tags: bookmarkTag, parentFolderId: 0, lastAccessedTime: lastVisit }, siteTags.BOOKMARK) | ||
.addSite({ location: 'https://www.youtube.com', tags: bookmarkTag, parentFolderId: 0, lastAccessedTime: lastVisit }, siteTags.BOOKMARK) | ||
.addSite({ location: 'https://www.facebook.com', title: 'facebook', tags: bookmarkTag, parentFolderId: 0, lastAccessedTime: lastVisit }, siteTags.BOOKMARK) | ||
.addSite({ location: 'https://duckduckgo.com', title: 'duckduckgo', tags: bookmarkTag, parentFolderId: folderId, lastAccessedTime: lastVisit }, siteTags.BOOKMARK) | ||
.addSite({ location: 'https://google.com', title: 'Google', tags: bookmarkTag, parentFolderId: folderId, lastAccessedTime: lastVisit }, siteTags.BOOKMARK) | ||
.addSite({ location: 'https://bing.com', title: 'Bing', tags: bookmarkTag, parentFolderId: folderId, lastAccessedTime: lastVisit }, siteTags.BOOKMARK) | ||
.waitForExist('.tab[data-frame-key="1"]') | ||
.tabByIndex(0) | ||
.url(aboutBookmarksUrl) | ||
}) | ||
|
||
it('displays entries with title', function * () { | ||
yield this.app.client | ||
.waitForVisible('table.sortableTable td.title[data-sort="Brave"]') | ||
}) | ||
|
||
it('displays entries without a title using their URL', function * () { | ||
yield this.app.client | ||
.waitForVisible('table.sortableTable td.title[data-sort="https://www.youtube.com"]') | ||
}) | ||
|
||
it('displays entries using customTitle (if available)', function * () { | ||
yield this.app.client | ||
.waitForVisible('table.sortableTable td.title[data-sort="customTest"]') | ||
}) | ||
|
||
it('shows bookmark folders', function * () { | ||
yield this.app.client | ||
.waitForVisible('.bookmarkFolderList .listItem[data-folder-id="' + folderId + '"]') | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters