Tests for invalid custom queries and table page