mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-21 03:26:01 +00:00
Minimize use of jtx::with_only_features (RIPD-1515):
In order to automatically run unit tests with newly created amendments, prefer to start with jtx::supported_features() and then subtract unwanted features. These changes identified a few bugs that were hiding in amendments. One of those bugs, in FlowCross, is not yet fixed. By uncommenting the test in CrossingLimits_test.cpp you can see failures relating to that bug. Since FlowCross is not yet enabled on the network we can fix the bug at our convenience.
This commit is contained in:
@@ -117,10 +117,6 @@ class Feature_test : public beast::unit_test::suite
|
||||
using namespace test::jtx;
|
||||
Env env {*this,
|
||||
with_only_features(featureEscrow, featureCryptoConditions)};
|
||||
// The amendment table has to be modified
|
||||
// since that is what feature RPC actually checks
|
||||
env.app().getAmendmentTable().enable(featureEscrow);
|
||||
env.app().getAmendmentTable().enable(featureCryptoConditions);
|
||||
|
||||
auto jrr = env.rpc("feature") [jss::result];
|
||||
if(! BEAST_EXPECT(jrr.isMember(jss::features)))
|
||||
@@ -221,9 +217,6 @@ class Feature_test : public beast::unit_test::suite
|
||||
using namespace test::jtx;
|
||||
Env env {*this,
|
||||
with_only_features(featureCryptoConditions)};
|
||||
// The amendment table has to be modified
|
||||
// since that is what feature RPC actually checks
|
||||
env.app().getAmendmentTable().enable(featureCryptoConditions);
|
||||
|
||||
auto jrr = env.rpc("feature", "CryptoConditions") [jss::result];
|
||||
if(! BEAST_EXPECTS(jrr[jss::status] == jss::success, "status"))
|
||||
|
||||
Reference in New Issue
Block a user