Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
6ef590db
Commit
6ef590db
authored
Mar 04, 2020
by
Nick Thomas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Work around some failing specs
parent
c1e5ad36
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
16 additions
and
4 deletions
+16
-4
spec/features/issues/user_creates_issue_spec.rb
spec/features/issues/user_creates_issue_spec.rb
+1
-1
spec/features/projects/tags/user_edits_tags_spec.rb
spec/features/projects/tags/user_edits_tags_spec.rb
+1
-1
spec/features/uploads/user_uploads_file_to_note_spec.rb
spec/features/uploads/user_uploads_file_to_note_spec.rb
+1
-1
spec/support/capybara.rb
spec/support/capybara.rb
+12
-0
spec/support/shared_examples/features/wiki_file_attachments_shared_examples.rb
...xamples/features/wiki_file_attachments_shared_examples.rb
+1
-1
No files found.
spec/features/issues/user_creates_issue_spec.rb
View file @
6ef590db
...
@@ -156,7 +156,7 @@ describe "User creates issue" do
...
@@ -156,7 +156,7 @@ describe "User creates issue" do
expect
(
page
.
find_field
(
"issue_description"
).
value
).
not_to
match
/\n\n$/
expect
(
page
.
find_field
(
"issue_description"
).
value
).
not_to
match
/\n\n$/
end
end
it
"cancels a file upload correctly"
do
it
"cancels a file upload correctly"
,
:capybara_ignore_server_errors
do
slow_requests
do
slow_requests
do
dropzone_file
([
Rails
.
root
.
join
(
'spec'
,
'fixtures'
,
'dk.png'
)],
0
,
false
)
dropzone_file
([
Rails
.
root
.
join
(
'spec'
,
'fixtures'
,
'dk.png'
)],
0
,
false
)
...
...
spec/features/projects/tags/user_edits_tags_spec.rb
View file @
6ef590db
...
@@ -68,7 +68,7 @@ describe 'Project > Tags', :js do
...
@@ -68,7 +68,7 @@ describe 'Project > Tags', :js do
end
end
end
end
it
'shows "Attaching a file" message on uploading 1 file'
,
:js
do
it
'shows "Attaching a file" message on uploading 1 file'
,
:js
,
:capybara_ignore_server_errors
do
slow_requests
do
slow_requests
do
dropzone_file
([
Rails
.
root
.
join
(
'spec'
,
'fixtures'
,
'dk.png'
)],
0
,
false
)
dropzone_file
([
Rails
.
root
.
join
(
'spec'
,
'fixtures'
,
'dk.png'
)],
0
,
false
)
...
...
spec/features/uploads/user_uploads_file_to_note_spec.rb
View file @
6ef590db
...
@@ -22,7 +22,7 @@ describe 'User uploads file to note' do
...
@@ -22,7 +22,7 @@ describe 'User uploads file to note' do
end
end
end
end
context
'uploading is in progress'
do
context
'uploading is in progress'
,
:capybara_ignore_server_errors
do
it
'cancels uploading on clicking to "Cancel" button'
,
:js
do
it
'cancels uploading on clicking to "Cancel" button'
,
:js
do
slow_requests
do
slow_requests
do
dropzone_file
([
Rails
.
root
.
join
(
'spec'
,
'fixtures'
,
'dk.png'
)],
0
,
false
)
dropzone_file
([
Rails
.
root
.
join
(
'spec'
,
'fixtures'
,
'dk.png'
)],
0
,
false
)
...
...
spec/support/capybara.rb
View file @
6ef590db
...
@@ -113,6 +113,18 @@ RSpec.configure do |config|
...
@@ -113,6 +113,18 @@ RSpec.configure do |config|
end
end
end
end
# The :capybara_ignore_server_errors metadata means unhandled exceptions raised
# by the application under test will not necessarily fail the server. This is
# useful when testing conditions that are expected to raise a 500 error in
# production; it should not be used on the happy path.
config
.
around
(
:each
,
:capybara_ignore_server_errors
)
do
|
example
|
Capybara
.
raise_server_errors
=
false
example
.
run
ensure
Capybara
.
raise_server_errors
=
true
end
config
.
after
(
:example
,
:js
)
do
|
example
|
config
.
after
(
:example
,
:js
)
do
|
example
|
# when a test fails, display any messages in the browser's console
# when a test fails, display any messages in the browser's console
# but fail don't add the message if the failure is a pending test that got
# but fail don't add the message if the failure is a pending test that got
...
...
spec/support/shared_examples/features/wiki_file_attachments_shared_examples.rb
View file @
6ef590db
...
@@ -20,7 +20,7 @@ RSpec.shared_examples 'wiki file attachments' do
...
@@ -20,7 +20,7 @@ RSpec.shared_examples 'wiki file attachments' do
end
end
end
end
context
'uploading is in progress'
do
context
'uploading is in progress'
,
:capybara_ignore_server_errors
do
it
'cancels uploading on clicking to "Cancel" button'
do
it
'cancels uploading on clicking to "Cancel" button'
do
slow_requests
do
slow_requests
do
attach_with_dropzone
attach_with_dropzone
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment