fix TestFromDirSymlink on Windows due to missing drive-letter#283
Merged
dnephin merged 1 commit intogotestyourself:mainfrom Aug 29, 2024
Merged
Conversation
2533182 to
b848e70
Compare
Contributor
Author
|
Hm... nope; that didn't help. Looks like something else needs to be updated; perhaps as part of the Hm.. looking again, it looks like it's actual failing on the part related to Lines 39 to 41 in 631f6c8 Looks like that was added in; Maybe that part is no longer needed; let me try just removing it |
2fe67a9 to
0b8a80e
Compare
This test was failing, because it expected the drive-letter to always
be returned, which wasn't the case;
=== FAIL: fs TestFromDirSymlink (0.01s)
ops_test.go:55: assertion failed: directory C:\Users\circleci\AppData\Local\Temp\test-from-dir-2260318643 does not match expected:
\a\b\3
target: expected C:\some\inexistent\link got \some\inexistent\link
This patch removes the special-case from d44953d,
which unconditionally added the drive-letter. Instead, we only change
the check to use the expected directory-separator.
Signed-off-by: Sebastiaan van Stijn <[email protected]>
test
Signed-off-by: Sebastiaan van Stijn <[email protected]>
0b8a80e to
109d43e
Compare
dnephin
approved these changes
Aug 29, 2024
Member
dnephin
left a comment
There was a problem hiding this comment.
Thank you!
I guess the Go stdlib changed in a recent version? This test was passing for a long time.
Contributor
Author
|
Yeah, no clue either; also honestly don't have a Windows machine to test locally 😂. Given that the original fix was a workaround for CI, and nobody complained that the code itself wasn't working, I'm pretty sure nothing was severely broken, so just the test. |
Crown0815
pushed a commit
to Crown0815/forgejo-runner-windows
that referenced
this pull request
May 21, 2025
This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [gotest.tools/v3](https://github.com/gotestyourself/gotest.tools) | require | patch | `v3.5.1` -> `v3.5.2` | --- ### Release Notes <details> <summary>gotestyourself/gotest.tools (gotest.tools/v3)</summary> ### [`v3.5.2`](https://github.com/gotestyourself/gotest.tools/releases/tag/v3.5.2) [Compare Source](gotestyourself/gotest.tools@v3.5.1...v3.5.2) #### What's Changed - assert: ensure message is always displayed & fix under bazel by [@​cstrahan](https://github.com/cstrahan) in gotestyourself/gotest.tools#276 - go.mod: golang.org/x/tools v0.13.0 for go1.22+ compatibility by [@​thaJeztah](https://github.com/thaJeztah) in gotestyourself/gotest.tools#282 - poll: Continue(): use format.Message for formatting by [@​thaJeztah](https://github.com/thaJeztah) in gotestyourself/gotest.tools#279 - fix TestFromDirSymlink on Windows due to missing drive-letter by [@​thaJeztah](https://github.com/thaJeztah) in gotestyourself/gotest.tools#283 - Fix various linting issues and minor bugs by [@​thaJeztah](https://github.com/thaJeztah) in gotestyourself/gotest.tools#280 - fix badges in readme, gofmt, and minor linting fix by [@​thaJeztah](https://github.com/thaJeztah) in gotestyourself/gotest.tools#284 - circleci: add go1.21, go1.22, go1.23, and update golangci-lint to v1.60.3 by [@​thaJeztah](https://github.com/thaJeztah) in gotestyourself/gotest.tools#285 - assert, assert/cmp: un-deprecate assert.ErrorType for now by [@​thaJeztah](https://github.com/thaJeztah) in gotestyourself/gotest.tools#286 #### New Contributors - [@​cstrahan](https://github.com/cstrahan) made their first contribution in gotestyourself/gotest.tools#276 **Full Changelog**: gotestyourself/gotest.tools@v3.5.1...v3.5.2 </details> --- ### Configuration 📅 **Schedule**: Branch creation - Between 12:00 AM and 03:59 AM ( * 0-3 * * * ) (UTC), Automerge - Between 12:00 AM and 03:59 AM ( * 0-3 * * * ) (UTC). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMTIuMCIsInVwZGF0ZWRJblZlciI6IjM5LjI1Mi4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119--> Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/524 Co-authored-by: Renovate Bot <[email protected]> Co-committed-by: Renovate Bot <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This test was failing, because it expected the drive-letter to always
be returned, which wasn't the case;
This patch removes the special-case from d44953d,
which unconditionally added the drive-letter. Instead, we only change
the check to use the expected directory-separator.