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

PET-16 Go coverage only in cmd and pkg directories #57

Closed
wants to merge 1 commit into from

Conversation

glothriel
Copy link
Contributor

New go version, parametrized.

@glothriel glothriel requested a review from a team as a code owner October 6, 2023 16:19
@glothriel glothriel requested review from jzyinq, plks and radekska October 6, 2023 16:19
@@ -54,7 +58,7 @@ runs:

- name: Run tests
shell: bash
run: go test ./... -v -coverpkg=./... -coverprofile cover.out
run: go test ./cmd/... ./pkg/... -v -coverpkg=./cmd/...,./pkg/... -coverprofile cover.out
Copy link
Contributor

Choose a reason for hiding this comment

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

What if some modules would have an internal directory as well?

Copy link
Contributor

Choose a reason for hiding this comment

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

What purpose does this change have?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@Decard6 https://github.com/PiwikPRO/PPMS-DomainResolver/pull/60/files
@radekska I think that we should introduce a global convention of putting the go project files only in pkg and cmd directory in order for it to work. If you plan to use internal packages, there's no problem in putting them under pkg/internal i suppose.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@radekska Hmm, now i've read your link. Should we add the internal package to the flags as well?

Copy link
Contributor

Choose a reason for hiding this comment

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

@glothriel not sure how many modules actually use a separate internal package, though making test and coverage directories configurable would be a plus

Copy link
Contributor

Choose a reason for hiding this comment

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

I'd say so, we probably want to adjust to go standards.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm going to get back to this on next pet project friday

@glothriel glothriel closed this Oct 23, 2023
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.

3 participants