Skip to content

Add envtest integration tests for kube controller#2487

Open
AryanP123 wants to merge 1 commit into
skupperproject:mainfrom
AryanP123:add-kube-controller-envtest
Open

Add envtest integration tests for kube controller#2487
AryanP123 wants to merge 1 commit into
skupperproject:mainfrom
AryanP123:add-kube-controller-envtest

Conversation

@AryanP123

Copy link
Copy Markdown
Contributor

Fixes #2486

@AryanP123

Copy link
Copy Markdown
Contributor Author

@ajssmith @fgiorgetti @c-kruse Thoughts on this set up? For now just added integration tests for skupper/internal/kube/controller/controller.go. Didn't want to crowd the location of production files with more test files as unit tests typically already exist there.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggest a separate issue/pr for changes to NewClient as scope separate/independent from envtest integration

}
time.Sleep(3 * time.Second)

if err := testEnv.Stop(); err != nil {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggest using defer function on Stop() following Start() above

Comment thread Makefile
test:
go test ${TESTFLAGS} ./...

.PHONY: test-integration

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggest moving the tests/Makefile unless there is a reason it needs to be here


## Layout

| Directory | Tests |

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggest a layout that mirrors internal, e.g.

/tests/integration/kube/controller

In anticipation of integration tests for nonkube, e.g.

/tests/integration/nonkube/controller

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add integration testing

2 participants