Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to execute Tests for release #178

Merged
merged 10 commits into from
Jan 12, 2023

Conversation

harshit-mehtaa
Copy link
Contributor

@harshit-mehtaa harshit-mehtaa commented Jan 9, 2023

Fixes Issue

#115

Changes proposed

  • Add a button to 'Run test' on the chart revision page
  • Create a new POST API to execute the helm test
  • Show tests response in a new modal

Check List (Check all the applicable boxes)

  • My code follows the code style of this project.
  • My change requires changes to the documentation.
  • I have updated the documentation accordingly.
  • All new and existing tests passed.
  • The title of my pull request is a short description of the requested changes.

Screenshots

image

image

@undera
Copy link
Collaborator

undera commented Jan 9, 2023

If PR is not complete, consider turning it into "draft". It's a handy feature in GH, exactly for that.

@harshit-mehtaa harshit-mehtaa changed the title [WIP]: Add option to execute Tests for release Add option to execute Tests for release Jan 9, 2023
@harshit-mehtaa harshit-mehtaa marked this pull request as draft January 9, 2023 16:40
@undera
Copy link
Collaborator

undera commented Jan 10, 2023

Note that this will need to be ported to v1.0

@github-actions github-actions bot added the docs label Jan 12, 2023
@harshit-mehtaa harshit-mehtaa marked this pull request as ready for review January 12, 2023 10:56
@harshit-mehtaa
Copy link
Contributor Author

@undera Please help review

Will port to be compatible with release v1.0.0 once this is merged

return
}

c.String(http.StatusAccepted, out)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The tests can actually have output and logs. Shouldn't we block until those are returned, and show the result in UI?

Copy link
Collaborator

@undera undera Jan 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I mean StatusAccepted has meaning "the request is accepted for processing, but it is not complete". If it is complete, the status code should be 200 OK

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Handled in new commit

@@ -278,6 +278,17 @@ func (d *DataLayer) ChartInstall(namespace string, name string, repoChart string
return out, nil
}

func (d *DataLayer) RunTests(namespace string, name string) (string, error) {
cmd := []string{"test", name, "--namespace", namespace}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add --logs here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Handled in new commit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants