Skip to content

Commit

Permalink
Uncomment odo project list json test
Browse files Browse the repository at this point in the history
  • Loading branch information
amitkrout committed Jul 11, 2020
1 parent c7d7fcb commit c2737e0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 19 deletions.
19 changes: 0 additions & 19 deletions tests/integration/generic_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,25 +114,6 @@ var _ = Describe("odo generic", func() {
})
})

// Uncomment once https://github.com/openshift/odo/issues/1708 is fixed
/*Context("odo machine readable output on empty project", func() {
JustBeforeEach(func() {
project = helper.CreateRandProject()
context = helper.CreateNewContext()
os.Setenv("GLOBALODOCONFIG", filepath.Join(context, "config.yaml"))
})
JustAfterEach(func() {
helper.DeleteProject(project)
helper.DeleteDir(context)
os.Unsetenv("GLOBALODOCONFIG")
})
It("should be able to return project list", func() {
actualProjectListJSON := helper.CmdShouldPass("odo", "project", "list", "-o", "json")
partOfProjectListJSON := fmt.Sprintf(`{"kind":"Project","apiVersion":"odo.dev/v1alpha1","metadata":{"name":"%s","creationTimestamp":null},`, project)
Expect(actualProjectListJSON).To(ContainSubstring(partOfProjectListJSON))
})
})*/

Context("creating component with an application and url", func() {
JustBeforeEach(func() {
context = helper.CreateNewContext()
Expand Down
7 changes: 7 additions & 0 deletions tests/integration/project/cmd_project_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,13 @@ var _ = Describe("odo project command tests", func() {
})
})

Context("odo machine readable output on empty project", func() {
It("should be able to list current project", func() {
projectListJSON := helper.CmdShouldPass("odo", "project", "list", "-o", "json")
Expect(projectListJSON).To(ContainSubstring("\"namespace\": " + "\"" + project + "\""))
})
})

Context("Should be able to delete a project with --wait", func() {
var projectName string
JustBeforeEach(func() {
Expand Down

0 comments on commit c2737e0

Please sign in to comment.