Alexander Lapin created IGNITE-19916: ----------------------------------------
Summary: TX SQL tests refactoring with the help of @TestOnly IgniteImpl#txManager and TxManager#pending Key: IGNITE-19916 URL: https://issues.apache.org/jira/browse/IGNITE-19916 Project: Ignite Issue Type: Improvement Reporter: Alexander Lapin h3. Motivation Rather often it's required to check whether all transactions that were started by SQL are properly finished. Currently, reflection along with crappy txnState checks are used: {code:java} TxManager txManagerInternal = (TxManager) IgniteTestUtils.getFieldValue(CLUSTER_NODES.get(0), IgniteImpl.class, "txManager"); var states = (Map<UUID, TxState>) IgniteTestUtils.getFieldValue(txManagerInternal, TxManagerImpl.class, "states"); assertEquals(txManagerInternal.finished(), states.size());{code} After implementing https://issues.apache.org/jira/browse/IGNITE-19663 it should be possible to rewrite code above with {code:java} assertEquals(0, ((IgniteImpl) CLUSTER_NODES.get(0)).txManager().pending()); {code} or similar. h3. Definition of Done All required sql tx tests are simplified through TxManager#pending() -- This message was sent by Atlassian Jira (v8.20.10#820010)