3 var create = require('../../../object/create')
5 , getPrototypeOf = Object.getPrototypeOf;
7 module.exports = function (t, a) {
10 if (t === null) return;
11 a(t(x, y), x, "Return self object");
12 a(getPrototypeOf(x), y, "Object");
13 a.throws(function () { t(x); }, TypeError, "Undefined");
14 a.throws(function () { t('foo'); }, TypeError, "Primitive");
15 a(getPrototypeOf(t(x, null)), t.nullPolyfill || null, "Null");
17 a.h1("Change null prototype");
18 a(t(x, y), x, "Result");
19 a(getPrototypeOf(x), y, "Prototype");
20 a.h1("Set null prototype");
21 a(t(y, null), y, "Result");
22 a(getPrototypeOf(y), t.nullPolyfill || null, "Prototype");