diff --git a/scripts/tests/api_compare/filter-list b/scripts/tests/api_compare/filter-list index 72b86badc3f..86a63a4f652 100644 --- a/scripts/tests/api_compare/filter-list +++ b/scripts/tests/api_compare/filter-list @@ -8,5 +8,3 @@ !Filecoin.EthGetTransactionReceipt # TODO(elmattic): https://github.com/ChainSafe/forest/issues/4851 !Filecoin.EthGetLogs -# Enable after Lotus image is upgraded to a release in which F3IntitialPowerTable is hard coded. -!Filecoin.F3GetManifest diff --git a/scripts/tests/api_compare/filter-list-offline b/scripts/tests/api_compare/filter-list-offline index 5cf6744f86d..de674265116 100644 --- a/scripts/tests/api_compare/filter-list-offline +++ b/scripts/tests/api_compare/filter-list-offline @@ -14,6 +14,13 @@ !Filecoin.NetProtectList # Most F3 methods are not avaiable on offline Forest RPC server !Filecoin.F3GetManifest +!Filecoin.F3GetLatestCertificate +!Filecoin.F3ListParticipants +!Filecoin.F3GetProgress +!Filecoin.F3IsRunning +!Filecoin.F3GetCertificate +!Filecoin.F3GetOrRenewParticipationTicket +!Filecoin.F3GetF3PowerTable # CustomCheckFailed in Forest: https://github.com/ChainSafe/forest/actions/runs/9593268587/job/26453560366 !Filecoin.StateReplay # CustomCheckFailed in Forest: https://github.com/ChainSafe/forest/actions/runs/9593268587/job/26453560366 diff --git a/src/tool/subcommands/api_cmd.rs b/src/tool/subcommands/api_cmd.rs index 4c634a5c53b..490d09a63fd 100644 --- a/src/tool/subcommands/api_cmd.rs +++ b/src/tool/subcommands/api_cmd.rs @@ -1624,15 +1624,32 @@ fn gas_tests_with_tipset(shared_tipset: &Tipset) -> Vec { )] } -fn f3_tests_with_tipset(tipset: &Tipset) -> anyhow::Result> { +fn f3_tests() -> anyhow::Result> { Ok(vec![ // using basic because 2 nodes are not garanteed to be at the same head RpcTest::basic(F3GetECPowerTable::request((None.into(),))?), - RpcTest::identity(F3GetECPowerTable::request((tipset.key().into(),))?), + RpcTest::basic(F3GetLatestCertificate::request(())?), + RpcTest::basic(F3ListParticipants::request(())?), + RpcTest::basic(F3GetProgress::request(())?), + RpcTest::basic(F3GetOrRenewParticipationTicket::request(( + Address::new_id(1000), + vec![], + 3, + ))?), + RpcTest::identity(F3IsRunning::request(())?), + RpcTest::identity(F3GetCertificate::request((0,))?), + RpcTest::identity(F3GetCertificate::request((1000,))?), RpcTest::identity(F3GetManifest::request(())?), ]) } +fn f3_tests_with_tipset(tipset: &Tipset) -> anyhow::Result> { + Ok(vec![ + RpcTest::identity(F3GetECPowerTable::request((tipset.key().into(),))?), + RpcTest::identity(F3GetF3PowerTable::request((tipset.key().into(),))?), + ]) +} + // Extract tests that use chain-specific data such as block CIDs or message // CIDs. Right now, only the last `n_tipsets` tipsets are used. fn snapshot_tests( @@ -1733,6 +1750,7 @@ fn create_tests( tests.extend(wallet_tests(worker_address)); tests.extend(eth_tests()); tests.extend(state_tests()); + tests.extend(f3_tests()?); if !snapshot_files.is_empty() { let store = Arc::new(ManyCar::try_from(snapshot_files)?); tests.extend(snapshot_tests(