cy: no more naviagte

This commit is contained in:
Jean-Baptiste Pasquier
2020-09-17 13:08:44 +02:00
parent 9a0beef4fb
commit 4ab6ab9764
16 changed files with 133 additions and 32 deletions

View File

@ -23,12 +23,20 @@ context('Retire Channel Browser Testing', () => {
it('should login', () => cy.login());
describe('Channel Retirement process', () => {
let channelsLength;
it('should visit the channels list screen', () => cy.naviagte('/admin'));
it('should visit the channels list screen', () => {
cy.visit('/admin');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/admin');
});
});
it('should visit the last channel edit screen', () => {
cy.get(menuQuery.join(' '))
.invoke('attr', 'data-src')
.then(url => cy.encodeUrl(url).then(id => {
cy.naviagte('/circle/@' + id + '/circle-information/circle-edit');
cy.visit('/circle/@' + id + '/circle-information/circle-edit');
cy.location().should((loc) => {
expect(loc.pathname).to.eq('/circle/@' + id + '/circle-information/circle-edit');
});
}));
});
it('should count the number of joined channels', () => {