[PR #763] [CLOSED] tests: expect the unreadable path as OSError prints it (bink_names, opus_tags, world_names) (OLD-10046) #801

Closed
opened 2026-11-26 20:19:05 +01:00 by 4ld0 · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ubiquitarianism/leonida/pull/763
Author: @abnalstlll-byte
Created: 11/24/2026
Status: ❌ Closed

Base: main ← Head: restore/old-10046-tests-oserror-repr


📝 Commits (1)

  • e04c421 tests: expect the unreadable path as OSError prints it (bink_names, opus_tags, world_names)

📊 Changes

3 files changed (+6 additions, -3 deletions)

View changed files

📝 tests/test_bink_names.py (+2 -1)
📝 tests/test_opus_tags.py (+2 -1)
📝 tests/test_world_names.py (+2 -1)

📄 Description

Carries old PR 10046 (draft #312, old-pr/10046 by @icecreammule277-dot), rebased cleanly on current main (2d73c242f).

What this does

Each test makes the tree walk report an unreadable folder and asserts the folder's path appears in the tool's error message. The message embeds str(OSError), which prints the filename with repr(), so on Windows every backslash is doubled and assertIn(path, message) misses. Expect repr(path), which is the exact text OSError produces on Windows while remaining identical on POSIX.

Verification

  • python -I tests/test_world_names.py: 31/31 PASS (resolves Windows failure)
  • python -I tests/test_bink_names.py: 36/36 PASS (resolves Windows failure)
  • python -I tests/test_opus_tags.py: 28/28 PASS (resolves Windows failure)
  • python -I scripts/check_no_game_data.py: clean
  • Standard library only, no game data. AI-assisted.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ubiquitarianism/leonida/pull/763 **Author:** [@abnalstlll-byte](https://github.com/abnalstlll-byte) **Created:** 11/24/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `restore/old-10046-tests-oserror-repr` --- ### 📝 Commits (1) - [`e04c421`](https://github.com/ubiquitarianism/leonida/commit/e04c42163fd49be3f1b7df89917a949dcba7a6de) tests: expect the unreadable path as OSError prints it (bink_names, opus_tags, world_names) ### 📊 Changes **3 files changed** (+6 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `tests/test_bink_names.py` (+2 -1) 📝 `tests/test_opus_tags.py` (+2 -1) 📝 `tests/test_world_names.py` (+2 -1) </details> ### 📄 Description Carries old PR 10046 (draft #312, old-pr/10046 by @icecreammule277-dot), rebased cleanly on current main (2d73c242f). ### What this does Each test makes the tree walk report an unreadable folder and asserts the folder's path appears in the tool's error message. The message embeds str(OSError), which prints the filename with repr(), so on Windows every backslash is doubled and assertIn(path, message) misses. Expect repr(path), which is the exact text OSError produces on Windows while remaining identical on POSIX. ### Verification - python -I tests/test_world_names.py: 31/31 PASS (resolves Windows failure) - python -I tests/test_bink_names.py: 36/36 PASS (resolves Windows failure) - python -I tests/test_opus_tags.py: 28/28 PASS (resolves Windows failure) - python -I scripts/check_no_game_data.py: clean - Standard library only, no game data. AI-assisted. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
4ld0 2026-11-26 20:19:05 +01:00
Sign in to join this conversation.
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
starred/leonida#801
No description provided.