Skip to content
Snippets Groups Projects
Commit 8a9649e4 authored by Giannis Kopanas's avatar Giannis Kopanas Committed by Alexandros Georgantas
Browse files

feat(applicationmanager): bookbuilder read components types test

parent e4b98cd2
No related branches found
No related tags found
1 merge request!23Add dynamic component types
describe('BookBuilder', () => { describe('BookBuilder', () => {
before(() => { before(() => {
cy.exec('node ./scripts/truncateDB.js') cy.exec('node ./scripts/truncateDB.js')
cy.exec('node ./scripts/seedApplicationParameter.js')
cy.exec('node ./scripts/createBooksWithUsersAndTeams.js') cy.exec('node ./scripts/createBooksWithUsersAndTeams.js')
}) })
it('production editor can navigate to book builder for the book she/he is assigned on', () => { it('production editor can navigate to book builder for the book she/he is assigned on', () => {
...@@ -19,4 +20,17 @@ describe('BookBuilder', () => { ...@@ -19,4 +20,17 @@ describe('BookBuilder', () => {
cy.contains('BACKMATTER') cy.contains('BACKMATTER')
}) })
}) })
it('admin can see the correct bookComponent Types to coresponding divisions', () => {
// cy.login('admin')
// cy.getCollections().then(res => {
// const { body } = res
// const { data } = body
// const { getBookCollections } = data
// const collection = getBookCollections[0]
// const { books } = collection
// const productionEditorBook = books[0]
// cy.visit(`/books/${productionEditorBook.id}/book-builder`)
// cy.get('[data-test-id="book"]')
// })
})
}) })
...@@ -9,6 +9,6 @@ describe('Login page', () => { ...@@ -9,6 +9,6 @@ describe('Login page', () => {
cy.get('input[name="username"]').type(username) cy.get('input[name="username"]').type(username)
cy.get('input[name="password"]').type(password) cy.get('input[name="password"]').type(password)
cy.get('button[type="submit"]').click() cy.get('button[type="submit"]').click()
cy.url().should('include', '/books') cy.url().should('include', '/books')
}) })
}) })
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment