From 50fd74bb6ae86bab64acb08dde192453a8e98b12 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Thu, 11 Aug 2022 14:14:47 +0200 Subject: [PATCH] Remove tests of disabled cancel button, because they are always enabled yet --- .../Contributions/ContributionForm.spec.js | 36 ++++--------------- 1 file changed, 7 insertions(+), 29 deletions(-) diff --git a/frontend/src/components/Contributions/ContributionForm.spec.js b/frontend/src/components/Contributions/ContributionForm.spec.js index 24b1f6cb3..cf47577a3 100644 --- a/frontend/src/components/Contributions/ContributionForm.spec.js +++ b/frontend/src/components/Contributions/ContributionForm.spec.js @@ -46,13 +46,7 @@ describe('ContributionForm', () => { }) describe('empty form data', () => { - describe('buttons', () => { - it('has reset enabled', () => { - expect( - wrapper.find('button[data-test="button-cancel"]').attributes('disabled'), - ).toBeFalsy() - }) - + describe('button', () => { it('has submit disabled', () => { expect(wrapper.find('button[data-test="button-submit"]').attributes('disabled')).toBe( 'disabled', @@ -232,7 +226,7 @@ describe('ContributionForm', () => { await wrapper.find('#contribution-memo').find('textarea').setValue('1234') }) - describe('buttons', () => { + describe('button', () => { describe('submit', () => { it('has disabled', () => { expect( @@ -256,7 +250,7 @@ describe('ContributionForm', () => { await wrapper.vm.$nextTick() }) - describe('buttons', () => { + describe('button', () => { describe('submit', () => { it('has disabled', () => { expect( @@ -278,15 +272,7 @@ describe('ContributionForm', () => { await wrapper.find('#contribution-amount').find('input').setValue('200') }) - describe('buttons', () => { - describe('reset', () => { - it('has enabled', () => { - expect( - wrapper.find('button[data-test="button-cancel"]').attributes('disabled'), - ).toBeFalsy() - }) - }) - + describe('button', () => { describe('submit', () => { it('has enabled', () => { expect( @@ -352,7 +338,7 @@ describe('ContributionForm', () => { await wrapper.find('#contribution-memo').find('textarea').setValue('1234') }) - describe('buttons', () => { + describe('button', () => { describe('submit', () => { it('has disabled', () => { expect( @@ -376,7 +362,7 @@ describe('ContributionForm', () => { await wrapper.vm.$nextTick() }) - describe('buttons', () => { + describe('button', () => { describe('submit', () => { it('has disabled', () => { expect( @@ -398,15 +384,7 @@ describe('ContributionForm', () => { await wrapper.find('#contribution-amount').find('input').setValue('200') }) - describe('buttons', () => { - describe('reset', () => { - it('has enabled', () => { - expect( - wrapper.find('button[data-test="button-cancel"]').attributes('disabled'), - ).toBeFalsy() - }) - }) - + describe('button', () => { describe('submit', () => { it('has enabled', () => { expect(