rewrite: add test for 'view raw' feature
rewrite: implement errors as a blueprint