Implement tests with sorting on texts