test database connection result before creating provider