Fix setInstace class declaration
Fix tests