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
b8dbebce
Commit
b8dbebce
authored
Feb 12, 2017
by
Filipa Lacerda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix typo
parent
f7d8c29e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
13 deletions
+13
-13
app/assets/javascripts/environments/components/environment_item.js.es6
...vascripts/environments/components/environment_item.js.es6
+12
-12
spec/features/projects/builds_spec.rb
spec/features/projects/builds_spec.rb
+1
-1
No files found.
app/assets/javascripts/environments/components/environment_item.js.es6
View file @
b8dbebce
...
@@ -72,7 +72,7 @@ module.exports = Vue.component('environment-item', {
...
@@ -72,7 +72,7 @@ module.exports = Vue.component('environment-item', {
* @returns {Boolean}
* @returns {Boolean}
*/
*/
hasLastDeploymentKey() {
hasLastDeploymentKey() {
if (this.model.la
s
test && this.model.latest.last_deployment &&
if (this.model.latest && this.model.latest.last_deployment &&
!this.$options.isObjectEmpty(this.model.latest.last_deployment)) {
!this.$options.isObjectEmpty(this.model.latest.last_deployment)) {
return true;
return true;
}
}
...
@@ -86,7 +86,7 @@ module.exports = Vue.component('environment-item', {
...
@@ -86,7 +86,7 @@ module.exports = Vue.component('environment-item', {
* @returns {Boolean|Undefined}
* @returns {Boolean|Undefined}
*/
*/
hasManualActions() {
hasManualActions() {
return this.model.la
s
test && 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 &&
this.model.latest.last_deployment.manual_actions.length > 0;
this.model.latest.last_deployment.manual_actions.length > 0;
},
},
...
@@ -107,7 +107,7 @@ module.exports = Vue.component('environment-item', {
...
@@ -107,7 +107,7 @@ module.exports = Vue.component('environment-item', {
* @returns {Boolean|Undefined}
* @returns {Boolean|Undefined}
*/
*/
canRetry() {
canRetry() {
return this.model.la
s
test &&
return this.model.latest &&
this.hasLastDeploymentKey &&
this.hasLastDeploymentKey &&
this.model.latest.last_deployment &&
this.model.latest.last_deployment &&
this.model.latest.last_deployment.deployable;
this.model.latest.last_deployment.deployable;
...
@@ -119,7 +119,7 @@ module.exports = Vue.component('environment-item', {
...
@@ -119,7 +119,7 @@ module.exports = Vue.component('environment-item', {
* @returns {Boolean|Undefined}
* @returns {Boolean|Undefined}
*/
*/
canShowDate() {
canShowDate() {
return this.model.la
s
test &&
return this.model.latest &&
this.model.latest.last_deployment &&
this.model.latest.last_deployment &&
this.model.latest.last_deployment.deployable &&
this.model.latest.last_deployment.deployable &&
this.model.latest.last_deployment.deployable !== undefined;
this.model.latest.last_deployment.deployable !== undefined;
...
@@ -131,9 +131,9 @@ module.exports = Vue.component('environment-item', {
...
@@ -131,9 +131,9 @@ module.exports = Vue.component('environment-item', {
* @returns {String}
* @returns {String}
*/
*/
createdDate() {
createdDate() {
if (this.model.la
s
test &&
if (this.model.latest &&
this.model.latest.last_deployment &&
this.model.latest.last_deployment &&
this.model.la
s
test.last_deployment.deployable &&
this.model.latest.last_deployment.deployable &&
this.model.latest.last_deployment.deployable.created_at) {
this.model.latest.last_deployment.deployable.created_at) {
return timeagoInstance.format(this.model.latest.last_deployment.deployable.created_at);
return timeagoInstance.format(this.model.latest.last_deployment.deployable.created_at);
}
}
...
@@ -350,7 +350,7 @@ module.exports = Vue.component('environment-item', {
...
@@ -350,7 +350,7 @@ module.exports = Vue.component('environment-item', {
*/
*/
shouldRenderBuildName() {
shouldRenderBuildName() {
return !this.model.isFolder &&
return !this.model.isFolder &&
this.model.la
s
test &&
this.model.latest &&
!this.$options.isObjectEmpty(this.model.latest.last_deployment) &&
!this.$options.isObjectEmpty(this.model.latest.last_deployment) &&
!this.$options.isObjectEmpty(this.model.latest.last_deployment.deployable);
!this.$options.isObjectEmpty(this.model.latest.last_deployment.deployable);
},
},
...
@@ -362,10 +362,10 @@ module.exports = Vue.component('environment-item', {
...
@@ -362,10 +362,10 @@ module.exports = Vue.component('environment-item', {
*/
*/
buildPath() {
buildPath() {
if (this.model.latest &&
if (this.model.latest &&
this.model.la
s
test.last_deployment &&
this.model.latest.last_deployment &&
this.model.latest.last_deployment.deployable &&
this.model.latest.last_deployment.deployable &&
this.model.la
s
test.last_deployment.deployable.build_path) {
this.model.latest.last_deployment.deployable.build_path) {
return this.model.la
s
test.last_deployment.deployable.build_path;
return this.model.latest.last_deployment.deployable.build_path;
}
}
return '';
return '';
...
@@ -392,13 +392,13 @@ module.exports = Vue.component('environment-item', {
...
@@ -392,13 +392,13 @@ module.exports = Vue.component('environment-item', {
*/
*/
shouldRenderDeploymentID() {
shouldRenderDeploymentID() {
return !this.model.isFolder &&
return !this.model.isFolder &&
this.model.la
s
test &&
this.model.latest &&
!this.$options.isObjectEmpty(this.model.latest.last_deployment) &&
!this.$options.isObjectEmpty(this.model.latest.last_deployment) &&
this.model.latest.last_deployment.iid !== undefined;
this.model.latest.last_deployment.iid !== undefined;
},
},
environmentPath() {
environmentPath() {
if (this.model && this.model.la
s
test && this.model.latest.environment_path) {
if (this.model && this.model.latest && this.model.latest.environment_path) {
return this.model.latest.environment_path;
return this.model.latest.environment_path;
}
}
...
...
spec/features/projects/builds_spec.rb
View file @
b8dbebce
...
@@ -271,7 +271,7 @@ feature 'Builds', :feature do
...
@@ -271,7 +271,7 @@ feature 'Builds', :feature do
let!
(
:deployment
)
{
create
(
:deployment
,
environment:
environment
,
sha:
project
.
commit
.
id
)
}
let!
(
:deployment
)
{
create
(
:deployment
,
environment:
environment
,
sha:
project
.
commit
.
id
)
}
let
(
:build
)
{
create
(
:ci_build
,
:success
,
environment:
environment
.
name
,
pipeline:
pipeline
)
}
let
(
:build
)
{
create
(
:ci_build
,
:success
,
environment:
environment
.
name
,
pipeline:
pipeline
)
}
it
'shows a link to la
s
test deployment'
do
it
'shows a link to latest deployment'
do
visit
namespace_project_build_path
(
project
.
namespace
,
project
,
build
)
visit
namespace_project_build_path
(
project
.
namespace
,
project
,
build
)
expect
(
page
).
to
have_link
(
'latest deployment'
)
expect
(
page
).
to
have_link
(
'latest deployment'
)
...
...
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