add test for import transaction, add check for account in session and refactor