Clean up and fix server view tests

Reduce a lot of code reuse, make tests more readable, and directly access the database for insert, find, and remove tests to avoid relying on other methods in tests.