Change tests to depend on behavior instead of implementation