fixed some broken tests and api
fixed tests and api