UNPKG

phaser

Version:

A fast, free and fun HTML5 Game Framework for Desktop and Mobile web browsers from the team at Phaser Studio Inc.

32 lines (26 loc) 769 B
var NULL = require('../../src/utils/NULL'); describe('Phaser.Utils.NULL', function () { it('should be a function', function () { expect(typeof NULL).toBe('function'); }); it('should return null when called with no arguments', function () { expect(NULL()).toBeNull(); }); it('should return null when called with arguments', function () { expect(NULL(1, 2, 3)).toBeNull(); }); it('should return null when called with object arguments', function () { expect(NULL({ a: 1 }, [1, 2])).toBeNull(); }); it('should always return null on repeated calls', function () { expect(NULL()).toBeNull(); expect(NULL()).toBeNull(); expect(NULL()).toBeNull(); }); });