8000 fwk: rename package testdata to internal/fwktest by dolmen · Pull Request #942 · go-hep/hep · GitHub
[go: up one dir, main page]

Skip to content
This repository was archived by the owner on Oct 30, 2025. It is now read-only.

fwk: rename package testdata to internal/fwktest - #942

Merged
sbinet merged 4 commits into
go-hep:mainfrom
dolmen-go:fwk-rename-pkg-testdata
May 10, 2022
Merged

sbinet merged 4 commits into
go-hep:mainfrom
dolmen-go:fwk-rename-pkg-testdata

Conversation

@dolmen
@dolmen dolmen commented May 5, 2022
Copy link
Copy Markdown
Contributor

Fixes #941 .

1st commit:

$ mkdir -p fwk/internal/fwktest
$ git mv fwk/testdata/*.go fwk/internal/fwktest
$ ( cd fwk/internal/fwktest; sed -i '' 's/package testdata/package fwktest/' *.go )
$ git add fwk/internal/fwktest

2nd commit:

$ ( cd fwk; find . -name '*.go' -exec grep -Hq 'fwk/testdata' '{}' \; -print | xargs sed -i '' -e 's!fwk/testdata!fwk/internal/fwktest!' -e 's!testdata\.!fwktest.!' -e 's!some tools defined in testdata!some tools defined in fwktest!' )
$ git add fwk

dolmen added 3 commits May 5, 2022 22:12
mkdir -p fwk/internal/fwktest
git mv fwk/testdata/*.go fwk/internal/fwktest
( cd fwk/internal/fwktest; sed -i '' 's/package testdata/package fwktest/' *.go )
git add fwk/internal/fwktest
( cd fwk; find . -name '*.go' -exec grep -Hq 'fwk/testdata' '{}' \; -print | xargs sed -i '' -e 's!fwk/testdata!fwk/internal/fwktest!' -e 's!testdata\.!fwktest.!' -e 's!some tools defined in testdata!some tools defined in fwktest!' )
@sbinet sbinet left a comment
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.

LGTM.

thanks for cleaning that up.

like for the other pending PRs, please send another (just one) pull request against the go-hep/license repository, adding yourself to the AUTHORS and/or CONTRIBUTORS file(s).
then I'll be able to collect and merge all your other pull requests.
(I can't do that before you've added yourself to the list of authors/contributors of the Go-HEP project)

thanks.

@sbinet
sbinet commented May 6, 2022
Copy link
Copy Markdown
Member

ah. one finnicky import ordering that doesn't suit gofmt (or goimport in this case).

Apply gofmt after automated changes in previous commits.
@sbinet
sbinet commented May 10, 2022
Copy link
Copy Markdown
Member

I'll handle the staticcheck failure.

thanks.

@sbinet
sbinet merged commit f81a84e into go-hep:main May 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Rename package fwk/testdata (Go reserved name)

2 participants

0