Skip to content

[pathlib] Test fail on Windows/WSL #8

Description

@LukeSavefrogs

⚠This issue only affects Windows OS⚠

Tests are failing ONLY on Windows runners.

It almost always includes a path separator mismatch, but it also differs between versions:

Jython 2.5.3 (Windows):
image

Jython 2.2.1 (Windows):
image
image

From Jython 2.5.0 onwards, the failing tests are always the same:

======================================================================
FAIL: test_creation (polyfills.pathlib.__init__.PathTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "src\polyfills\pathlib\__init__.py", line 371, in test_creation
    self.assertEqual(
AssertionError: '/tmp\\test.py' != '\\tmp\\test.py'

======================================================================
FAIL: test_dots (polyfills.pathlib.__init__.PathTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "src\polyfills\pathlib\__init__.py", line 381, in test_dots
    self.assertEqual(str(Path("../..")), "..%s.." % (_os.sep))
AssertionError: '../..' != '..\\..'

----------------------------------------------------------------------
Ran 90 tests in 0.188s

FAILED (failures=2)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions