Skip to content

[bug] build-time test fail in chroot #39

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

Open
werdahias opened this issue May 30, 2025 · 0 comments
Open

[bug] build-time test fail in chroot #39

werdahias opened this issue May 30, 2025 · 0 comments

Comments

@werdahias
Copy link

I'm packaging go-paths-helper for Debian as prerequisite for arduino-cli. It builds fine, however the tests fail like this:

  dh_auto_test -O--builddirectory=_build -O--buildsystem=golang
	cd _build && go test -vet=off -v -p 14 github.com/arduino/go-paths-helper
=== RUN   TestGzipGunzip
--- PASS: TestGzipGunzip (0.00s)
=== RUN   TestListConstructors
--- PASS: TestListConstructors (0.00s)
=== RUN   TestListSorting
--- PASS: TestListSorting (0.00s)
=== RUN   TestListFilters
--- PASS: TestListFilters (0.00s)
=== RUN   TestPathNew
--- PASS: TestPathNew (0.00s)
=== RUN   TestPath
--- PASS: TestPath (0.00s)
=== RUN   TestResetStatCacheWhenFollowingSymlink
--- PASS: TestResetStatCacheWhenFollowingSymlink (0.00s)
=== RUN   TestIsInsideDir
--- PASS: TestIsInsideDir (0.00s)
=== RUN   TestReadFileAsLines
--- PASS: TestReadFileAsLines (0.00s)
=== RUN   TestCanonicaTempDir
--- PASS: TestCanonicaTempDir (0.00s)
=== RUN   TestCopyDir
--- PASS: TestCopyDir (0.00s)
=== RUN   TestParents
--- PASS: TestParents (0.00s)
=== RUN   TestFilterDirs
--- PASS: TestFilterDirs (0.00s)
=== RUN   TestFilterOutDirs
   paths_test.go:313: 
       	Error Trace:	/build/reproducible-path/golang-github-arduino-go-paths-helper-1.13.1/_build/src/github.com/arduino/go-paths-helper/paths_test.go:313
       	Error:      	"[testdata/broken_symlink/dir_1/file2 testdata/broken_symlink/dir_1/linked_dir testdata/broken_symlink/dir_1/linked_dir/file1 testdata/broken_symlink/dir_1/linked_file testdata/broken_symlink/dir_1/real_dir testdata/broken_symlink/dir_1/real_dir/file1]" should have 7 item(s), but has 6
       	Test:       	TestFilterOutDirs
--- FAIL: TestFilterOutDirs (0.00s)
=== RUN   TestEquivalentPaths
--- PASS: TestEquivalentPaths (0.00s)
=== RUN   TestCanonicalize
--- PASS: TestCanonicalize (0.00s)
=== RUN   TestRelativeTo
--- PASS: TestRelativeTo (0.00s)
=== RUN   TestWriteToTempFile
--- PASS: TestWriteToTempFile (0.00s)
=== RUN   TestCopyToSamePath
--- PASS: TestCopyToSamePath (0.00s)
=== RUN   TestProcessWithinContext
--- PASS: TestProcessWithinContext (0.40s)
=== RUN   TestKillProcessGroupOnLinux
--- PASS: TestKillProcessGroupOnLinux (1.00s)
=== RUN   TestReadDirRecursive
--- PASS: TestReadDirRecursive (0.00s)
=== RUN   TestReadDirRecursiveSymLinkLoop
directories symlink loop detected
directories symlink loop detected
--- PASS: TestReadDirRecursiveSymLinkLoop (0.00s)
=== RUN   TestReadDirFiltered
--- PASS: TestReadDirFiltered (0.00s)
=== RUN   TestReadDirRecursiveFiltered
--- PASS: TestReadDirRecursiveFiltered (0.00s)
=== RUN   TestReadDirRecursiveLoopDetection
   readdir_test.go:312: 
       	Error Trace:	/build/reproducible-path/golang-github-arduino-go-paths-helper-1.13.1/_build/src/github.com/arduino/go-paths-helper/readdir_test.go:312
       	Error:      	"[testdata/loops/regular_3/dir1 testdata/loops/regular_3/dir1/file1 testdata/loops/regular_3/dir2 testdata/loops/regular_3/dir2/dir1 testdata/loops/regular_3/dir2/dir1/file1 testdata/loops/regular_3/dir2/file2]" should have 7 item(s), but has 6
       	Test:       	TestReadDirRecursiveLoopDetection
--- FAIL: TestReadDirRecursiveLoopDetection (0.07s)
FAIL
FAIL	github.com/arduino/go-paths-helper	1.481s
FAIL
dh_auto_test: error: cd _build && go test -vet=off -v -p 14 github.com/arduino/go-paths-helper returned exit code 1

The build runs inside a chroot; any pointers to why the test fails here ? Looks like a one-off bug to me

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

No branches or pull requests

1 participant