diff --git a/test/parse-url.js b/test/parse-url.js index a6c0848..35f8ae4 100644 --- a/test/parse-url.js +++ b/test/parse-url.js @@ -5,6 +5,7 @@ test('handles strings with query string', t => { t.deepEqual(queryString.parseUrl('https://foo.bar#top?foo=bar'), {url: 'https://foo.bar', query: {}}); t.deepEqual(queryString.parseUrl('https://foo.bar?foo=bar&foo=baz#top'), {url: 'https://foo.bar', query: {foo: ['bar', 'baz']}}); t.deepEqual(queryString.parseUrl('https://foo.bar?foo=bar&foo=baz'), {url: 'https://foo.bar', query: {foo: ['bar', 'baz']}}); + t.deepEqual(queryString.parseUrl('https://foo.bar?foo=null'), {url: 'https://foo.bar', query: {foo: 'null'}}); }); test('handles strings not containing query string', t => { diff --git a/test/parse.js b/test/parse.js index e4904e9..17de629 100644 --- a/test/parse.js +++ b/test/parse.js @@ -20,6 +20,7 @@ test('query strings ending with a `&`', t => { test('parse a query string', t => { t.deepEqual(queryString.parse('foo=bar'), {foo: 'bar'}); + t.deepEqual(queryString.parse('foo=null'), {foo: 'null'}); }); test('parse multiple query string', t => {