AG-3863: refactoring test contexts