fixed api tests using the same db_session and added test db