Skip to content

Commit

Permalink
Remove unit-test guards that aren't needed
Browse files Browse the repository at this point in the history
  • Loading branch information
philderbeast committed Nov 21, 2024
1 parent e81f990 commit 50313b1
Showing 1 changed file with 1 addition and 21 deletions.
22 changes: 1 addition & 21 deletions cabal-install/tests/UnitTests/Distribution/Solver/Modular/DSL.hs
Original file line number Diff line number Diff line change
Expand Up @@ -492,15 +492,7 @@ exAvSrcPkg ex =
-- they are not related to this test suite, and are tested
-- with golden tests.
let checks = C.checkPackage (srcpkgDescription package)
in filter
( \x ->
not (isgtLowerBound x)
&& not (isLeqUpperBound x)
&& not (isTrailingZeroUpperBound x)
&& not (isMissingUpperBound x)
&& not (isUnknownLangExt x)
)
checks
in filter (\x -> not (isMissingUpperBound x) && not (isUnknownLangExt x)) checks
in if null pkgCheckErrors
then package
else
Expand Down Expand Up @@ -723,18 +715,6 @@ exAvSrcPkg ex =
isMissingUpperBound pc = case C.explanation pc of
C.MissingUpperBounds{} -> True
_ -> False
isTrailingZeroUpperBound :: C.PackageCheck -> Bool
isTrailingZeroUpperBound pc = case C.explanation pc of
C.TrailingZeroUpperBounds{} -> True
_ -> False
isLeqUpperBound :: C.PackageCheck -> Bool
isLeqUpperBound pc = case C.explanation pc of
C.LEQUpperBounds{} -> True
_ -> False
isgtLowerBound :: C.PackageCheck -> Bool
isgtLowerBound pc = case C.explanation pc of
C.GTLowerBounds{} -> True
_ -> False

mkSimpleVersion :: ExamplePkgVersion -> C.Version
mkSimpleVersion n = C.mkVersion [n, 0, 0]
Expand Down

0 comments on commit 50313b1

Please sign in to comment.