BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
96785e77
Unverified
Commit
96785e77
authored
May 09, 2018
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added specs
parent
cc066314
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
0 deletions
+20
-0
model_spec.js
spec/javascripts/ide/lib/common/model_spec.js
+4
-0
file_spec.js
spec/javascripts/ide/stores/actions/file_spec.js
+16
-0
No files found.
spec/javascripts/ide/lib/common/model_spec.js
View file @
96785e77
...
...
@@ -28,6 +28,10 @@ describe('Multi-file editor library model', () => {
expect
(
model
.
originalModel
).
not
.
toBeNull
();
expect
(
model
.
model
).
not
.
toBeNull
();
expect
(
model
.
baseModel
).
not
.
toBeNull
();
expect
(
model
.
originalModel
.
uri
.
path
).
toBe
(
'original/path--path'
);
expect
(
model
.
model
.
uri
.
path
).
toBe
(
'path--path'
);
expect
(
model
.
baseModel
.
uri
.
path
).
toBe
(
'target/path--path'
);
});
it
(
'creates model with head file to compare against'
,
()
=>
{
...
...
spec/javascripts/ide/stores/actions/file_spec.js
View file @
96785e77
...
...
@@ -569,6 +569,22 @@ describe('IDE store file actions', () => {
.
catch
(
done
.
fail
);
});
it
(
'returns false when already opened'
,
done
=>
{
store
.
state
.
openFiles
.
push
({
...
f
,
active
:
true
,
key
:
`pending-
${
f
.
key
}
`
,
});
store
.
dispatch
(
'openPendingTab'
,
{
file
:
f
,
keyPrefix
:
'pending'
})
.
then
(
added
=>
{
expect
(
added
).
toBe
(
false
);
})
.
then
(
done
)
.
catch
(
done
.
fail
);
});
it
(
'pushes router URL when added'
,
done
=>
{
store
.
state
.
currentBranchId
=
'master'
;
...
...
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