Skip to content
Snippets Groups Projects
Commit 65ae869b authored by Clayton, Brandon Scott's avatar Clayton, Brandon Scott
Browse files

add hazard utils

parent 0345b875
No related branches found
No related tags found
2 merge requests!147Production Release | nshmp-apps,!143Cypress tests
import * as utils from './utils';
export function hasHazardModelMenu() {
it('Has model menu', () => {
cy.get('nshmp-template-control-panel')
.find('hazard-lib-model-form')
.scrollIntoView()
.find('mat-select')
.should('be.visible');
});
}
export function setHazardCommonControlPanel() {
utils.setInput('.latitude-input', '34');
utils.setInput('.longitude-input', '-118');
cy.get('nshmp-template-control-panel')
.find('hazard-lib-site-class-form')
.scrollIntoView()
.find('mat-select')
.click();
utils.selectMatOption('BC');
utils.setInput('hazard-lib-return-period-form', '2475');
}
export function setHazardMaxDirection() {
cy.get('nshmp-template-control-panel')
.find('hazard-lib-max-direction-form')
.scrollIntoView()
.find('mat-checkbox')
.should('not.have.class', 'mat-checkbox-checked')
.should('be.visible')
.find('label')
.click()
.parent()
.should('have.class', 'mat-checkbox-checked');
}
export function setHazardTruncate() {
cy.get('nshmp-template-control-panel')
.find('hazard-lib-truncation-form')
.scrollIntoView()
.find('mat-checkbox')
.should('not.have.class', 'mat-checkbox-checked')
.should('be.visible')
.find('label')
.click()
.parent()
.should('have.class', 'mat-checkbox-checked');
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment