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
52cff35e
Commit
52cff35e
authored
Apr 27, 2017
by
Clement Ho
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[skip ci] fix time tracking spec
parent
07ec200b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
124 additions
and
126 deletions
+124
-126
spec/javascripts/issuable_time_tracker_spec.js
spec/javascripts/issuable_time_tracker_spec.js
+124
-126
No files found.
spec/javascripts/issuable_time_tracker_spec.js
View file @
52cff35e
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
import
Vue
from
'
vue
'
;
import
Vue
from
'
vue
'
;
import
'
~/sidebar/components/time_tracking/time_tracker
'
;
import
timeTracker
from
'
~/sidebar/components/time_tracking/time_tracker
'
;
function
initTimeTrackingComponent
(
opts
)
{
function
initTimeTrackingComponent
(
opts
)
{
setFixtures
(
`
setFixtures
(
`
...
@@ -16,18 +16,17 @@ function initTimeTrackingComponent(opts) {
...
@@ -16,18 +16,17 @@ function initTimeTrackingComponent(opts) {
time_spent
:
opts
.
timeSpent
,
time_spent
:
opts
.
timeSpent
,
human_time_estimate
:
opts
.
timeEstimateHumanReadable
,
human_time_estimate
:
opts
.
timeEstimateHumanReadable
,
human_time_spent
:
opts
.
timeSpentHumanReadable
,
human_time_spent
:
opts
.
timeSpentHumanReadable
,
docsUrl
:
'
/help/workflow/time_tracking.md
'
,
rootPath
:
'
/
'
,
};
};
const
TimeTrackingComponent
=
Vue
.
component
(
'
issuable-time-tracker
'
);
const
TimeTrackingComponent
=
Vue
.
extend
(
timeTracker
);
this
.
timeTracker
=
new
TimeTrackingComponent
({
this
.
timeTracker
=
new
TimeTrackingComponent
({
el
:
'
#mock-container
'
,
el
:
'
#mock-container
'
,
propsData
:
this
.
initialData
,
propsData
:
this
.
initialData
,
});
});
}
}
((
gl
)
=>
{
describe
(
'
Issuable Time Tracker
'
,
function
()
{
describe
(
'
Issuable Time Tracker
'
,
function
()
{
describe
(
'
Initialization
'
,
function
()
{
describe
(
'
Initialization
'
,
function
()
{
beforeEach
(
function
()
{
beforeEach
(
function
()
{
initTimeTrackingComponent
.
call
(
this
,
{
timeEstimate
:
100000
,
timeSpent
:
5000
,
timeEstimateHumanReadable
:
'
2h 46m
'
,
timeSpentHumanReadable
:
'
1h 23m
'
});
initTimeTrackingComponent
.
call
(
this
,
{
timeEstimate
:
100000
,
timeSpent
:
5000
,
timeEstimateHumanReadable
:
'
2h 46m
'
,
timeSpentHumanReadable
:
'
1h 23m
'
});
...
@@ -131,7 +130,7 @@ function initTimeTrackingComponent(opts) {
...
@@ -131,7 +130,7 @@ function initTimeTrackingComponent(opts) {
describe
(
'
No time tracking pane
'
,
function
()
{
describe
(
'
No time tracking pane
'
,
function
()
{
beforeEach
(
function
()
{
beforeEach
(
function
()
{
initTimeTrackingComponent
.
call
(
this
,
{
timeEstimate
:
0
,
timeSpent
:
0
,
timeEstimateHumanReadable
:
0
,
timeSpentHumanReadable
:
0
});
initTimeTrackingComponent
.
call
(
this
,
{
timeEstimate
:
0
,
timeSpent
:
0
,
timeEstimateHumanReadable
:
''
,
timeSpentHumanReadable
:
''
});
});
});
it
(
'
should only show the "No time tracking" pane when both timeEstimate and time_spent are falsey
'
,
function
(
done
)
{
it
(
'
should only show the "No time tracking" pane when both timeEstimate and time_spent are falsey
'
,
function
(
done
)
{
...
@@ -198,5 +197,4 @@ function initTimeTrackingComponent(opts) {
...
@@ -198,5 +197,4 @@ function initTimeTrackingComponent(opts) {
});
});
});
});
});
});
});
});
})(
window
.
gl
||
(
window
.
gl
=
{}));
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