Skip to content

Commit

Permalink
fix: dont navigate on each test, and remove unnecessary gets from cyp…
Browse files Browse the repository at this point in the history
…ress suite (#281)
  • Loading branch information
alharris-at authored Dec 7, 2021
1 parent 2f7f806 commit c72e66c
Show file tree
Hide file tree
Showing 10 changed files with 55 additions and 354 deletions.
203 changes: 0 additions & 203 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions packages/codegen-ui-react/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions packages/codegen-ui/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,11 @@
limitations under the License.
*/
describe('Complex Components', () => {
it('Successfully opens the app', () => {
before(() => {
cy.visit('http://localhost:3000/complex-tests');
});

it('Complex 1', () => {
cy.visit('http://localhost:3000/complex-tests');
cy.get('#complex-test-1').within(() => {
cy.get('.amplify-flex')
.should(
Expand All @@ -41,7 +40,6 @@ describe('Complex Components', () => {
});

it('Complex 2', () => {
cy.visit('http://localhost:3000/complex-tests');
cy.get('#complex-test-2').within(() => {
cy.get('.amplify-flex')
.should(
Expand Down Expand Up @@ -81,7 +79,6 @@ describe('Complex Components', () => {
});

it('Complex 3', () => {
cy.visit('http://localhost:3000/complex-tests');
cy.get('#complex-test-3').within(() => {
cy.get('.amplify-flex')
.should(
Expand Down Expand Up @@ -127,7 +124,6 @@ describe('Complex Components', () => {
});

it('Complex 4', () => {
cy.visit('http://localhost:3000/complex-tests');
cy.get('#complex-test-4').within(() => {
cy.get('.amplify-flex')
.should(
Expand Down Expand Up @@ -164,7 +160,6 @@ describe('Complex Components', () => {
});

it('Complex 5', () => {
cy.visit('http://localhost:3000/complex-tests');
cy.get('#complex-test-5').within(() => {
cy.get('.amplify-flex')
.should(
Expand Down Expand Up @@ -195,7 +190,6 @@ describe('Complex Components', () => {
});

it('Complex 6', () => {
cy.visit('http://localhost:3000/complex-tests');
cy.get('#complex-test-6').within(() => {
cy.get('.amplify-flex')
.should(
Expand Down Expand Up @@ -239,7 +233,6 @@ describe('Complex Components', () => {
});

it('Complex 7', () => {
cy.visit('http://localhost:3000/complex-tests');
cy.get('#complex-test-7').within(() => {
cy.get('div')
.should('have.attr', 'style', 'height: 192px; padding: 0px; position: relative; width: 401px;')
Expand Down Expand Up @@ -279,7 +272,6 @@ describe('Complex Components', () => {
});

it('Complex 8', () => {
cy.visit('http://localhost:3000/complex-tests');
cy.get('#complex-test-8').within(() => {
cy.get('.amplify-flex')
.should(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,11 @@ const EXPECTED_INTERNAL_ERROR_CASES = new Set([]);
const TARGET_GENERATORS = ['ES2016_TSX', 'ES2016_JSX', 'ES5_TSX', 'ES5_JSX'];

describe('Generate Components', () => {
it('Loads the page', () => {
before(() => {
cy.visit('http://localhost:3000/generate-tests');
});

it('Can generate all expected rows successfully', () => {
cy.visit('http://localhost:3000/generate-tests');
cy.get('.generateTest').each(($element) => {
const className = $element.attr('id').replace('generateTest', '');
cy.wrap($element).within(() => {
Expand Down
Loading

0 comments on commit c72e66c

Please sign in to comment.