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

Run integration tests against an external agent process #552

Merged
merged 2 commits into from
Jan 9, 2024

Conversation

tallclair
Copy link
Contributor

This PR enables the agent executed by integration tests to be launched as a separate process from a prebuilt binary, chosen by the --agent-path flag.

Aside from the new agent runner, most of the changes in this PR are around the way metrics are tested, since they need to be scraped from the external process when used.

I will follow up with the external ProxyServer runner as a separate PR.

For #519

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jan 5, 2024
@tallclair
Copy link
Contributor Author

/assign @jkh52

@k8s-ci-robot k8s-ci-robot requested review from elmiko and ipochi January 5, 2024 21:54
@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jan 5, 2024
@tallclair tallclair mentioned this pull request Jan 5, 2024
6 tasks
@jkh52
Copy link
Contributor

jkh52 commented Jan 9, 2024

Please fix the lint errors:

tests/framework/agent.go:136:9: G204: Subprocess launched with a potential tainted input or cmd arguments (gosec)
	cmd := exec.Command(r.ExecutablePath, args...)
	       ^
tests/framework/metrics.go:47:15: G107: Potential HTTP request made with variable url (gosec)
	resp, err := http.Get(metricsURL)
	             ^
pkg/testing/metrics/metrics.go:136:9: indent-error-flow: if block ends with a return statement, so drop this else and outdent its block (revive)
	} else {
		return promtest.ScrapeAndCompare(t.Endpoint, strings.NewReader(expected), fqName)
	}

/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jkh52, tallclair

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 9, 2024
@tallclair
Copy link
Contributor Author

/label tide/merge-method-squash

@k8s-ci-robot k8s-ci-robot added the tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges. label Jan 9, 2024
@tallclair
Copy link
Contributor Author

I fixed the security issues by excluding tests from the security linter. I think it's more likely to just create noise on test files.

@jkh52
Copy link
Contributor

jkh52 commented Jan 9, 2024

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 9, 2024
@jkh52
Copy link
Contributor

jkh52 commented Jan 9, 2024

arm64 build timeout

/retest

@k8s-ci-robot k8s-ci-robot merged commit 73e88b3 into kubernetes-sigs:master Jan 9, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants