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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
e5a81aec
Commit
e5a81aec
authored
Dec 28, 2018
by
Mark Lapierre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "Allow tests to be quarantined"
This reverts commit 8ef418d57c5a9511b862bf0711aadbb977086c91.
parent
89a79282
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
84 deletions
+14
-84
qa/qa/specs/runner.rb
qa/qa/specs/runner.rb
+0
-7
qa/spec/specs/runner_spec.rb
qa/spec/specs/runner_spec.rb
+14
-77
No files found.
qa/qa/specs/runner.rb
View file @
e5a81aec
...
...
@@ -23,9 +23,6 @@ module QA
args
.
push
(
%w[--tag ~orchestrated]
)
unless
(
%w[-t --tag]
&
options
).
any?
end
# Skip quarantined tests by default
args
.
push
(
%w[--tag ~quarantine]
)
unless
include_quarantine?
args
.
push
(
%w[--tag ~skip_signup_disabled]
)
if
QA
::
Runtime
::
Env
.
signup_disabled?
QA
::
Runtime
::
Env
.
supported_features
.
each_key
do
|
key
|
...
...
@@ -41,10 +38,6 @@ module QA
abort
if
status
.
nonzero?
end
end
def
include_quarantine?
tags
.
include?
(
:quarantine
)
||
options
.
include?
(
'quarantine'
)
end
end
end
end
qa/spec/specs/runner_spec.rb
View file @
e5a81aec
...
...
@@ -6,12 +6,8 @@ describe QA::Specs::Runner do
allow
(
QA
::
Runtime
::
Browser
).
to
receive
(
:configure!
)
end
it
'excludes the orchestrated and quarantine tags by default'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'--tag'
,
'~quarantine'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
it
'excludes the orchestrated tag by default'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
subject
.
perform
end
...
...
@@ -20,12 +16,7 @@ describe QA::Specs::Runner do
subject
{
described_class
.
new
.
tap
{
|
runner
|
runner
.
tty
=
true
}
}
it
'sets the `--tty` flag'
do
expect_rspec_runner_arguments
([
'--tty'
,
'--tag'
,
'~orchestrated'
,
'--tag'
,
'~quarantine'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
expect_rspec_runner_arguments
([
'--tty'
,
'--tag'
,
'~orchestrated'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
subject
.
perform
end
...
...
@@ -34,54 +25,18 @@ describe QA::Specs::Runner do
context
'when tags are set'
do
subject
{
described_class
.
new
.
tap
{
|
runner
|
runner
.
tags
=
%i[orchestrated github]
}
}
it
'focuses on the given tags, plus the ~quarantine tag'
do
expect_rspec_runner_arguments
([
'--tag'
,
'orchestrated'
,
'--tag'
,
'github'
,
'--tag'
,
'~quarantine'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
it
'focuses on the given tags'
do
expect_rspec_runner_arguments
([
'--tag'
,
'orchestrated'
,
'--tag'
,
'github'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
subject
.
perform
end
end
context
'when only "--tag quarantine" is set as options'
do
subject
{
described_class
.
new
.
tap
{
|
runner
|
runner
.
options
=
%w[--tag quarantine]
}
}
it
'focuses on the given tags without the default args'
do
expect_rspec_runner_arguments
([
'--tag'
,
'quarantine'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
subject
.
perform
end
end
context
'when only "--tag smoke" is set as options'
do
context
'when "--tag smoke" is set as options'
do
subject
{
described_class
.
new
.
tap
{
|
runner
|
runner
.
options
=
%w[--tag smoke]
}
}
it
'focuses on the given tag without the default args, but with the ~quarantine tag'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~quarantine'
,
'--tag'
,
'smoke'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
subject
.
perform
end
end
context
'when "--tag smoke" and "--tag quarantine" are set as options'
do
subject
{
described_class
.
new
.
tap
{
|
runner
|
runner
.
options
=
%w[--tag smoke --tag quarantine]
}
}
it
'focuses on the given tags without the default args'
do
expect_rspec_runner_arguments
([
'--tag'
,
'smoke'
,
'--tag'
,
'quarantine'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
it
'focuses on the given tag without excluded the orchestrated tag'
do
expect_rspec_runner_arguments
([
'--tag'
,
'smoke'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
subject
.
perform
end
...
...
@@ -90,12 +45,8 @@ describe QA::Specs::Runner do
context
'when "qa/specs/features/foo" is set as options'
do
subject
{
described_class
.
new
.
tap
{
|
runner
|
runner
.
options
=
%w[qa/specs/features/foo]
}
}
it
'passes the given tests path and excludes the default args'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'--tag'
,
'~quarantine'
,
'qa/specs/features/foo'
])
it
'passes the given tests path and excludes the orchestrated tag'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'qa/specs/features/foo'
])
subject
.
perform
end
...
...
@@ -104,12 +55,8 @@ describe QA::Specs::Runner do
context
'when "-- qa/specs/features/foo" is set as options'
do
subject
{
described_class
.
new
.
tap
{
|
runner
|
runner
.
options
=
%w[-- qa/specs/features/foo]
}
}
it
'passes the given tests path and excludes the default args'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'--tag'
,
'~quarantine'
,
'--'
,
'qa/specs/features/foo'
])
it
'passes the given tests path and excludes the orchestrated tag'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'--'
,
'qa/specs/features/foo'
])
subject
.
perform
end
...
...
@@ -123,12 +70,7 @@ describe QA::Specs::Runner do
subject
{
described_class
.
new
}
it
'it includes default args and excludes the skip_signup_disabled tag'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'--tag'
,
'~quarantine'
,
'--tag'
,
'~skip_signup_disabled'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'--tag'
,
'~skip_signup_disabled'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
subject
.
perform
end
...
...
@@ -142,12 +84,7 @@ describe QA::Specs::Runner do
subject
{
described_class
.
new
}
it
'it includes default args and excludes the requires_git_protocol_v2 tag'
do
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'--tag'
,
'~quarantine'
,
'--tag'
,
'~requires_git_protocol_v2'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
expect_rspec_runner_arguments
([
'--tag'
,
'~orchestrated'
,
'--tag'
,
'~requires_git_protocol_v2'
,
*
described_class
::
DEFAULT_TEST_PATH_ARGS
])
subject
.
perform
end
...
...
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