|
18 | 18 | //============================================================================== |
19 | 19 |
|
20 | 20 | #include <test/jtx.h> |
| 21 | +#include <test/jtx/permissioned_domains.h> |
21 | 22 |
|
22 | 23 | #include <xrpl/protocol/Feature.h> |
| 24 | +#include <xrpl/protocol/TER.h> |
23 | 25 | #include <xrpl/protocol/jss.h> |
24 | 26 |
|
25 | 27 | namespace ripple { |
@@ -1251,21 +1253,48 @@ class AccountDelete_test : public beast::unit_test::suite |
1251 | 1253 | } |
1252 | 1254 | } |
1253 | 1255 |
|
| 1256 | + void |
| 1257 | + testDeletePermissionedDomainOwner() |
| 1258 | + { |
| 1259 | + using namespace jtx; |
| 1260 | + |
| 1261 | + Env env{*this}; |
| 1262 | + Account alice{"alice"}; |
| 1263 | + Account becky{"becky"}; |
| 1264 | + env.fund(XRP(1000), alice, becky); |
| 1265 | + env.close(); |
| 1266 | + env(fset(becky, asfDepositAuth)); |
| 1267 | + env.close(); |
| 1268 | + |
| 1269 | + pdomain::Credentials const credentials1{ |
| 1270 | + {.issuer = alice, .credType = "foobaz"}}; |
| 1271 | + |
| 1272 | + env(pdomain::setTx(alice, credentials1)); |
| 1273 | + // Close 256 ledgers |
| 1274 | + for (int i = 0; i < 256; ++i) |
| 1275 | + env.close(); |
| 1276 | + |
| 1277 | + auto const acctDelFee{drops(env.current()->fees().increment)}; |
| 1278 | + env(acctdelete(alice, becky), fee(acctDelFee), ter{tecNO_PERMISSION}); |
| 1279 | + env.close(); |
| 1280 | + } |
| 1281 | + |
1254 | 1282 | void |
1255 | 1283 | run() override |
1256 | 1284 | { |
1257 | | - testBasics(); |
1258 | | - testDirectories(); |
1259 | | - testOwnedTypes(); |
1260 | | - testResurrection(); |
1261 | | - testAmendmentEnable(); |
1262 | | - testTooManyOffers(); |
1263 | | - testImplicitlyCreatedTrustline(); |
1264 | | - testBalanceTooSmallForFee(); |
1265 | | - testWithTickets(); |
1266 | | - testDest(); |
1267 | | - testDestinationDepositAuthCredentials(); |
1268 | | - testDeleteCredentialsOwner(); |
| 1285 | + // testBasics(); |
| 1286 | + // testDirectories(); |
| 1287 | + // testOwnedTypes(); |
| 1288 | + // testResurrection(); |
| 1289 | + // testAmendmentEnable(); |
| 1290 | + // testTooManyOffers(); |
| 1291 | + // testImplicitlyCreatedTrustline(); |
| 1292 | + // testBalanceTooSmallForFee(); |
| 1293 | + // testWithTickets(); |
| 1294 | + // testDest(); |
| 1295 | + // testDestinationDepositAuthCredentials(); |
| 1296 | + // testDeleteCredentialsOwner(); |
| 1297 | + testDeletePermissionedDomainOwner(); |
1269 | 1298 | } |
1270 | 1299 | }; |
1271 | 1300 |
|
|
0 commit comments