Skip to content
GitLab
Next
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Primary navigation
Search or go to…
Project
GitLab FOSS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Privacy statement
Keyboard shortcuts
?
What's new
4
Snippets
Groups
Projects
Show more breadcrumbs
GitLab.org
GitLab FOSS
Commits
db749d5d
There was a problem fetching the pipeline summary.
Commit
db749d5d
authored
7 years ago
by
Filipa Lacerda
Browse files
Options
Downloads
Patches
Plain Diff
Adds tests for scoped tabs
parent
d3ab245a
No related branches found
No related tags found
1 merge request
!10290
Resolve "Expandable folders for environments"
Pipeline
#
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
spec/features/projects/environments/environments_spec.rb
+36
-0
36 additions, 0 deletions
spec/features/projects/environments/environments_spec.rb
with
36 additions
and
0 deletions
spec/features/projects/environments/environments_spec.rb
+
36
−
0
View file @
db749d5d
...
...
@@ -23,6 +23,42 @@
expect
(
page
).
to
have_link
(
'Available'
)
expect
(
page
).
to
have_link
(
'Stopped'
)
end
describe
'with one available environment'
do
given
(
:environment
)
{
create
(
:environment
,
project:
project
,
state: :available
)
}
describe
'in available tab page'
do
it
'should show one environment'
do
visit
namespace_project_environments_path
(
project
.
namespace
,
project
,
scope:
'available'
)
expect
(
page
.
all
(
'tbody > tr'
).
length
).
to
eq
(
1
)
end
end
describe
'in stopped tab page'
do
it
'should show no environments'
do
visit
namespace_project_environments_path
(
project
.
namespace
,
project
,
scope:
'stopped'
)
expect
(
page
).
to
have_content
(
'You don\'t have any environments right now'
)
end
end
end
describe
'with one stopped environment'
do
given
(
:environment
)
{
create
(
:environment
,
project:
project
,
state: :stopped
)
}
describe
'in available tab page'
do
it
'should show no environments'
do
visit
namespace_project_environments_path
(
project
.
namespace
,
project
,
scope:
'available'
)
expect
(
page
).
to
have_content
(
'You don\'t have any environments right now'
)
end
end
describe
'in stopped tab page'
do
it
'should show one environment'
do
visit
namespace_project_environments_path
(
project
.
namespace
,
project
,
scope:
'stopped'
)
expect
(
page
.
all
(
'tbody > tr'
).
length
).
to
eq
(
1
)
end
end
end
end
context
'without environments'
do
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment