Skip to content

Commit 52083c8

Browse files
authored
Merge pull request #5434 from IntersectMBO/carlos/add-reproducer-for-5418
Add Imp test reproducer for #5418
2 parents 1258f44 + 5c53fa7 commit 52083c8

File tree

2 files changed

+45
-1
lines changed
  • eras/conway/impl/testlib/Test/Cardano/Ledger/Conway/Imp
  • libs/cardano-ledger-conformance/test/Test/Cardano/Ledger/Conformance/Spec/Conway

2 files changed

+45
-1
lines changed

eras/conway/impl/testlib/Test/Cardano/Ledger/Conway/Imp/RatifySpec.hs

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,48 @@ spoAndCCVotingSpec = do
236236
logRatificationChecks constitutionActionId
237237
passNEpochs 2
238238
getConstitution `shouldNotReturn` newConstitution
239+
-- https://github.com/IntersectMBO/cardano-ledger/issues/5418
240+
-- TODO: Re-enable after issue is resolved, by removing this override
241+
disableInConformanceIt "Committee proposals pass with inactive committee" $
242+
whenPostBootstrap $ do
243+
modifyPParams $ \pp ->
244+
pp
245+
& ppCommitteeMinSizeL .~ 2
246+
& ppCommitteeMaxTermLengthL .~ EpochInterval 50
247+
coldCommitteeActive <- KeyHashObj <$> freshKeyHash
248+
coldCommitteeInactive <- KeyHashObj <$> freshKeyHash
249+
startingEpoch <- getsNES nesELL
250+
maxTermLength <- getsPParams ppCommitteeMaxTermLengthL
251+
(drep, _, _) <- setupSingleDRep 1_000_000_000
252+
(spo, _, _) <- setupPoolWithStake $ Coin 1_000_000_000
253+
let
254+
committeeMap =
255+
[ (coldCommitteeActive, addEpochInterval startingEpoch maxTermLength)
256+
, (coldCommitteeInactive, addEpochInterval startingEpoch $ EpochInterval 5)
257+
]
258+
initialCommittee <- getCommitteeMembers
259+
committeeActionId <-
260+
impAnn "Submit committee update"
261+
. submitGovAction
262+
$ UpdateCommittee
263+
SNothing
264+
initialCommittee
265+
committeeMap
266+
(0 %! 1)
267+
submitYesVote_ (DRepVoter drep) committeeActionId
268+
submitYesVote_ (StakePoolVoter spo) committeeActionId
269+
passNEpochs 5
270+
getCommitteeMembers `shouldReturn` Map.keysSet committeeMap
271+
committeeProposal <-
272+
elements
273+
[ NoConfidence (SJust (GovPurposeId committeeActionId))
274+
, UpdateCommittee (SJust (GovPurposeId committeeActionId)) Set.empty [] (0 %! 1)
275+
]
276+
committeeActionId2 <- submitGovAction committeeProposal
277+
submitYesVote_ (DRepVoter drep) committeeActionId2
278+
submitYesVote_ (StakePoolVoter spo) committeeActionId2
279+
passNEpochs 2
280+
getLastEnactedCommittee `shouldReturn` SJust (GovPurposeId committeeActionId2)
239281

240282
committeeExpiryResignationDiscountSpec ::
241283
forall era.

libs/cardano-ledger-conformance/test/Test/Cardano/Ledger/Conformance/Spec/Conway/Ratify.hs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,9 @@ conformsToImplAccepted impl agda = property $ do
8080

8181
spec :: Spec
8282
spec = describe "RATIFY" $ do
83-
prop "STS" $ conformsToImplConstrained_ constrainedRatify
83+
-- https://github.com/IntersectMBO/cardano-ledger/issues/5418
84+
-- TODO: Re-enable after issue is resolved, by removing this override
85+
xprop "STS" $ conformsToImplConstrained_ constrainedRatify
8486
describe "Accepted" $ do
8587
forM_
8688
[ ("DRep", (dRepAccepted, Agda.acceptedByDRep))

0 commit comments

Comments
 (0)