[TASK] Refactor trustline test code

Refactor trustline test code to reduce duplication and check response body before status code and headers
I actually like the original format. It's easier to read IMO