[XAPID-1037] refactor and add tests
14 files changed