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

fix: Support relative paths with multiple subfolders in Directory.GetFiles #332

Merged
merged 3 commits into from
Jul 17, 2023

Conversation

ElStefan
Copy link
Contributor

FileSystem.Directory.GetFiles(string path) returns an invalid file path when the argument consists of .. and two subfolders, when the current directory was located in the first subfolder.
The returned file path contains the second subfolder twice. (e.g. ..\subfolder1\subfolder2\subfolder2\file.txt)

@vbreuss vbreuss added the bug Something isn't working label Jul 17, 2023
@vbreuss vbreuss enabled auto-merge (squash) July 17, 2023 16:49
@vbreuss vbreuss merged commit bdecd1b into Testably:main Jul 17, 2023
9 checks passed
vbreuss pushed a commit that referenced this pull request Jul 18, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[Testably.Abstractions](https://togithub.com/Testably/Testably.Abstractions)
| nuget | patch | `2.3.1` -> `2.3.2` |

---

### Release Notes

<details>
<summary>Testably/Testably.Abstractions
(Testably.Abstractions)</summary>

###
[`v2.3.2`](https://togithub.com/Testably/Testably.Abstractions/releases/tag/v2.3.2)

#### What's Changed

- chore(deps): update dependency microsoft.net.test.sdk to v17.6.0 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#310
- chore(deps): update dependency microsoft.codeanalysis.csharp to v4.6.0
by [@&#8203;renovate](https://togithub.com/renovate) in
[#311
- chore(deps): update dependency testableio.system.io.abstractions to
v19.2.29 by [@&#8203;renovate](https://togithub.com/renovate) in
[#312
- coverage: Add tests for correct update of the exists cache for
IFileInfo and IDirectoryInfo by
[@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#313
- chore(deps): update dependency coverlet.collector to v6 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#314
- chore(deps): update danielpalme/reportgenerator-github-action action
to v5.1.21 by [@&#8203;renovate](https://togithub.com/renovate) in
[#315
- chore(deps): update dependency microsoft.net.test.sdk to v17.6.1 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#317
- fix: failing tests on .NET framework by
[@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#320
- chore(deps): update dependency microsoft.net.test.sdk to v17.6.2 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#318
- chore(deps): update danielpalme/reportgenerator-github-action action
to v5.1.22 by [@&#8203;renovate](https://togithub.com/renovate) in
[#319
- chore(deps): update dependency microsoft.net.test.sdk to v17.6.3 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#321
- chore(deps): update danielpalme/reportgenerator-github-action action
to v5.1.23 by [@&#8203;renovate](https://togithub.com/renovate) in
[#322
- chore(deps): update dependency xunit to v2.5.0 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#323
- chore(deps): update dependency xunit.runner.visualstudio to v2.5.0 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#324
- docs: include information for local testing against the
`RealFileSystem` by [@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#325
- refactor: Use central package management by
[@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#316
- chore(deps): update dependency microsoft.net.test.sdk to v17.6.3 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#326
- feat: Add a sample Directory.Build.props by
[@&#8203;ElStefan](https://togithub.com/ElStefan) in
[#328
- fix: Remove single quotes from test by
[@&#8203;ElStefan](https://togithub.com/ElStefan) in
[#329
- chore(deps): update dependencies by
[@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#333
- fix: Support relative paths with multiple subfolders in
Directory.GetFiles by [@&#8203;ElStefan](https://togithub.com/ElStefan)
in
[#332

#### New Contributors

- [@&#8203;ElStefan](https://togithub.com/ElStefan) made their first
contribution in
[#328

**Full Changelog**:
v2.3.1...v2.3.2

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **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 [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/Testably/Testably.Abstractions).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi44LjExIiwidXBkYXRlZEluVmVyIjoiMzYuOC4xMSIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
vbreuss pushed a commit that referenced this pull request Jul 18, 2023
#330)

[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[Testably.Abstractions.Testing](https://togithub.com/Testably/Testably.Abstractions)
| nuget | patch | `2.3.1` -> `2.3.2` |

---

### Release Notes

<details>
<summary>Testably/Testably.Abstractions
(Testably.Abstractions.Testing)</summary>

###
[`v2.3.2`](https://togithub.com/Testably/Testably.Abstractions/releases/tag/v2.3.2)

#### What's Changed

- chore(deps): update dependency microsoft.net.test.sdk to v17.6.0 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#310
- chore(deps): update dependency microsoft.codeanalysis.csharp to v4.6.0
by [@&#8203;renovate](https://togithub.com/renovate) in
[#311
- chore(deps): update dependency testableio.system.io.abstractions to
v19.2.29 by [@&#8203;renovate](https://togithub.com/renovate) in
[#312
- coverage: Add tests for correct update of the exists cache for
IFileInfo and IDirectoryInfo by
[@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#313
- chore(deps): update dependency coverlet.collector to v6 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#314
- chore(deps): update danielpalme/reportgenerator-github-action action
to v5.1.21 by [@&#8203;renovate](https://togithub.com/renovate) in
[#315
- chore(deps): update dependency microsoft.net.test.sdk to v17.6.1 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#317
- fix: failing tests on .NET framework by
[@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#320
- chore(deps): update dependency microsoft.net.test.sdk to v17.6.2 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#318
- chore(deps): update danielpalme/reportgenerator-github-action action
to v5.1.22 by [@&#8203;renovate](https://togithub.com/renovate) in
[#319
- chore(deps): update dependency microsoft.net.test.sdk to v17.6.3 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#321
- chore(deps): update danielpalme/reportgenerator-github-action action
to v5.1.23 by [@&#8203;renovate](https://togithub.com/renovate) in
[#322
- chore(deps): update dependency xunit to v2.5.0 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#323
- chore(deps): update dependency xunit.runner.visualstudio to v2.5.0 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#324
- docs: include information for local testing against the
`RealFileSystem` by [@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#325
- refactor: Use central package management by
[@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#316
- chore(deps): update dependency microsoft.net.test.sdk to v17.6.3 by
[@&#8203;renovate](https://togithub.com/renovate) in
[#326
- feat: Add a sample Directory.Build.props by
[@&#8203;ElStefan](https://togithub.com/ElStefan) in
[#328
- fix: Remove single quotes from test by
[@&#8203;ElStefan](https://togithub.com/ElStefan) in
[#329
- chore(deps): update dependencies by
[@&#8203;vbreuss](https://togithub.com/vbreuss) in
[#333
- fix: Support relative paths with multiple subfolders in
Directory.GetFiles by [@&#8203;ElStefan](https://togithub.com/ElStefan)
in
[#332

#### New Contributors

- [@&#8203;ElStefan](https://togithub.com/ElStefan) made their first
contribution in
[#328

**Full Changelog**:
v2.3.1...v2.3.2

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **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 [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/Testably/Testably.Abstractions).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi44LjExIiwidXBkYXRlZEluVmVyIjoiMzYuOC4xMSIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
@ElStefan ElStefan deleted the topic/sla/bugfix_relative_paths branch July 18, 2023 08:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants