Use partial function in test_db