我正在尝试编写多个测试(
it
块)在单个
spec.ts
文件(角度+NX项目)。我的问题是,在执行第一个测试之前,第二个测试已经开始执行,这会阻止第一个测试运行。
在下面的例子中,第二个
信息技术
阻止执行第一个:
import { login } from '../support/util';
/// <reference types="cypress-xpath" />
describe('merkur helper json-management functionality', () => {
before(() => cy.visit(Cypress.env('baseUrl')));
it('logs in and goto json-management module', async () => {
const uuid = () => Cypress._.random(0, 1e6)
const id = uuid()
const testFormName = `testname${id}`
login('sadmin', '87654321');
cy.wait(3000);
cy.visit(`${Cypress.env('CYPRESS_BASE_URL')}/#/json-management`);
cy.wait(1000);
cy.location('href').should('include', '/json-management');
cy.wait(1000);
});
it('should go into a distributor modules section', async () => {
cy.log('++++++++++++++++++++++++++++++++++++++')
});
});