Update e2e test schema
This commit is contained in:
parent
65b25ed488
commit
ef5c1c6279
|
|
@ -15,6 +15,7 @@
|
|||
},
|
||||
"onboardingVisited": false,
|
||||
"__typename": "UserNode",
|
||||
"permissions": []
|
||||
"permissions": [],
|
||||
"team": null
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,13 +4,16 @@ const schema = require('../../fixtures/schema.json');
|
|||
const me = require('../../fixtures/me.new-student.json');
|
||||
|
||||
describe('New student', () => {
|
||||
it('shows "Enter Code" page and adds the user to a class', () => {
|
||||
before(() => {
|
||||
cy.server();
|
||||
|
||||
cy.mockGraphql({
|
||||
schema: schema,
|
||||
cy.task('getSchema').then(schema => {
|
||||
cy.mockGraphql({
|
||||
schema,
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
it('shows "Enter Code" page and adds the user to a class', () => {
|
||||
cy.apolloLogin('hansli', 'test');
|
||||
|
||||
const __typename = 'SchoolClassNode';
|
||||
|
|
@ -26,9 +29,9 @@ describe('New student', () => {
|
|||
schoolClass: {
|
||||
id,
|
||||
name,
|
||||
__typename
|
||||
}
|
||||
}
|
||||
__typename,
|
||||
},
|
||||
},
|
||||
},
|
||||
MySchoolClassQuery: {
|
||||
me: {
|
||||
|
|
@ -37,12 +40,12 @@ describe('New student', () => {
|
|||
__typename,
|
||||
name,
|
||||
id,
|
||||
members: []
|
||||
}
|
||||
}
|
||||
members: [],
|
||||
},
|
||||
},
|
||||
},
|
||||
...mockUpdateOnboardingProgress()
|
||||
}
|
||||
...mockUpdateOnboardingProgress(),
|
||||
},
|
||||
});
|
||||
|
||||
cy.visit('/');
|
||||
|
|
|
|||
Loading…
Reference in New Issue