test: add test for #2263
This commit is contained in:
parent
b1dc43a9c9
commit
7ebf8e7552
|
@ -2,8 +2,16 @@ import { loginAsLockedAccount } from '../roles'
|
||||||
import { followAs, unfollowAs } from '../serverActions'
|
import { followAs, unfollowAs } from '../serverActions'
|
||||||
import {
|
import {
|
||||||
avatarInComposeBox,
|
avatarInComposeBox,
|
||||||
communityNavButton, followersButton, getNthSearchResult, getSearchResultByHref, getUrl, goBack,
|
communityNavButton,
|
||||||
homeNavButton, sleep
|
followersButton,
|
||||||
|
getNthSearchResult,
|
||||||
|
getNthStatus,
|
||||||
|
getSearchResultByHref,
|
||||||
|
getUrl,
|
||||||
|
goBack,
|
||||||
|
homeNavButton,
|
||||||
|
notificationsNavButton,
|
||||||
|
sleep
|
||||||
} from '../utils'
|
} from '../utils'
|
||||||
import { users } from '../users'
|
import { users } from '../users'
|
||||||
import { Selector as $ } from 'testcafe'
|
import { Selector as $ } from 'testcafe'
|
||||||
|
@ -93,6 +101,9 @@ test('Shows unresolved follow requests', async t => {
|
||||||
|
|
||||||
await t
|
await t
|
||||||
.expect(communityNavButton.getAttribute('aria-label')).eql('Community (2 follow requests)')
|
.expect(communityNavButton.getAttribute('aria-label')).eql('Community (2 follow requests)')
|
||||||
|
.click(notificationsNavButton)
|
||||||
|
.expect(getUrl()).contains('/notifications')
|
||||||
|
.expect(getNthStatus(1).innerText).contains('requested to follow you')
|
||||||
.click(communityNavButton)
|
.click(communityNavButton)
|
||||||
.expect(requestsButton.innerText).contains('Follow requests (2)')
|
.expect(requestsButton.innerText).contains('Follow requests (2)')
|
||||||
.click(requestsButton)
|
.click(requestsButton)
|
||||||
|
|
Loading…
Reference in New Issue