main
Last change
on this file was d565449, checked in by stefan toskovski <stefantoska84@…>, 4 weeks ago |
Update repo after prototype presentation
|
-
Property mode
set to
100644
|
File size:
603 bytes
|
Line | |
---|
1 | 'use strict';
|
---|
2 |
|
---|
3 | var implementation = require('../implementation');
|
---|
4 | var callBind = require('call-bind');
|
---|
5 | var test = require('tape');
|
---|
6 | var hasStrictMode = require('has-strict-mode')();
|
---|
7 | var runTests = require('./tests');
|
---|
8 |
|
---|
9 | test('as a function', function (t) {
|
---|
10 | t.test('bad first arg/receiver', { skip: !hasStrictMode }, function (st) {
|
---|
11 | st['throws'](function () { implementation(undefined); }, TypeError, 'undefined is not an object');
|
---|
12 | st['throws'](function () { implementation(null); }, TypeError, 'null is not an object');
|
---|
13 | st.end();
|
---|
14 | });
|
---|
15 |
|
---|
16 | runTests(callBind(implementation, Object), t);
|
---|
17 |
|
---|
18 | t.end();
|
---|
19 | });
|
---|
Note:
See
TracBrowser
for help on using the repository browser.