Skip to content

QuickCheck PathName function may produce bad paths on Windows #9253

Closed
@geekosaur

Description

@geekosaur

Describe the bug
A review of the QuickCheck instances (as part of #9241 debugging) revealed that arbitraryShortPath does not check for illegal characters on Windows, nor for device names (CON, LPT, etc.) which cannot be used as file or directory names.

To Reproduce
See https://github.com/haskell/cabal/blob/master/Cabal-QuickCheck/src/Test/QuickCheck/Instances/Cabal.hs#L508-L509

Expected behavior
It should produce pathnames valid on any system that we support.

System information

  • Operating system: Windows
  • cabal, ghc versions: any

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions