errors tests: Deduplicate and isolate the magical part.
errors tests: Deduplicate and isolate the magical part.

This makes the tests look a lot more boring and straightforward, in
addition to being a bit shorter.

andersk/zulip,rishig/zulip,synicalsyntax/zulip,andersk/zulip,timabbott/zulip,brainwane/zulip,kou/zulip,shubhamdhama/zulip,synicalsyntax/zulip,punchagan/zulip,synicalsyntax/zulip,dhcrzf/zulip,punchagan/zulip,eeshangarg/zulip,timabbott/zulip,kou/zulip,andersk/zulip,zulip/zulip,timabbott/zulip,shubhamdhama/zulip,jackrzhang/zulip,zulip/zulip,andersk/zulip,showell/zulip,rht/zulip,tommyip/zulip,rishig/zulip,punchagan/zulip,jackrzhang/zulip,synicalsyntax/zulip,tommyip/zulip,hackerkid/zulip,showell/zulip,brainwane/zulip,rht/zulip,showell/zulip,zulip/zulip,kou/zulip,andersk/zulip,tommyip/zulip,shubhamdhama/zulip,punchagan/zulip,brainwane/zulip,hackerkid/zulip,zulip/zulip,hackerkid/zulip,showell/zulip,zulip/zulip,eeshangarg/zulip,rishig/zulip,tommyip/zulip,hackerkid/zulip,brainwane/zulip,rht/zulip,rishig/zulip,eeshangarg/zulip,dhcrzf/zulip,synicalsyntax/zulip,rishig/zulip,dhcrzf/zulip,timabbott/zulip,showell/zulip,dhcrzf/zulip,eeshangarg/zulip,tommyip/zulip,rht/zulip,punchagan/zulip,jackrzhang/zulip,kou/zulip,eeshangarg/zulip,tommyip/zulip,shubhamdhama/zulip,punchagan/zulip,shubhamdhama/zulip,kou/zulip,shubhamdhama/zulip,rht/zulip,eeshangarg/zulip,zulip/zulip,brainwane/zulip,rht/zulip,zulip/zulip,timabbott/zulip,kou/zulip,timabbott/zulip,andersk/zulip,eeshangarg/zulip,kou/zulip,timabbott/zulip,hackerkid/zulip,jackrzhang/zulip,rishig/zulip,rht/zulip,synicalsyntax/zulip,synicalsyntax/zulip,andersk/zulip,showell/zulip,showell/zulip,rishig/zulip,jackrzhang/zulip,dhcrzf/zulip,hackerkid/zulip,tommyip/zulip,dhcrzf/zulip,jackrzhang/zulip,jackrzhang/zulip,dhcrzf/zulip,shubhamdhama/zulip,brainwane/zulip,hackerkid/zulip,brainwane/zulip,punchagan/zulip