}
} ) );
- QUnit.test( 'set( key, value )', 7, function ( assert ) {
+ QUnit.test( 'set( key, value )', function ( assert ) {
var call;
// Simple case
assert.strictEqual( call[ 1 ], '0', '0 is value' );
} );
- QUnit.test( 'set( key, value, expires )', 6, function ( assert ) {
+ QUnit.test( 'set( key, value, expires )', function ( assert ) {
var date, options;
date = new Date();
assert.strictEqual( options.expires, date, 'custom expiration (with wgCookieExpiration=0)' );
} );
- QUnit.test( 'set( key, value, options )', 4, function ( assert ) {
+ QUnit.test( 'set( key, value, options )', function ( assert ) {
var date, call;
mw.cookie.set( 'foo', 'bar', {
}, 'Options (incl. expires)' );
} );
- QUnit.test( 'get( key ) - no values', 6, function ( assert ) {
+ QUnit.test( 'get( key ) - no values', function ( assert ) {
var key, value;
mw.cookie.get( 'foo' );
assert.strictEqual( value, 'bar', 'Custom default value' );
} );
- QUnit.test( 'get( key ) - with value', 1, function ( assert ) {
+ QUnit.test( 'get( key ) - with value', function ( assert ) {
var value;
$.cookie.returns( 'bar' );
assert.strictEqual( value, 'bar', 'Return value of cookie' );
} );
- QUnit.test( 'get( key, prefix )', 1, function ( assert ) {
+ QUnit.test( 'get( key, prefix )', function ( assert ) {
var key;
mw.cookie.get( 'foo', 'bar' );