feat(tools): test file buttons (#44919)
* feat(tools): test file buttons * fix: set SHOW_NEW_CURRICULUM to true * fix: landing test
This commit is contained in:
@ -16,7 +16,8 @@ const certifications = [
|
|||||||
'Scientific Computing with Python',
|
'Scientific Computing with Python',
|
||||||
'Data Analysis with Python',
|
'Data Analysis with Python',
|
||||||
'Information Security',
|
'Information Security',
|
||||||
'Machine Learning with Python'
|
'Machine Learning with Python',
|
||||||
|
'Responsive Web Design (Beta)'
|
||||||
];
|
];
|
||||||
|
|
||||||
describe('Landing page', () => {
|
describe('Landing page', () => {
|
||||||
@ -57,7 +58,7 @@ describe('Landing page', () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it('Has links to all the certifications', function () {
|
it('Has links to all the certifications', function () {
|
||||||
cy.get(selectors.certifications).children().its('length').should('eq', 10);
|
cy.get(selectors.certifications).children().its('length').should('eq', 11);
|
||||||
cy.wrap(certifications).each(cert => {
|
cy.wrap(certifications).each(cert => {
|
||||||
cy.get(selectors.certifications).contains(cert);
|
cy.get(selectors.certifications).contains(cert);
|
||||||
});
|
});
|
||||||
|
14
cypress/integration/learn/challenges/multifile.js
Normal file
14
cypress/integration/learn/challenges/multifile.js
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
const location =
|
||||||
|
'/learn/2022/responsive-web-design/learn-accessibility-by-building-a-quiz/step-2';
|
||||||
|
|
||||||
|
describe('Challenge with multifile editor', () => {
|
||||||
|
before(() => {
|
||||||
|
cy.visit(location);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('renders the file tab buttons', () => {
|
||||||
|
cy.get('.monaco-editor-tabs').should('exist');
|
||||||
|
cy.get('.monaco-editor-tabs').contains('index.html');
|
||||||
|
cy.get('.monaco-editor-tabs').contains('styles.css');
|
||||||
|
});
|
||||||
|
});
|
@ -17,7 +17,8 @@ const superBlockNames = [
|
|||||||
'Data Analysis with Python Certification',
|
'Data Analysis with Python Certification',
|
||||||
'Information Security Certification',
|
'Information Security Certification',
|
||||||
'Machine Learning with Python Certification',
|
'Machine Learning with Python Certification',
|
||||||
'Coding Interview Prep (Thousands of hours of challenges)'
|
'Coding Interview Prep (Thousands of hours of challenges)',
|
||||||
|
'Responsive Web Design (Beta) Certification'
|
||||||
];
|
];
|
||||||
|
|
||||||
describe('Learn Landing page (not logged in)', () => {
|
describe('Learn Landing page (not logged in)', () => {
|
||||||
@ -41,7 +42,7 @@ describe('Learn Landing page (not logged in)', () => {
|
|||||||
const superBlocks = document.querySelectorAll(
|
const superBlocks = document.querySelectorAll(
|
||||||
`${selectors.challengeMap} > li > a`
|
`${selectors.challengeMap} > li > a`
|
||||||
);
|
);
|
||||||
expect(superBlocks).to.have.length(11);
|
expect(superBlocks).to.have.length(12);
|
||||||
|
|
||||||
superBlocks.forEach((superBlock, idx) => {
|
superBlocks.forEach((superBlock, idx) => {
|
||||||
expect(superBlock.innerText).to.have.string(superBlockNames[idx]);
|
expect(superBlock.innerText).to.have.string(superBlockNames[idx]);
|
||||||
|
@ -57,7 +57,7 @@ CURRICULUM_LOCALE=english
|
|||||||
|
|
||||||
# Show or hide WIP in progress challenges
|
# Show or hide WIP in progress challenges
|
||||||
SHOW_UPCOMING_CHANGES=false
|
SHOW_UPCOMING_CHANGES=false
|
||||||
SHOW_NEW_CURRICULUM=false
|
SHOW_NEW_CURRICULUM=true
|
||||||
|
|
||||||
# Application paths
|
# Application paths
|
||||||
HOME_LOCATION=http://localhost:8000
|
HOME_LOCATION=http://localhost:8000
|
||||||
|
Reference in New Issue
Block a user