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
4f7c7b15
Commit
4f7c7b15
authored
May 07, 2020
by
Dave Pisek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reviewer feedback: Test description fixes
parent
b45accce
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
35 additions
and
32 deletions
+35
-32
ee/spec/frontend/license_compliance/components/app_spec.js
ee/spec/frontend/license_compliance/components/app_spec.js
+22
-19
spec/frontend/helpers/set_window_location_helper_spec.js
spec/frontend/helpers/set_window_location_helper_spec.js
+13
-13
No files found.
ee/spec/frontend/license_compliance/components/app_spec.js
View file @
4f7c7b15
...
...
@@ -194,7 +194,9 @@ describe('Project Licenses', () => {
${
'
policies
'
}
|
${
1
}
${
'
foo
'
}
|
${
0
}
${
'
bar
'
}
|
${
0
}
`
(
'
when the url contains $givenUrlHash hash
'
,
({
givenLocationHash
,
expectedTabIndex
})
=>
{
`
(
'
when the url contains $givenLocationHash hash
'
,
({
givenLocationHash
,
expectedTabIndex
})
=>
{
beforeEach
(()
=>
{
setWindowLocation
({
href
:
`
${
TEST_HOST
}
#
${
givenLocationHash
}
`
,
...
...
@@ -212,10 +214,11 @@ describe('Project Licenses', () => {
});
});
it
(
`sets the tabIndex to be "
${
expectedTabIndex
}
`
,
()
=>
{
it
(
`sets the tabIndex to be "
${
expectedTabIndex
}
"
`
,
()
=>
{
expect
(
wrapper
.
find
(
GlTabs
).
attributes
(
'
value
'
)).
toBe
(
`
${
expectedTabIndex
}
`
);
});
});
},
);
it
.
each
`
givenTabIndex | expectedLocationHash
...
...
spec/frontend/helpers/set_window_location_helper_spec.js
View file @
4f7c7b15
...
...
@@ -8,7 +8,7 @@ describe('setWindowLocationHelper', () => {
});
it
.
each
`
locationProperty
| value
property
| value
${
'
hash
'
}
|
${
'
foo
'
}
${
'
host
'
}
|
${
'
gitlab.com
'
}
${
'
hostname
'
}
|
${
'
gitlab.com
'
}
...
...
@@ -17,13 +17,13 @@ describe('setWindowLocationHelper', () => {
${
'
origin
'
}
|
${
'
/foo
'
}
${
'
port
'
}
|
${
'
80
'
}
${
'
protocol
'
}
|
${
'
https:
'
}
`
(
'
sets "window.location.$
locationProperty" to be $value
'
,
({
locationP
roperty
,
value
})
=>
{
expect
(
window
.
location
[
locationProperty
]).
not
.
toBe
(
value
);
`
(
'
sets "window.location.$
property" to be $value
'
,
({
p
roperty
,
value
})
=>
{
expect
(
window
.
location
).
toBe
(
originalLocation
);
setWindowLocationHelper
({
[
locationP
roperty
]:
value
,
[
p
roperty
]:
value
,
});
expect
(
window
.
location
[
locationP
roperty
]).
toBe
(
value
);
expect
(
window
.
location
[
p
roperty
]).
toBe
(
value
);
});
});
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