From f18d9d8466a540874d7d099a77f7867306f9cc69 Mon Sep 17 00:00:00 2001 From: Jan Kassens Date: Sun, 18 Jul 2010 21:09:13 +0200 Subject: [PATCH] querystring.js: JSLint warnings fixed --- test/simple/test-querystring.js | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/test/simple/test-querystring.js b/test/simple/test-querystring.js index 40f68d83da..b58c4f863f 100644 --- a/test/simple/test-querystring.js +++ b/test/simple/test-querystring.js @@ -1,5 +1,5 @@ common = require("../common"); -assert = common.assert +assert = common.assert; // test using assert @@ -107,15 +107,18 @@ qsNoMungeTestCases.forEach(function (testCase) { }); // test the nested qs-in-qs case -var f = qs.parse("a=b&q=x%3Dy%26y%3Dz"); -f.q = qs.parse(f.q); -assert.deepEqual(f, { a : "b", q : { x : "y", y : "z" } }); +(function(){ + var f = qs.parse("a=b&q=x%3Dy%26y%3Dz"); + f.q = qs.parse(f.q); + assert.deepEqual(f, { a : "b", q : { x : "y", y : "z" } }); +})(); // nested in colon -var f = qs.parse("a:b;q:x%3Ay%3By%3Az", ";", ":"); -f.q = qs.parse(f.q, ";", ":"); -assert.deepEqual(f, { a : "b", q : { x : "y", y : "z" } }); - +(function(){ + var f = qs.parse("a:b;q:x%3Ay%3By%3Az", ";", ":"); + f.q = qs.parse(f.q, ";", ":"); + assert.deepEqual(f, { a : "b", q : { x : "y", y : "z" } }); +})(); // now test stringifying assert.throws(function () {