Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
H
helm3
Project
Project
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
helm3
Commits
538e8297
Commit
538e8297
authored
Feb 06, 2017
by
Michelle Noorali
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ref(*): add namespace info to failing test msg
* also cleanup comments
parent
bf9ae52e
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
9 additions
and
11 deletions
+9
-11
tiller.proto
_proto/hapi/services/tiller.proto
+2
-4
release_testing.go
cmd/helm/release_testing.go
+1
-1
environment.go
pkg/releasetesting/environment.go
+2
-2
test_suite.go
pkg/releasetesting/test_suite.go
+2
-2
test_suite_test.go
pkg/releasetesting/test_suite_test.go
+1
-1
release_server_test.go
pkg/tiller/release_server_test.go
+1
-1
No files found.
_proto/hapi/services/tiller.proto
View file @
538e8297
...
...
@@ -79,8 +79,7 @@ service ReleaseService {
rpc
GetHistory
(
GetHistoryRequest
)
returns
(
GetHistoryResponse
)
{
}
//TODO: move this to a test release service or rename to RunReleaseTest
// TestRelease runs the tests for a given release
// RunReleaseTest executes the tests defined of a named release
rpc
RunReleaseTest
(
TestReleaseRequest
)
returns
(
stream
TestReleaseResponse
)
{
}
}
...
...
@@ -318,8 +317,7 @@ message TestReleaseRequest {
int64
timeout
=
2
;
}
// TestReleaseResponse
// TestReleaseResponse
represents a message from executing a test
message
TestReleaseResponse
{
// TODO: change to repeated hapi.release.Release.Test results = 1; (for stream)
string
msg
=
1
;
}
cmd/helm/release_testing.go
View file @
538e8297
...
...
@@ -26,7 +26,7 @@ import (
)
const
releaseTestDesc
=
`
Th test command runs the tests for a release.
Th
e
test command runs the tests for a release.
The argument this command takes is the name of a deployed release.
The tests to be run are defined in the chart that was installed.
...
...
pkg/releasetesting/environment.go
View file @
538e8297
...
...
@@ -43,8 +43,8 @@ func streamError(info string, stream services.ReleaseService_RunReleaseTestServe
return
err
}
func
streamFailed
(
name
string
,
stream
services
.
ReleaseService_RunReleaseTestServer
)
error
{
msg
:=
fmt
.
Sprintf
(
"FAILED: %s, run `kubectl logs %s
` for more info"
,
name
,
nam
e
)
func
streamFailed
(
name
,
namespace
string
,
stream
services
.
ReleaseService_RunReleaseTestServer
)
error
{
msg
:=
fmt
.
Sprintf
(
"FAILED: %s, run `kubectl logs %s
--namespace %s` for more info"
,
name
,
name
,
namespac
e
)
err
:=
streamMessage
(
msg
,
stream
)
return
err
}
...
...
pkg/releasetesting/test_suite.go
View file @
538e8297
...
...
@@ -103,10 +103,10 @@ func (t *TestSuite) Run(env *Environment) error {
}
}
else
if
resourceCreated
&&
resourceCleanExit
&&
status
==
api
.
PodFailed
{
test
.
result
.
Status
=
release
.
TestRun_FAILURE
if
streamErr
:=
streamFailed
(
test
.
result
.
Name
,
env
.
Stream
);
streamErr
!=
nil
{
if
streamErr
:=
streamFailed
(
test
.
result
.
Name
,
env
.
Namespace
,
env
.
Stream
);
streamErr
!=
nil
{
return
err
}
}
//else if resourceCreated && resourceCleanExit && status == api.PodUnkown {
}
test
.
result
.
CompletedAt
=
timeconv
.
Now
()
t
.
Results
=
append
(
t
.
Results
,
test
.
result
)
...
...
pkg/releasetesting/test_suite_test.go
View file @
538e8297
...
...
@@ -128,7 +128,7 @@ kind: Pod
metadata:
name: finding-nemo,
annotations:
"helm.sh/hook": test
"helm.sh/hook": test
-success
spec:
containers:
- name: nemo-test
...
...
pkg/tiller/release_server_test.go
View file @
538e8297
...
...
@@ -58,7 +58,7 @@ kind: Pod
metadata:
name: finding-nemo,
annotations:
"helm.sh/hook": test
"helm.sh/hook": test
-success
spec:
containers:
- name: nemo-test
...
...
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