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
Tatuya Kamada
gitlab-ce
Commits
27d7ec70
Commit
27d7ec70
authored
Feb 10, 2017
by
Filipa Lacerda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove spec checking for scope 'all' since it's no longer part of component
Changes after review Fix typo
parent
595afed2
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
11 deletions
+13
-11
app/assets/javascripts/environments/components/environment_item.js.es6
...vascripts/environments/components/environment_item.js.es6
+4
-2
spec/javascripts/environments/environment_spec.js.es6
spec/javascripts/environments/environment_spec.js.es6
+3
-3
spec/javascripts/vue_shared/components/table_pagination_spec.js.es6
...cripts/vue_shared/components/table_pagination_spec.js.es6
+6
-6
No files found.
app/assets/javascripts/environments/components/environment_item.js.es6
View file @
27d7ec70
...
...
@@ -72,7 +72,8 @@ module.exports = Vue.component('environment-item', {
* @returns {Boolean}
*/
hasLastDeploymentKey() {
if (this.model.latest && this.model.latest.last_deployment &&
if (this.model.latest &&
this.model.latest.last_deployment &&
!this.$options.isObjectEmpty(this.model.latest.last_deployment)) {
return true;
}
...
...
@@ -86,7 +87,8 @@ module.exports = Vue.component('environment-item', {
* @returns {Boolean|Undefined}
*/
hasManualActions() {
return this.model.latest && this.model.latest.last_deployment &&
return this.model.latest &&
this.model.latest.last_deployment &&
this.model.latest.last_deployment.manual_actions &&
this.model.latest.last_deployment.manual_actions.length > 0;
},
...
...
spec/javascripts/environments/environment_spec.js.es6
View file @
27d7ec70
...
...
@@ -58,11 +58,11 @@ describe('Environment', () => {
}), {
status: 200,
headers: {
'X-
Next-Pa
ge': '2',
'
X-P
age': '1',
'X-
nExt-pA
ge': '2',
'
x-p
age': '1',
'X-Per-Page': '1',
'X-Prev-Page': '',
'X-T
otal
': '37',
'X-T
OTAL
': '37',
'X-Total-Pages': '2',
},
}));
...
...
spec/javascripts/vue_shared/components/table_pagination_spec.js.es6
View file @
27d7ec70
...
...
@@ -34,7 +34,7 @@ describe('Pagination component', () => {
component.changePage({ target: { innerText: '1' } });
expect(changeChanges.one).toEqual(1);
expect(changeChanges.two).toEqual(
'all'
);
expect(changeChanges.two).toEqual(
null
);
});
it('should go to the previous page', () => {
...
...
@@ -55,7 +55,7 @@ describe('Pagination component', () => {
component.changePage({ target: { innerText: 'Prev' } });
expect(changeChanges.one).toEqual(1);
expect(changeChanges.two).toEqual(
'all'
);
expect(changeChanges.two).toEqual(
null
);
});
it('should go to the next page', () => {
...
...
@@ -76,7 +76,7 @@ describe('Pagination component', () => {
component.changePage({ target: { innerText: 'Next' } });
expect(changeChanges.one).toEqual(5);
expect(changeChanges.two).toEqual(
'all'
);
expect(changeChanges.two).toEqual(
null
);
});
it('should go to the last page', () => {
...
...
@@ -97,7 +97,7 @@ describe('Pagination component', () => {
component.changePage({ target: { innerText: 'Last >>' } });
expect(changeChanges.one).toEqual(10);
expect(changeChanges.two).toEqual(
'all'
);
expect(changeChanges.two).toEqual(
null
);
});
it('should go to the first page', () => {
...
...
@@ -118,7 +118,7 @@ describe('Pagination component', () => {
component.changePage({ target: { innerText: '<< First' } });
expect(changeChanges.one).toEqual(1);
expect(changeChanges.two).toEqual(
'all'
);
expect(changeChanges.two).toEqual(
null
);
});
it('should do nothing', () => {
...
...
@@ -139,7 +139,7 @@ describe('Pagination component', () => {
component.changePage({ target: { innerText: '...' } });
expect(changeChanges.one).toEqual(1);
expect(changeChanges.two).toEqual(
'all'
);
expect(changeChanges.two).toEqual(
null
);
});
});
...
...
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