Needle in haystack multiline expectations
- Add else.project test - Use normalizeWindowsOutput - Add a changelog entry - Update expectation - Use concatOutput on needle - Include output - Align lines - Show modified output - Apply concatOutput to the needle - Show start and end of lines with ASCII ^ and $h - Can't print pilcrow so use grep char for marking end of line - Marking the start of line distinguishes "expected" intro from its content too, same for "output" - Use \n in multiline string expectation - Add NeedleHaystack - Add expectNeedleInHaystack field to NeedleHaystack - Remove 3 assert*Contains functions - Add TxContains record - Apply the txBwd transformations before display - Add displayHaystack field - Switch to using <EOL> as the marker - Sort language pragmas - Use ++ rather than cons with reversals - Rerun ParseErrorProvenance test - Add doctests for single line strings - Read exected multiline string from file - Use lineBreaksToSpaces - Add module Test.Cabal.NeedleHaystack - Redo ConditionalAndImport with multiline expectations - Add test of string expectation start and end marking - Rename encodeLf and decodeLfMarkLines - Rename original concatOutput to lineBreaksToSpaces - Add assertOutputContainsWrapped - Use multiline and wrapped assertions - DedupUsingConfigFromComplex multiline assertion - Remove redundant tests that fail on Windows - Use normalizeWindowsOutput in ConditionalAndImport - Forward conversion applied twice by mistake - Easier diff when assertOn follows assertOutputContains - Add readVerbatimFile - Have readVerbatimFile read contents strictly - Add normalizePathSeparator - Don't modify path separator for URIs - Don't normalize path with anything URI-like - Normalize expected output - Rename to normalizePathSeparators - Add an explicit export list to NeedleHaystack - Drop unlines . lines added trailing newline - Show example of normalizePathSeparators - Use local unsnoc definition to avoid CPP - Define local unlines - Satisfy fix-whitespace - Don't use <EOL> - Rename to delimitLines - Rename the changelog with *.md extension - Add a section on cabal-testsuite changes - Rename the function to readFileVerbatim - Add to contributing and cabal-testsuite's readme - Use setup for the noun - Typo s/displaying/display - Typo "can easier" - Use unsnoc from Cabal-syntax Utils.Generic - Add a note [Multiline Needles] - Remove doctests available elsewhere - Substitute encodeLf for concatOutput for assertOutputMatches
Showing
- CONTRIBUTING.md 6 additions, 3 deletionsCONTRIBUTING.md
- cabal-testsuite/PackageTests/ProjectImport/ParseErrorProvenance/cabal.out 10 additions, 0 deletions...PackageTests/ProjectImport/ParseErrorProvenance/cabal.out
- cabal-testsuite/PackageTests/ProjectImport/ParseErrorProvenance/cabal.test.hs 24 additions, 0 deletions...ageTests/ProjectImport/ParseErrorProvenance/cabal.test.hs
- cabal-testsuite/PackageTests/ProjectImport/ParseErrorProvenance/dir-else/else.config 4 additions, 0 deletions...s/ProjectImport/ParseErrorProvenance/dir-else/else.config
- cabal-testsuite/PackageTests/ProjectImport/ParseErrorProvenance/else.project 1 addition, 0 deletions...kageTests/ProjectImport/ParseErrorProvenance/else.project
- cabal-testsuite/PackageTests/ProjectImport/ParseErrorProvenance/msg.expect.txt 5 additions, 0 deletions...geTests/ProjectImport/ParseErrorProvenance/msg.expect.txt
- cabal-testsuite/README.md 4 additions, 0 deletionscabal-testsuite/README.md
- cabal-testsuite/cabal-testsuite.cabal 2 additions, 0 deletionscabal-testsuite/cabal-testsuite.cabal
- cabal-testsuite/src/Test/Cabal/NeedleHaystack.hs 277 additions, 0 deletionscabal-testsuite/src/Test/Cabal/NeedleHaystack.hs
- cabal-testsuite/src/Test/Cabal/Prelude.hs 62 additions, 18 deletionscabal-testsuite/src/Test/Cabal/Prelude.hs
- changelog.d/pr-10646.md 209 additions, 0 deletionschangelog.d/pr-10646.md
Loading
Please register or sign in to comment