Adds a js-
class to allow for specs
Rspec was using a CSS class to check if the content was being rendered. Since the CSS has changed, the specs failed This commit replaces the CSS class with a `js-` prepended one to guarantee changing CSS won't break a pipeline
This commit is contained in:
parent
2fa9b1fe8b
commit
5ea377a492
2 changed files with 7 additions and 6 deletions
|
@ -270,6 +270,7 @@ export default {
|
||||||
/>
|
/>
|
||||||
<grouped-test-reports-app
|
<grouped-test-reports-app
|
||||||
v-if="mr.testResultsPath"
|
v-if="mr.testResultsPath"
|
||||||
|
class="js-reports-container"
|
||||||
:endpoint="mr.testResultsPath"
|
:endpoint="mr.testResultsPath"
|
||||||
/>
|
/>
|
||||||
<div class="mr-section-container">
|
<div class="mr-section-container">
|
||||||
|
|
|
@ -423,7 +423,7 @@ describe 'Merge request > User sees merge widget', :js do
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'shows test reports summary which includes the new failure' do
|
it 'shows test reports summary which includes the new failure' do
|
||||||
within(".mr-section-container") do
|
within(".js-reports-container") do
|
||||||
click_button 'Expand'
|
click_button 'Expand'
|
||||||
|
|
||||||
expect(page).to have_content('Test summary contained 1 failed test result out of 2 total tests')
|
expect(page).to have_content('Test summary contained 1 failed test result out of 2 total tests')
|
||||||
|
@ -438,7 +438,7 @@ describe 'Merge request > User sees merge widget', :js do
|
||||||
|
|
||||||
context 'when user clicks the new failure' do
|
context 'when user clicks the new failure' do
|
||||||
it 'shows the test report detail' do
|
it 'shows the test report detail' do
|
||||||
within(".mr-section-container") do
|
within(".js-reports-container") do
|
||||||
click_button 'Expand'
|
click_button 'Expand'
|
||||||
|
|
||||||
within(".js-report-section-container") do
|
within(".js-report-section-container") do
|
||||||
|
@ -468,7 +468,7 @@ describe 'Merge request > User sees merge widget', :js do
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'shows test reports summary which includes the existing failure' do
|
it 'shows test reports summary which includes the existing failure' do
|
||||||
within(".mr-section-container") do
|
within(".js-reports-container") do
|
||||||
click_button 'Expand'
|
click_button 'Expand'
|
||||||
|
|
||||||
expect(page).to have_content('Test summary contained 1 failed test result out of 2 total tests')
|
expect(page).to have_content('Test summary contained 1 failed test result out of 2 total tests')
|
||||||
|
@ -483,7 +483,7 @@ describe 'Merge request > User sees merge widget', :js do
|
||||||
|
|
||||||
context 'when user clicks the existing failure' do
|
context 'when user clicks the existing failure' do
|
||||||
it 'shows test report detail of it' do
|
it 'shows test report detail of it' do
|
||||||
within(".mr-section-container") do
|
within(".js-reports-container") do
|
||||||
click_button 'Expand'
|
click_button 'Expand'
|
||||||
|
|
||||||
within(".js-report-section-container") do
|
within(".js-report-section-container") do
|
||||||
|
@ -519,7 +519,7 @@ describe 'Merge request > User sees merge widget', :js do
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'shows test reports summary which includes the resolved failure' do
|
it 'shows test reports summary which includes the resolved failure' do
|
||||||
within(".mr-section-container") do
|
within(".js-reports-container") do
|
||||||
click_button 'Expand'
|
click_button 'Expand'
|
||||||
|
|
||||||
expect(page).to have_content('Test summary contained 1 fixed test result out of 2 total tests')
|
expect(page).to have_content('Test summary contained 1 fixed test result out of 2 total tests')
|
||||||
|
@ -533,7 +533,7 @@ describe 'Merge request > User sees merge widget', :js do
|
||||||
|
|
||||||
context 'when user clicks the resolved failure' do
|
context 'when user clicks the resolved failure' do
|
||||||
it 'shows test report detail of it' do
|
it 'shows test report detail of it' do
|
||||||
within(".mr-section-container") do
|
within(".js-reports-container") do
|
||||||
click_button 'Expand'
|
click_button 'Expand'
|
||||||
|
|
||||||
within(".js-report-section-container") do
|
within(".js-report-section-container") do
|
||||||
|
|
Loading…
Reference in a new issue