Set objectId in InspectorObject for functions

Modified v8RefToInspectorObject to fill objectId for functions.
Also fixed failing tests.