From ab409db2343c9d16875a2c7370bffc063e871387 Mon Sep 17 00:00:00 2001 From: Jake Date: Thu, 25 Oct 2018 11:22:27 -0700 Subject: [PATCH 01/14] early wip --- package-lock.json | 156 +++++++++--------- .../apollo-server-core/src/ApolloServer.ts | 2 + .../src/__tests__/test-utils.test.ts | 68 ++++++++ 3 files changed, 148 insertions(+), 78 deletions(-) create mode 100644 packages/apollo-server-core/src/__tests__/test-utils.test.ts diff --git a/package-lock.json b/package-lock.json index 7b2a445543b..274a8c78f34 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4215,7 +4215,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -5043,7 +5043,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -5148,7 +5148,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -5223,27 +5223,27 @@ "dependencies": { "abbrev": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "resolved": false, "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", "dev": true, "optional": true }, "ansi-regex": { "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "resolved": false, "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", "dev": true }, "aproba": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", + "resolved": false, "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", "dev": true, "optional": true }, "are-we-there-yet": { "version": "1.1.4", - "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.4.tgz", + "resolved": false, "integrity": "sha1-u13KOCu5TwXhUZQ3PRb9O6HKEQ0=", "dev": true, "optional": true, @@ -5254,13 +5254,13 @@ }, "balanced-match": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "resolved": false, "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", "dev": true }, "brace-expansion": { "version": "1.1.11", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "resolved": false, "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, "requires": { @@ -5270,39 +5270,39 @@ }, "chownr": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.0.1.tgz", + "resolved": false, "integrity": "sha1-4qdQQqlVGQi+vSW4Uj1fl2nXkYE=", "dev": true, "optional": true }, "code-point-at": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", + "resolved": false, "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", "dev": true }, "concat-map": { "version": "0.0.1", - "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "resolved": false, "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", "dev": true }, "console-control-strings": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", + "resolved": false, "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=", "dev": true }, "core-util-is": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "resolved": false, "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", "dev": true, "optional": true }, "debug": { "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "resolved": false, "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "dev": true, "optional": true, @@ -5312,28 +5312,28 @@ }, "deep-extend": { "version": "0.5.1", - "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.5.1.tgz", + "resolved": false, "integrity": "sha512-N8vBdOa+DF7zkRrDCsaOXoCs/E2fJfx9B9MrKnnSiHNh4ws7eSys6YQE4KvT1cecKmOASYQBhbKjeuDD9lT81w==", "dev": true, "optional": true }, "delegates": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", + "resolved": false, "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=", "dev": true, "optional": true }, "detect-libc": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", + "resolved": false, "integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups=", "dev": true, "optional": true }, "fs-minipass": { "version": "1.2.5", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.5.tgz", + "resolved": false, "integrity": "sha512-JhBl0skXjUPCFH7x6x61gQxrKyXsxB5gcgePLZCwfyCGGsTISMoIeObbrvVeP6Xmyaudw4TT43qV2Gz+iyd2oQ==", "dev": true, "optional": true, @@ -5343,14 +5343,14 @@ }, "fs.realpath": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "resolved": false, "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", "dev": true, "optional": true }, "gauge": { "version": "2.7.4", - "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", + "resolved": false, "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", "dev": true, "optional": true, @@ -5367,7 +5367,7 @@ }, "glob": { "version": "7.1.2", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", + "resolved": false, "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", "dev": true, "optional": true, @@ -5382,14 +5382,14 @@ }, "has-unicode": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", + "resolved": false, "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=", "dev": true, "optional": true }, "iconv-lite": { "version": "0.4.21", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.21.tgz", + "resolved": false, "integrity": "sha512-En5V9za5mBt2oUA03WGD3TwDv0MKAruqsuxstbMUZaj9W9k/m1CV/9py3l0L5kw9Bln8fdHQmzHSYtvpvTLpKw==", "dev": true, "optional": true, @@ -5399,7 +5399,7 @@ }, "ignore-walk": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-3.0.1.tgz", + "resolved": false, "integrity": "sha512-DTVlMx3IYPe0/JJcYP7Gxg7ttZZu3IInhuEhbchuqneY9wWe5Ojy2mXLBaQFUQmo0AW2r3qG7m1mg86js+gnlQ==", "dev": true, "optional": true, @@ -5409,7 +5409,7 @@ }, "inflight": { "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "resolved": false, "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "dev": true, "optional": true, @@ -5420,20 +5420,20 @@ }, "inherits": { "version": "2.0.3", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "resolved": false, "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=", "dev": true }, "ini": { "version": "1.3.5", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", + "resolved": false, "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==", "dev": true, "optional": true }, "is-fullwidth-code-point": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "resolved": false, "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", "dev": true, "requires": { @@ -5442,14 +5442,14 @@ }, "isarray": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "resolved": false, "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", "dev": true, "optional": true }, "minimatch": { "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "resolved": false, "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "dev": true, "requires": { @@ -5458,13 +5458,13 @@ }, "minimist": { "version": "0.0.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "resolved": false, "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", "dev": true }, "minipass": { "version": "2.2.4", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-2.2.4.tgz", + "resolved": false, "integrity": "sha512-hzXIWWet/BzWhYs2b+u7dRHlruXhwdgvlTMDKC6Cb1U7ps6Ac6yQlR39xsbjWJE377YTCtKwIXIpJ5oP+j5y8g==", "dev": true, "requires": { @@ -5474,7 +5474,7 @@ }, "minizlib": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.1.0.tgz", + "resolved": false, "integrity": "sha512-4T6Ur/GctZ27nHfpt9THOdRZNgyJ9FZchYO1ceg5S8Q3DNLCKYy44nCZzgCJgcvx2UM8czmqak5BCxJMrq37lA==", "dev": true, "optional": true, @@ -5484,7 +5484,7 @@ }, "mkdirp": { "version": "0.5.1", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "resolved": false, "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", "dev": true, "requires": { @@ -5493,14 +5493,14 @@ }, "ms": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "resolved": false, "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", "dev": true, "optional": true }, "needle": { "version": "2.2.0", - "resolved": "https://registry.npmjs.org/needle/-/needle-2.2.0.tgz", + "resolved": false, "integrity": "sha512-eFagy6c+TYayorXw/qtAdSvaUpEbBsDwDyxYFgLZ0lTojfH7K+OdBqAF7TAFwDokJaGpubpSGG0wO3iC0XPi8w==", "dev": true, "optional": true, @@ -5512,7 +5512,7 @@ }, "node-pre-gyp": { "version": "0.10.0", - "resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.10.0.tgz", + "resolved": false, "integrity": "sha512-G7kEonQLRbcA/mOoFoxvlMrw6Q6dPf92+t/l0DFSMuSlDoWaI9JWIyPwK0jyE1bph//CUEL65/Fz1m2vJbmjQQ==", "dev": true, "optional": true, @@ -5531,7 +5531,7 @@ }, "nopt": { "version": "4.0.1", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.1.tgz", + "resolved": false, "integrity": "sha1-0NRoWv1UFRk8jHUFYC0NF81kR00=", "dev": true, "optional": true, @@ -5542,14 +5542,14 @@ }, "npm-bundled": { "version": "1.0.3", - "resolved": "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.0.3.tgz", + "resolved": false, "integrity": "sha512-ByQ3oJ/5ETLyglU2+8dBObvhfWXX8dtPZDMePCahptliFX2iIuhyEszyFk401PZUNQH20vvdW5MLjJxkwU80Ow==", "dev": true, "optional": true }, "npm-packlist": { "version": "1.1.10", - "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-1.1.10.tgz", + "resolved": false, "integrity": "sha512-AQC0Dyhzn4EiYEfIUjCdMl0JJ61I2ER9ukf/sLxJUcZHfo+VyEfz2rMJgLZSS1v30OxPQe1cN0LZA1xbcaVfWA==", "dev": true, "optional": true, @@ -5560,7 +5560,7 @@ }, "npmlog": { "version": "4.1.2", - "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", + "resolved": false, "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", "dev": true, "optional": true, @@ -5573,20 +5573,20 @@ }, "number-is-nan": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", + "resolved": false, "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", "dev": true }, "object-assign": { "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "resolved": false, "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", "dev": true, "optional": true }, "once": { "version": "1.4.0", - "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "resolved": false, "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "dev": true, "requires": { @@ -5595,21 +5595,21 @@ }, "os-homedir": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "resolved": false, "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", "dev": true, "optional": true }, "os-tmpdir": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "resolved": false, "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true, "optional": true }, "osenv": { "version": "0.1.5", - "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz", + "resolved": false, "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==", "dev": true, "optional": true, @@ -5620,21 +5620,21 @@ }, "path-is-absolute": { "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "resolved": false, "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true, "optional": true }, "process-nextick-args": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz", + "resolved": false, "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==", "dev": true, "optional": true }, "rc": { "version": "1.2.7", - "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.7.tgz", + "resolved": false, "integrity": "sha512-LdLD8xD4zzLsAT5xyushXDNscEjB7+2ulnl8+r1pnESlYtlJtVSoCMBGr30eDRJ3+2Gq89jK9P9e4tCEH1+ywA==", "dev": true, "optional": true, @@ -5647,7 +5647,7 @@ "dependencies": { "minimist": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": false, "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true, "optional": true @@ -5656,7 +5656,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": false, "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "optional": true, @@ -5672,7 +5672,7 @@ }, "rimraf": { "version": "2.6.2", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.2.tgz", + "resolved": false, "integrity": "sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w==", "dev": true, "optional": true, @@ -5682,48 +5682,48 @@ }, "safe-buffer": { "version": "5.1.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.1.tgz", + "resolved": false, "integrity": "sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg==", "dev": true }, "safer-buffer": { "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "resolved": false, "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", "dev": true, "optional": true }, "sax": { "version": "1.2.4", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", + "resolved": false, "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==", "dev": true, "optional": true }, "semver": { "version": "5.5.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.5.0.tgz", + "resolved": false, "integrity": "sha512-4SJ3dm0WAwWy/NVeioZh5AntkdJoWKxHxcmyP622fOkgHa4z3R0TdBJICINyaSDE6uNwVc8gZr+ZinwZAH4xIA==", "dev": true, "optional": true }, "set-blocking": { "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "resolved": false, "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true, "optional": true }, "signal-exit": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", + "resolved": false, "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", "dev": true, "optional": true }, "string-width": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "resolved": false, "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", "dev": true, "requires": { @@ -5734,7 +5734,7 @@ }, "string_decoder": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "resolved": false, "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "dev": true, "optional": true, @@ -5744,7 +5744,7 @@ }, "strip-ansi": { "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "resolved": false, "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { @@ -5753,14 +5753,14 @@ }, "strip-json-comments": { "version": "2.0.1", - "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "resolved": false, "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", "dev": true, "optional": true }, "tar": { "version": "4.4.1", - "resolved": "https://registry.npmjs.org/tar/-/tar-4.4.1.tgz", + "resolved": false, "integrity": "sha512-O+v1r9yN4tOsvl90p5HAP4AEqbYhx4036AGMm075fH9F8Qwi3oJ+v4u50FkT/KkvywNGtwkk0zRI+8eYm1X/xg==", "dev": true, "optional": true, @@ -5776,14 +5776,14 @@ }, "util-deprecate": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "resolved": false, "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", "dev": true, "optional": true }, "wide-align": { "version": "1.1.2", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.2.tgz", + "resolved": false, "integrity": "sha512-ijDLlyQ7s6x1JgCLur53osjm/UXUYD9+0PbYKrBsYisYXzCxN+HC3mYDNy/dWdmf3AwqwU3CXwDCvsNgGK1S0w==", "dev": true, "optional": true, @@ -5793,13 +5793,13 @@ }, "wrappy": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "resolved": false, "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true }, "yallist": { "version": "3.0.2", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.0.2.tgz", + "resolved": false, "integrity": "sha1-hFK0u36Dx8GI2AQcGoN8dz1ti7k=", "dev": true } @@ -8549,7 +8549,7 @@ }, "onetime": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", + "resolved": "http://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", "integrity": "sha1-ofeDj4MUxRbwXs78vEzP4EtO14k=", "dev": true }, @@ -8582,7 +8582,7 @@ }, "load-json-file": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", + "resolved": "http://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", "integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=", "dev": true, "requires": { @@ -8692,7 +8692,7 @@ }, "onetime": { "version": "1.1.0", - "resolved": "https://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", + "resolved": "http://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", "integrity": "sha1-ofeDj4MUxRbwXs78vEzP4EtO14k=", "dev": true }, @@ -9985,7 +9985,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -11800,7 +11800,7 @@ "dependencies": { "minimist": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true } @@ -12212,7 +12212,7 @@ }, "minimist": { "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true }, @@ -12313,9 +12313,9 @@ "dev": true }, "typescript": { - "version": "3.2.0-dev.20181030", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.2.0-dev.20181030.tgz", - "integrity": "sha512-UqZfZY7xAojS2f9SdLTEJ78Itxs1rlZZSlIHffQwFxdnO/jhMBmcVgaVpT+dsjnbuWnZKcX3Dozkdw06TjB8pg==", + "version": "3.2.0-dev.20181101", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.2.0-dev.20181101.tgz", + "integrity": "sha512-7OL68e1Ab4L5EyKsscjgta0i6tiwzzeYCnmd6sLOJyy0GAvvuNKbtHQlICBhF227z8K0P8r/OQoL32If5So2Cw==", "dev": true }, "uglify-js": { diff --git a/packages/apollo-server-core/src/ApolloServer.ts b/packages/apollo-server-core/src/ApolloServer.ts index f4c57d8243c..208cdf19353 100644 --- a/packages/apollo-server-core/src/ApolloServer.ts +++ b/packages/apollo-server-core/src/ApolloServer.ts @@ -502,4 +502,6 @@ export class ApolloServerBase { ...this.requestOptions, } as GraphQLOptions; } + + // public async executeOperation() {} } diff --git a/packages/apollo-server-core/src/__tests__/test-utils.test.ts b/packages/apollo-server-core/src/__tests__/test-utils.test.ts new file mode 100644 index 00000000000..e2b713a8577 --- /dev/null +++ b/packages/apollo-server-core/src/__tests__/test-utils.test.ts @@ -0,0 +1,68 @@ +import { ApolloServerBase, gql } from '../'; +import { processGraphQLRequest, GraphQLRequest } from '../requestPipeline'; + +/** +@Jake @james yep, `processGraphQLRequest` is the entry point to the request +pipeline. with an incoming HTTP request this is invoked by `runHttpQuery`, but +for testing we'd want to call it directly. + +so we should add a method (`executeOperation`?) to `ApolloServerBase` that calls +`processGraphQLRequest` with the right request context (filing in the schema, +context, etc. with properties from the server instance). (edited) + */ + +const createClient = (server, ctxFn) => { + // if a context fn is required, overwrite the old one + // allows easy mocking of the context + if (ctxFn) server.context = ctxFn; + + return { + query: () => {}, + mutate: () => {}, + watchQuery: () => {}, + subscribe: () => {}, + }; +}; + +describe('createClient', () => { + const typeDefs = gql` + type Query { + hello: String + } + `; + + const resolvers = { + Query: { + hello: (_, vars, context) => { + return `${context.hello} + ${vars.hello}`; + }, + }, + // Mutation: { + // foo: (_, __, context) => '', + // }, + }; + + const myTestServer = new ApolloServerBase({ + typeDefs, + context: () => ({ hello: 'world' }), + resolvers, + }); + + const query = gql` + { + hello + } + `; + + it('allows querying', () => { + console.log(Object.keys(myTestServer)); + + // const client = createClient(myTestServer); + // expect(client.query({ query })).toEqual({ data: { hello: 'world' } }); + }); + + xit('allows mocking of context', () => { + const client = createClient(myTestServer, () => ({ hello: 'boo!' })); + expect(client.query({ query })).toEqual('boo!'); + }); +}); From 9f89ed0f51155b64a1f44dec82c6c0ee4e637ad9 Mon Sep 17 00:00:00 2001 From: Jake Date: Thu, 1 Nov 2018 17:56:48 -0400 Subject: [PATCH 02/14] add apollo-server-testing --- .../apollo-server-core/src/ApolloServer.ts | 37 +++++++++- .../src/__tests__/test-utils.test.ts | 68 ------------------ packages/apollo-server-testing/CHANGELOG.md | 5 ++ packages/apollo-server-testing/README.md | 7 ++ packages/apollo-server-testing/jest.config.js | 3 + packages/apollo-server-testing/package.json | 32 +++++++++ .../src/__tests__/createTestClient.test.ts | 70 +++++++++++++++++++ .../src/__tests__/tsconfig.json | 5 ++ .../src/createTestClient.ts | 26 +++++++ packages/apollo-server-testing/src/index.ts | 5 ++ packages/apollo-server-testing/tsconfig.json | 12 ++++ 11 files changed, 201 insertions(+), 69 deletions(-) delete mode 100644 packages/apollo-server-core/src/__tests__/test-utils.test.ts create mode 100644 packages/apollo-server-testing/CHANGELOG.md create mode 100644 packages/apollo-server-testing/README.md create mode 100644 packages/apollo-server-testing/jest.config.js create mode 100644 packages/apollo-server-testing/package.json create mode 100644 packages/apollo-server-testing/src/__tests__/createTestClient.test.ts create mode 100644 packages/apollo-server-testing/src/__tests__/tsconfig.json create mode 100644 packages/apollo-server-testing/src/createTestClient.ts create mode 100644 packages/apollo-server-testing/src/index.ts create mode 100644 packages/apollo-server-testing/tsconfig.json diff --git a/packages/apollo-server-core/src/ApolloServer.ts b/packages/apollo-server-core/src/ApolloServer.ts index 208cdf19353..a9f4f7853ab 100644 --- a/packages/apollo-server-core/src/ApolloServer.ts +++ b/packages/apollo-server-core/src/ApolloServer.ts @@ -24,6 +24,7 @@ import { formatApolloErrors } from 'apollo-server-errors'; import { GraphQLServerOptions as GraphQLOptions, PersistedQueryOptions, + resolveGraphqlOptions, } from './graphqlOptions'; import { @@ -45,6 +46,14 @@ import { } from './playground'; import { generateSchemaHash } from './utils/schemaHash'; +import { + processGraphQLRequest, + GraphQLRequestPipelineConfig, + GraphQLRequestContext, + GraphQLRequest, +} from './requestPipeline'; + +import { Headers } from "apollo-server-env"; const NoIntrospection = (context: ValidationContext) => ({ Field(node: FieldDefinitionNode) { @@ -503,5 +512,31 @@ export class ApolloServerBase { } as GraphQLOptions; } - // public async executeOperation() {} + public async executeOperation(request: GraphQLRequest, contextArgs) { + let options; + + try { + options = await this.graphQLServerOptions(contextArgs); + } catch (e) { + e.message = `Invalid options provided to ApolloServer: ${e.message}`; + throw new Error(e); + } + + if (typeof options.context === 'function') { + options.context = (options.context as () => never)(); + } + + const requestCtx: GraphQLRequestContext = { + request, + context: options.context || {} + cache: options.cache!, + response: { + http: { + headers: new Headers(), + }, + }, + }; + + return processGraphQLRequest(options, requestCtx); + } } diff --git a/packages/apollo-server-core/src/__tests__/test-utils.test.ts b/packages/apollo-server-core/src/__tests__/test-utils.test.ts deleted file mode 100644 index e2b713a8577..00000000000 --- a/packages/apollo-server-core/src/__tests__/test-utils.test.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { ApolloServerBase, gql } from '../'; -import { processGraphQLRequest, GraphQLRequest } from '../requestPipeline'; - -/** -@Jake @james yep, `processGraphQLRequest` is the entry point to the request -pipeline. with an incoming HTTP request this is invoked by `runHttpQuery`, but -for testing we'd want to call it directly. - -so we should add a method (`executeOperation`?) to `ApolloServerBase` that calls -`processGraphQLRequest` with the right request context (filing in the schema, -context, etc. with properties from the server instance). (edited) - */ - -const createClient = (server, ctxFn) => { - // if a context fn is required, overwrite the old one - // allows easy mocking of the context - if (ctxFn) server.context = ctxFn; - - return { - query: () => {}, - mutate: () => {}, - watchQuery: () => {}, - subscribe: () => {}, - }; -}; - -describe('createClient', () => { - const typeDefs = gql` - type Query { - hello: String - } - `; - - const resolvers = { - Query: { - hello: (_, vars, context) => { - return `${context.hello} + ${vars.hello}`; - }, - }, - // Mutation: { - // foo: (_, __, context) => '', - // }, - }; - - const myTestServer = new ApolloServerBase({ - typeDefs, - context: () => ({ hello: 'world' }), - resolvers, - }); - - const query = gql` - { - hello - } - `; - - it('allows querying', () => { - console.log(Object.keys(myTestServer)); - - // const client = createClient(myTestServer); - // expect(client.query({ query })).toEqual({ data: { hello: 'world' } }); - }); - - xit('allows mocking of context', () => { - const client = createClient(myTestServer, () => ({ hello: 'boo!' })); - expect(client.query({ query })).toEqual('boo!'); - }); -}); diff --git a/packages/apollo-server-testing/CHANGELOG.md b/packages/apollo-server-testing/CHANGELOG.md new file mode 100644 index 00000000000..a64c146b38f --- /dev/null +++ b/packages/apollo-server-testing/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +### vNEXT + +* `apollo-server-testing`: Added createTestClient function diff --git a/packages/apollo-server-testing/README.md b/packages/apollo-server-testing/README.md new file mode 100644 index 00000000000..a9ecec5d2b8 --- /dev/null +++ b/packages/apollo-server-testing/README.md @@ -0,0 +1,7 @@ +# apollo-server-testing + +[![npm version](https://badge.fury.io/js/apollo-server-testing.svg)](https://badge.fury.io/js/apollo-server-testing) +[![Build Status](https://circleci.com/gh/apollographql/apollo-server.svg?style=svg)](https://circleci.com/gh/apollographql/apollo-server) + +This is the testing module of the Apollo community GraphQL Server. [Read the docs.](https://www.apollographql.com/docs/apollo-server/) +[Read the CHANGELOG.](https://github.com/apollographql/apollo-server/blob/master/CHANGELOG.md) diff --git a/packages/apollo-server-testing/jest.config.js b/packages/apollo-server-testing/jest.config.js new file mode 100644 index 00000000000..a383fbc925f --- /dev/null +++ b/packages/apollo-server-testing/jest.config.js @@ -0,0 +1,3 @@ +const config = require('../../jest.config.base'); + +module.exports = Object.assign(Object.create(null), config); diff --git a/packages/apollo-server-testing/package.json b/packages/apollo-server-testing/package.json new file mode 100644 index 00000000000..7d93995a33f --- /dev/null +++ b/packages/apollo-server-testing/package.json @@ -0,0 +1,32 @@ +{ + "name": "apollo-server-testing", + "version": "2.2.0-alpha.0", + "description": "Test utils for apollo-server", + "main": "dist/index.js", + "types": "dist/index.d.ts", + "repository": { + "type": "git", + "url": "https://github.com/apollographql/apollo-server/tree/master/packages/apollo-server-testing" + }, + "keywords": [ + "GraphQL", + "Apollo", + "Server", + "Javascript" + ], + "author": "Jonas Helfer ", + "license": "MIT", + "bugs": { + "url": "https://github.com/apollographql/apollo-server/issues" + }, + "homepage": "https://github.com/apollographql/apollo-server#readme", + "engines": { + "node": ">=6" + }, + "dependencies": { + "apollo-server-core": "file:../apollo-server-core" + }, + "peerDependencies": { + "graphql": "^0.12.0 || ^0.13.0 || ^14.0.0" + } +} diff --git a/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts b/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts new file mode 100644 index 00000000000..86ab6d60ebe --- /dev/null +++ b/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts @@ -0,0 +1,70 @@ +const { ApolloServerBase, gql } = require('apollo-server-core'); +const createTestClient = require('../createTestClient'); + +describe('createTestClient', () => { + const typeDefs = gql` + type Query { + test(echo: String): String + # this resolver uses context + hello: String + } + + type Mutation { + increment: Int! + } + `; + + let num = 0; + const resolvers = { + Query: { + test: (_, { echo }) => echo, + hello: (_, __, { person }) => { + return `hello ${person}`; + }, + }, + Mutation: { + increment: () => ++num, + }, + }; + + const myTestServer = new ApolloServerBase({ + typeDefs, + context: () => ({ person: 'tom' }), + resolvers, + }); + + it('allows queries', async () => { + const query = `{ test(echo: "foo") }`; + const client = createTestClient(myTestServer); + const res = await client.query({ query }); + expect(res.data).toEqual({ test: 'foo' }); + }); + + it('allows mutations', async () => { + const mutation = `mutation increment { increment }`; + const client = createTestClient(myTestServer); + const res = await client.mutate({ mutation }); + expect(res.data).toEqual({ increment: 1 }); + }); + + it('allows variables to be passed', async () => { + const query = `query test($echo: String){ test(echo: $echo) }`; + const client = createTestClient(myTestServer); + const res = await client.query({ query, variables: { echo: 'wow' } }); + expect(res.data).toEqual({ test: 'wow' }); + }); + + it('uses default context function if not overwritten', async () => { + const query = `{ hello }`; + const client = createTestClient(myTestServer); + const res = await client.query({ query }); + expect(res.data).toEqual({ hello: 'hello tom' }); + }); + + it('allows mocking of context', async () => { + const query = `{ hello }`; + const client = createTestClient(myTestServer, () => ({ person: 'mary' })); + const res = await client.query({ query }); + expect(res.data).toEqual({ hello: 'hello mary' }); + }); +}); diff --git a/packages/apollo-server-testing/src/__tests__/tsconfig.json b/packages/apollo-server-testing/src/__tests__/tsconfig.json new file mode 100644 index 00000000000..2f3a365cbfc --- /dev/null +++ b/packages/apollo-server-testing/src/__tests__/tsconfig.json @@ -0,0 +1,5 @@ +{ + "extends": "../../../../tsconfig.test.base", + "include": ["**/*"], + "references": [] +} diff --git a/packages/apollo-server-testing/src/createTestClient.ts b/packages/apollo-server-testing/src/createTestClient.ts new file mode 100644 index 00000000000..bde90615535 --- /dev/null +++ b/packages/apollo-server-testing/src/createTestClient.ts @@ -0,0 +1,26 @@ +import { ApolloServerBase, gql } from 'apollo-server-core'; +import { print } from 'graphql'; + +const createTestClient = (server: ApolloServerBase, ctxFn: any) => { + // if a context fn is required, overwrite the old one + // allows easy mocking of the context + if (ctxFn) server.context = ctxFn; + + const executeOperation = server.executeOperation.bind(server); + return { + query: ({ query, ...rest }) => + executeOperation({ + // print the query document if it isn't a string + query: typeof query === 'string' ? query : print(query), + ...rest, + }), + mutate: ({ mutation, ...rest }) => + executeOperation({ + // print the query document if it isn't a string + query: typeof mutation === 'string' ? mutation : print(mutation), + ...rest, + }), + }; +}; + +module.exports = createTestClient; diff --git a/packages/apollo-server-testing/src/index.ts b/packages/apollo-server-testing/src/index.ts new file mode 100644 index 00000000000..e1e5c50cc75 --- /dev/null +++ b/packages/apollo-server-testing/src/index.ts @@ -0,0 +1,5 @@ +const createTestClient = require('./createTestClient'); + +module.exports = { + createTestClient, +}; diff --git a/packages/apollo-server-testing/tsconfig.json b/packages/apollo-server-testing/tsconfig.json new file mode 100644 index 00000000000..dcf69da0397 --- /dev/null +++ b/packages/apollo-server-testing/tsconfig.json @@ -0,0 +1,12 @@ +{ + "extends": "../../tsconfig.base", + "compilerOptions": { + "rootDir": "./src", + "outDir": "./dist" + }, + "include": ["src/**/*"], + "exclude": ["**/__tests__", "**/__mocks__"], + "references": [ + { "path": "../apollo-server-core" } + ] +} From c912d7388b815f7433807010482b9a961bcb7e69 Mon Sep 17 00:00:00 2001 From: Jake Date: Thu, 1 Nov 2018 18:02:40 -0400 Subject: [PATCH 03/14] fix typo --- packages/apollo-server-core/src/ApolloServer.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/apollo-server-core/src/ApolloServer.ts b/packages/apollo-server-core/src/ApolloServer.ts index a9f4f7853ab..7b5c255a19b 100644 --- a/packages/apollo-server-core/src/ApolloServer.ts +++ b/packages/apollo-server-core/src/ApolloServer.ts @@ -53,7 +53,7 @@ import { GraphQLRequest, } from './requestPipeline'; -import { Headers } from "apollo-server-env"; +import { Headers } from 'apollo-server-env'; const NoIntrospection = (context: ValidationContext) => ({ Field(node: FieldDefinitionNode) { @@ -528,7 +528,7 @@ export class ApolloServerBase { const requestCtx: GraphQLRequestContext = { request, - context: options.context || {} + context: options.context || {}, cache: options.cache!, response: { http: { From 80670c8a9d0ed86b55e51b062507ff9b3adfbaaf Mon Sep 17 00:00:00 2001 From: Jake Date: Thu, 1 Nov 2018 18:06:35 -0400 Subject: [PATCH 04/14] fixed type errors --- packages/apollo-server-core/src/ApolloServer.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/apollo-server-core/src/ApolloServer.ts b/packages/apollo-server-core/src/ApolloServer.ts index 7b5c255a19b..97f4927712d 100644 --- a/packages/apollo-server-core/src/ApolloServer.ts +++ b/packages/apollo-server-core/src/ApolloServer.ts @@ -24,7 +24,6 @@ import { formatApolloErrors } from 'apollo-server-errors'; import { GraphQLServerOptions as GraphQLOptions, PersistedQueryOptions, - resolveGraphqlOptions, } from './graphqlOptions'; import { @@ -48,7 +47,6 @@ import { import { generateSchemaHash } from './utils/schemaHash'; import { processGraphQLRequest, - GraphQLRequestPipelineConfig, GraphQLRequestContext, GraphQLRequest, } from './requestPipeline'; @@ -512,7 +510,10 @@ export class ApolloServerBase { } as GraphQLOptions; } - public async executeOperation(request: GraphQLRequest, contextArgs) { + public async executeOperation( + request: GraphQLRequest, + contextArgs: Record, + ) { let options; try { From c44fff4686c4aae4832951e5686694492fdcff70 Mon Sep 17 00:00:00 2001 From: Jake Date: Thu, 1 Nov 2018 18:10:16 -0400 Subject: [PATCH 05/14] tested query documents --- .../src/__tests__/createTestClient.test.ts | 22 +++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts b/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts index 86ab6d60ebe..c62c2fd52cc 100644 --- a/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts +++ b/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts @@ -14,7 +14,6 @@ describe('createTestClient', () => { } `; - let num = 0; const resolvers = { Query: { test: (_, { echo }) => echo, @@ -23,7 +22,7 @@ describe('createTestClient', () => { }, }, Mutation: { - increment: () => ++num, + increment: () => 1, }, }; @@ -67,4 +66,23 @@ describe('createTestClient', () => { const res = await client.query({ query }); expect(res.data).toEqual({ hello: 'hello mary' }); }); + + it('allows query documents as input', async () => { + const query = gql` + { + test(echo: "foo") + } + `; + const client = createTestClient(myTestServer); + const clientRes = await client.query({ query }); + expect(clientRes.data).toEqual({ test: 'foo' }); + + const mutation = gql` + mutation increment { + increment + } + `; + const mutationRes = await client.mutate({ mutation }); + expect(mutationRes.data).toEqual({ increment: 1 }); + }); }); From fa59212209fde749e7d7bfda88ea0081b7f42ff4 Mon Sep 17 00:00:00 2001 From: Jesse Rosenberger Date: Fri, 2 Nov 2018 13:56:46 -0400 Subject: [PATCH 06/14] Update packages/apollo-server-testing/src/createTestClient.ts Co-Authored-By: JakeDawkins --- packages/apollo-server-testing/src/createTestClient.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/apollo-server-testing/src/createTestClient.ts b/packages/apollo-server-testing/src/createTestClient.ts index bde90615535..137625d3e44 100644 --- a/packages/apollo-server-testing/src/createTestClient.ts +++ b/packages/apollo-server-testing/src/createTestClient.ts @@ -10,7 +10,8 @@ const createTestClient = (server: ApolloServerBase, ctxFn: any) => { return { query: ({ query, ...rest }) => executeOperation({ - // print the query document if it isn't a string + // Convert ASTs, which are produced by `graphql-tag` to + // a string using `graphql/language/print`. query: typeof query === 'string' ? query : print(query), ...rest, }), From 3f28757d038d55160b76d4d44c525ae240e18711 Mon Sep 17 00:00:00 2001 From: Jesse Rosenberger Date: Fri, 2 Nov 2018 13:57:57 -0400 Subject: [PATCH 07/14] Update packages/apollo-server-testing/src/createTestClient.ts Co-Authored-By: JakeDawkins --- packages/apollo-server-testing/src/createTestClient.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/apollo-server-testing/src/createTestClient.ts b/packages/apollo-server-testing/src/createTestClient.ts index 137625d3e44..fd59851c139 100644 --- a/packages/apollo-server-testing/src/createTestClient.ts +++ b/packages/apollo-server-testing/src/createTestClient.ts @@ -1,7 +1,7 @@ import { ApolloServerBase, gql } from 'apollo-server-core'; import { print } from 'graphql'; -const createTestClient = (server: ApolloServerBase, ctxFn: any) => { +const createTestClient = (server: ApolloServerBase, ctxFn: (...args: any[]) => any) => { // if a context fn is required, overwrite the old one // allows easy mocking of the context if (ctxFn) server.context = ctxFn; From 25fa50931c7d6156c772c311713a8fdc3f212afb Mon Sep 17 00:00:00 2001 From: Jake Date: Fri, 2 Nov 2018 14:23:01 -0400 Subject: [PATCH 08/14] review --- package-lock.json | 8 ++++++ package.json | 1 + .../apollo-server-core/src/ApolloServer.ts | 2 +- .../src/__tests__/createTestClient.test.ts | 4 +-- .../src/createTestClient.ts | 28 ++++++++----------- packages/apollo-server-testing/src/index.ts | 6 +--- tsconfig.build.json | 1 + 7 files changed, 25 insertions(+), 25 deletions(-) diff --git a/package-lock.json b/package-lock.json index 3824758556f..20675602a66 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6403,6 +6403,14 @@ "dev": true, "requires": { "hoek": "5.x.x" + }, + "dependencies": { + "hoek": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/hoek/-/hoek-5.0.4.tgz", + "integrity": "sha512-Alr4ZQgoMlnere5FZJsIyfIjORBqZll5POhDsF4q64dPuJR6rNxXdDxtHSQq8OXRurhmx+PWYEE8bXRROY8h0w==", + "dev": true + } } }, "wreck": { diff --git a/package.json b/package.json index 234b0003372..925eaf908ad 100644 --- a/package.json +++ b/package.json @@ -54,6 +54,7 @@ "apollo-server-lambda": "file:packages/apollo-server-lambda", "apollo-server-micro": "file:packages/apollo-server-micro", "apollo-server-plugin-base": "file:packages/apollo-server-plugin-base", + "apollo-server-testing": "file:packages/apollo-server-testing", "apollo-tracing": "file:packages/apollo-tracing", "graphql-extensions": "file:packages/graphql-extensions" }, diff --git a/packages/apollo-server-core/src/ApolloServer.ts b/packages/apollo-server-core/src/ApolloServer.ts index 97f4927712d..7be54d921fe 100644 --- a/packages/apollo-server-core/src/ApolloServer.ts +++ b/packages/apollo-server-core/src/ApolloServer.ts @@ -529,7 +529,7 @@ export class ApolloServerBase { const requestCtx: GraphQLRequestContext = { request, - context: options.context || {}, + context: options.context || Object.create(null), cache: options.cache!, response: { http: { diff --git a/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts b/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts index c62c2fd52cc..dd43ce24f6b 100644 --- a/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts +++ b/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts @@ -1,5 +1,5 @@ -const { ApolloServerBase, gql } = require('apollo-server-core'); -const createTestClient = require('../createTestClient'); +import { ApolloServerBase, gql } from 'apollo-server-core'; +import createTestClient from '../createTestClient'; describe('createTestClient', () => { const typeDefs = gql` diff --git a/packages/apollo-server-testing/src/createTestClient.ts b/packages/apollo-server-testing/src/createTestClient.ts index fd59851c139..701482e09be 100644 --- a/packages/apollo-server-testing/src/createTestClient.ts +++ b/packages/apollo-server-testing/src/createTestClient.ts @@ -1,27 +1,21 @@ import { ApolloServerBase, gql } from 'apollo-server-core'; import { print } from 'graphql'; -const createTestClient = (server: ApolloServerBase, ctxFn: (...args: any[]) => any) => { +export default (server: ApolloServerBase, ctxFn: (...args: any[]) => any) => { // if a context fn is required, overwrite the old one // allows easy mocking of the context if (ctxFn) server.context = ctxFn; const executeOperation = server.executeOperation.bind(server); - return { - query: ({ query, ...rest }) => - executeOperation({ - // Convert ASTs, which are produced by `graphql-tag` to - // a string using `graphql/language/print`. - query: typeof query === 'string' ? query : print(query), - ...rest, - }), - mutate: ({ mutation, ...rest }) => - executeOperation({ - // print the query document if it isn't a string - query: typeof mutation === 'string' ? mutation : print(mutation), - ...rest, - }), + const test = ({ query, mutation, ...rest }) => { + const operation = query || mutation; + return executeOperation({ + // Convert ASTs, which are produced by `graphql-tag` but not currently + // used by `executeOperation`, to a String using `graphql/language/print`. + query: typeof operation === 'string' ? operation : print(operation), + ...rest, + }); }; -}; -module.exports = createTestClient; + return { query: test, mutate: test }; +}; diff --git a/packages/apollo-server-testing/src/index.ts b/packages/apollo-server-testing/src/index.ts index e1e5c50cc75..acd8c5f2b2b 100644 --- a/packages/apollo-server-testing/src/index.ts +++ b/packages/apollo-server-testing/src/index.ts @@ -1,5 +1 @@ -const createTestClient = require('./createTestClient'); - -module.exports = { - createTestClient, -}; +export { default as createTestClient } from './createTestClient'; diff --git a/tsconfig.build.json b/tsconfig.build.json index 09db1dd58d5..39809dba39e 100644 --- a/tsconfig.build.json +++ b/tsconfig.build.json @@ -22,6 +22,7 @@ { "path": "./packages/apollo-server-lambda" }, { "path": "./packages/apollo-server-micro" }, { "path": "./packages/apollo-server-plugin-base" }, + { "path": "./packages/apollo-server-testing" }, { "path": "./packages/apollo-tracing" }, { "path": "./packages/graphql-extensions" }, ] From ce5286977137b5560fc50248b0a3e05fdf6ef869 Mon Sep 17 00:00:00 2001 From: Jake Date: Sun, 4 Nov 2018 11:03:43 -0500 Subject: [PATCH 09/14] revert package-lock changes --- package-lock.json | 685 ++++++++---------- .../src/createTestClient.ts | 2 +- 2 files changed, 321 insertions(+), 366 deletions(-) diff --git a/package-lock.json b/package-lock.json index 20675602a66..7b2a445543b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1470,9 +1470,9 @@ } }, "@types/node": { - "version": "10.12.2", - "resolved": "https://registry.npmjs.org/@types/node/-/node-10.12.2.tgz", - "integrity": "sha512-53ElVDSnZeFUUFIYzI8WLQ25IhWzb6vbddNp8UHlXQyU0ET2RhV5zg0NfubzU7iNMh5bBXb0htCzfvrSVNgzaQ==" + "version": "10.12.1", + "resolved": "https://registry.npmjs.org/@types/node/-/node-10.12.1.tgz", + "integrity": "sha512-i1sl+WCX2OCHeUi9oi7PiCNUtYFrpWhpcx878vpeq/tlZTKzcFdHePlyFHVbWqeuKN0SRPl/9ZFDSTsfv9h7VQ==" }, "@types/node-fetch": { "version": "2.1.2", @@ -1676,6 +1676,15 @@ "json-schema-traverse": "^0.3.0" } }, + "ammo": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/ammo/-/ammo-3.0.1.tgz", + "integrity": "sha512-4UqoM8xQjwkQ78oiU4NbBK0UgYqeKMAKmwE4ec7Rz3rGU8ZEBFxzgF2sUYKOAlqIXExBDYLN6y1ShF5yQ4hwLQ==", + "dev": true, + "requires": { + "hoek": "5.x.x" + } + }, "ansi-escapes": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.1.0.tgz", @@ -2519,6 +2528,12 @@ "integrity": "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==", "dev": true }, + "b64": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/b64/-/b64-4.0.0.tgz", + "integrity": "sha512-EhmUQodKB0sdzPPrbIWbGqA5cQeTWxYrAgNeeT1rLZWtD3tbNTnphz8J4vkXI3cPgBNlXBjzEbzDzq0Nwi4f9A==", + "dev": true + }, "babel-code-frame": { "version": "6.26.0", "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz", @@ -2893,6 +2908,12 @@ "tweetnacl": "^0.14.3" } }, + "big-time": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/big-time/-/big-time-2.0.1.tgz", + "integrity": "sha1-aMffjcMPl+lT8lpnp2rJcTwWyd4=", + "dev": true + }, "block-stream": { "version": "0.0.9", "resolved": "https://registry.npmjs.org/block-stream/-/block-stream-0.0.9.tgz", @@ -2933,6 +2954,16 @@ "hoek": "5.x.x" } }, + "bounce": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/bounce/-/bounce-1.2.0.tgz", + "integrity": "sha512-8syCGe8B2/WC53118/F/tFy5aW00j+eaGPXmAUP7iBhxc+EBZZxS1vKelWyBCH6IqojgS2t1gF0glH30qAJKEw==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "5.x.x" + } + }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -3095,6 +3126,16 @@ "ylru": "^1.2.0" } }, + "call": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/call/-/call-5.0.1.tgz", + "integrity": "sha512-ollfFPSshiuYLp7AsrmpkQJ/PxCi6AzV81rCjBwWhyF2QGyUY/vPDMzoh4aUcWyucheRglG2LaS5qkIEfLRh6A==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "5.x.x" + } + }, "call-me-maybe": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/call-me-maybe/-/call-me-maybe-1.0.1.tgz", @@ -3139,6 +3180,28 @@ "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", "dev": true }, + "catbox": { + "version": "10.0.3", + "resolved": "https://registry.npmjs.org/catbox/-/catbox-10.0.3.tgz", + "integrity": "sha512-qwus6RnVctHXYwfxvvDwvlMWHwCjQdIpQQbtyHnRF0JpwmxbQJ/UIZi9y8O6DpphKCdfO9gpxgb2ne9ZDx39BQ==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "5.x.x", + "joi": "13.x.x" + } + }, + "catbox-memory": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/catbox-memory/-/catbox-memory-3.1.2.tgz", + "integrity": "sha512-lhWtutLVhsq3Mucxk2McxBPPibJ34WcHuWFz3xqub9u9Ve/IQYpZv3ijLhQXfQped9DXozURiaq9O3aZpP91eg==", + "dev": true, + "requires": { + "big-time": "2.x.x", + "boom": "7.x.x", + "hoek": "5.x.x" + } + }, "chalk": { "version": "2.4.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.0.tgz", @@ -3533,6 +3596,15 @@ "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=", "dev": true }, + "content": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/content/-/content-4.0.5.tgz", + "integrity": "sha512-wDP6CTWDpwCf791fNxlCCkZGRkrNzSEU/8ju9Hnr3Uc5mF/gFR5W+fcoGm6zUSlVPdSXYn5pCbySADKj7YM4Cg==", + "dev": true, + "requires": { + "boom": "7.x.x" + } + }, "content-disposition": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.2.tgz", @@ -3769,6 +3841,15 @@ "which": "^1.2.9" } }, + "cryptiles": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-4.1.2.tgz", + "integrity": "sha512-U2ALcoAHvA1oO2xOreyHvtkQ+IELqDG2WVWRI1GH/XEmmfGIOalnM5MU5Dd2ITyWfr3m6kNqXiy8XuYyd4wKJw==", + "dev": true, + "requires": { + "boom": "7.x.x" + } + }, "cssom": { "version": "0.3.4", "resolved": "https://registry.npmjs.org/cssom/-/cssom-0.3.4.tgz", @@ -4134,7 +4215,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -4962,7 +5043,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -5067,7 +5148,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -5142,27 +5223,27 @@ "dependencies": { "abbrev": { "version": "1.1.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", "dev": true, "optional": true }, "ansi-regex": { "version": "2.1.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", "dev": true }, "aproba": { "version": "1.2.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", "dev": true, "optional": true }, "are-we-there-yet": { "version": "1.1.4", - "resolved": false, + "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.4.tgz", "integrity": "sha1-u13KOCu5TwXhUZQ3PRb9O6HKEQ0=", "dev": true, "optional": true, @@ -5173,13 +5254,13 @@ }, "balanced-match": { "version": "1.0.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=", "dev": true }, "brace-expansion": { "version": "1.1.11", - "resolved": false, + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", "dev": true, "requires": { @@ -5189,39 +5270,39 @@ }, "chownr": { "version": "1.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.0.1.tgz", "integrity": "sha1-4qdQQqlVGQi+vSW4Uj1fl2nXkYE=", "dev": true, "optional": true }, "code-point-at": { "version": "1.1.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", "dev": true }, "concat-map": { "version": "0.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", "dev": true }, "console-control-strings": { "version": "1.1.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=", "dev": true }, "core-util-is": { "version": "1.0.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=", "dev": true, "optional": true }, "debug": { "version": "2.6.9", - "resolved": false, + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "dev": true, "optional": true, @@ -5231,28 +5312,28 @@ }, "deep-extend": { "version": "0.5.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.5.1.tgz", "integrity": "sha512-N8vBdOa+DF7zkRrDCsaOXoCs/E2fJfx9B9MrKnnSiHNh4ws7eSys6YQE4KvT1cecKmOASYQBhbKjeuDD9lT81w==", "dev": true, "optional": true }, "delegates": { "version": "1.0.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=", "dev": true, "optional": true }, "detect-libc": { "version": "1.0.3", - "resolved": false, + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-1.0.3.tgz", "integrity": "sha1-+hN8S9aY7fVc1c0CrFWfkaTEups=", "dev": true, "optional": true }, "fs-minipass": { "version": "1.2.5", - "resolved": false, + "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-1.2.5.tgz", "integrity": "sha512-JhBl0skXjUPCFH7x6x61gQxrKyXsxB5gcgePLZCwfyCGGsTISMoIeObbrvVeP6Xmyaudw4TT43qV2Gz+iyd2oQ==", "dev": true, "optional": true, @@ -5262,14 +5343,14 @@ }, "fs.realpath": { "version": "1.0.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", "dev": true, "optional": true }, "gauge": { "version": "2.7.4", - "resolved": false, + "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", "dev": true, "optional": true, @@ -5286,7 +5367,7 @@ }, "glob": { "version": "7.1.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", "dev": true, "optional": true, @@ -5301,14 +5382,14 @@ }, "has-unicode": { "version": "2.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=", "dev": true, "optional": true }, "iconv-lite": { "version": "0.4.21", - "resolved": false, + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.21.tgz", "integrity": "sha512-En5V9za5mBt2oUA03WGD3TwDv0MKAruqsuxstbMUZaj9W9k/m1CV/9py3l0L5kw9Bln8fdHQmzHSYtvpvTLpKw==", "dev": true, "optional": true, @@ -5318,7 +5399,7 @@ }, "ignore-walk": { "version": "3.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/ignore-walk/-/ignore-walk-3.0.1.tgz", "integrity": "sha512-DTVlMx3IYPe0/JJcYP7Gxg7ttZZu3IInhuEhbchuqneY9wWe5Ojy2mXLBaQFUQmo0AW2r3qG7m1mg86js+gnlQ==", "dev": true, "optional": true, @@ -5328,7 +5409,7 @@ }, "inflight": { "version": "1.0.6", - "resolved": false, + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", "dev": true, "optional": true, @@ -5339,20 +5420,20 @@ }, "inherits": { "version": "2.0.3", - "resolved": false, + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=", "dev": true }, "ini": { "version": "1.3.5", - "resolved": false, + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==", "dev": true, "optional": true }, "is-fullwidth-code-point": { "version": "1.0.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", "dev": true, "requires": { @@ -5361,14 +5442,14 @@ }, "isarray": { "version": "1.0.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", "dev": true, "optional": true }, "minimatch": { "version": "3.0.4", - "resolved": false, + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", "dev": true, "requires": { @@ -5377,13 +5458,13 @@ }, "minimist": { "version": "0.0.8", - "resolved": false, + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=", "dev": true }, "minipass": { "version": "2.2.4", - "resolved": false, + "resolved": "https://registry.npmjs.org/minipass/-/minipass-2.2.4.tgz", "integrity": "sha512-hzXIWWet/BzWhYs2b+u7dRHlruXhwdgvlTMDKC6Cb1U7ps6Ac6yQlR39xsbjWJE377YTCtKwIXIpJ5oP+j5y8g==", "dev": true, "requires": { @@ -5393,7 +5474,7 @@ }, "minizlib": { "version": "1.1.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-1.1.0.tgz", "integrity": "sha512-4T6Ur/GctZ27nHfpt9THOdRZNgyJ9FZchYO1ceg5S8Q3DNLCKYy44nCZzgCJgcvx2UM8czmqak5BCxJMrq37lA==", "dev": true, "optional": true, @@ -5403,7 +5484,7 @@ }, "mkdirp": { "version": "0.5.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", "dev": true, "requires": { @@ -5412,14 +5493,14 @@ }, "ms": { "version": "2.0.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", "dev": true, "optional": true }, "needle": { "version": "2.2.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/needle/-/needle-2.2.0.tgz", "integrity": "sha512-eFagy6c+TYayorXw/qtAdSvaUpEbBsDwDyxYFgLZ0lTojfH7K+OdBqAF7TAFwDokJaGpubpSGG0wO3iC0XPi8w==", "dev": true, "optional": true, @@ -5431,7 +5512,7 @@ }, "node-pre-gyp": { "version": "0.10.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/node-pre-gyp/-/node-pre-gyp-0.10.0.tgz", "integrity": "sha512-G7kEonQLRbcA/mOoFoxvlMrw6Q6dPf92+t/l0DFSMuSlDoWaI9JWIyPwK0jyE1bph//CUEL65/Fz1m2vJbmjQQ==", "dev": true, "optional": true, @@ -5450,7 +5531,7 @@ }, "nopt": { "version": "4.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/nopt/-/nopt-4.0.1.tgz", "integrity": "sha1-0NRoWv1UFRk8jHUFYC0NF81kR00=", "dev": true, "optional": true, @@ -5461,14 +5542,14 @@ }, "npm-bundled": { "version": "1.0.3", - "resolved": false, + "resolved": "https://registry.npmjs.org/npm-bundled/-/npm-bundled-1.0.3.tgz", "integrity": "sha512-ByQ3oJ/5ETLyglU2+8dBObvhfWXX8dtPZDMePCahptliFX2iIuhyEszyFk401PZUNQH20vvdW5MLjJxkwU80Ow==", "dev": true, "optional": true }, "npm-packlist": { "version": "1.1.10", - "resolved": false, + "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-1.1.10.tgz", "integrity": "sha512-AQC0Dyhzn4EiYEfIUjCdMl0JJ61I2ER9ukf/sLxJUcZHfo+VyEfz2rMJgLZSS1v30OxPQe1cN0LZA1xbcaVfWA==", "dev": true, "optional": true, @@ -5479,7 +5560,7 @@ }, "npmlog": { "version": "4.1.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz", "integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==", "dev": true, "optional": true, @@ -5492,20 +5573,20 @@ }, "number-is-nan": { "version": "1.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", "dev": true }, "object-assign": { "version": "4.1.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", "dev": true, "optional": true }, "once": { "version": "1.4.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", "dev": true, "requires": { @@ -5514,21 +5595,21 @@ }, "os-homedir": { "version": "1.0.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", "dev": true, "optional": true }, "os-tmpdir": { "version": "1.0.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true, "optional": true }, "osenv": { "version": "0.1.5", - "resolved": false, + "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz", "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==", "dev": true, "optional": true, @@ -5539,21 +5620,21 @@ }, "path-is-absolute": { "version": "1.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true, "optional": true }, "process-nextick-args": { "version": "2.0.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.0.tgz", "integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==", "dev": true, "optional": true }, "rc": { "version": "1.2.7", - "resolved": false, + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.7.tgz", "integrity": "sha512-LdLD8xD4zzLsAT5xyushXDNscEjB7+2ulnl8+r1pnESlYtlJtVSoCMBGr30eDRJ3+2Gq89jK9P9e4tCEH1+ywA==", "dev": true, "optional": true, @@ -5566,7 +5647,7 @@ "dependencies": { "minimist": { "version": "1.2.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true, "optional": true @@ -5575,7 +5656,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": false, + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "optional": true, @@ -5591,7 +5672,7 @@ }, "rimraf": { "version": "2.6.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.2.tgz", "integrity": "sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w==", "dev": true, "optional": true, @@ -5601,48 +5682,48 @@ }, "safe-buffer": { "version": "5.1.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.1.tgz", "integrity": "sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg==", "dev": true }, "safer-buffer": { "version": "2.1.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", "dev": true, "optional": true }, "sax": { "version": "1.2.4", - "resolved": false, + "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==", "dev": true, "optional": true }, "semver": { "version": "5.5.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/semver/-/semver-5.5.0.tgz", "integrity": "sha512-4SJ3dm0WAwWy/NVeioZh5AntkdJoWKxHxcmyP622fOkgHa4z3R0TdBJICINyaSDE6uNwVc8gZr+ZinwZAH4xIA==", "dev": true, "optional": true }, "set-blocking": { "version": "2.0.0", - "resolved": false, + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true, "optional": true }, "signal-exit": { "version": "3.0.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", "dev": true, "optional": true }, "string-width": { "version": "1.0.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", "dev": true, "requires": { @@ -5653,7 +5734,7 @@ }, "string_decoder": { "version": "1.1.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "dev": true, "optional": true, @@ -5663,7 +5744,7 @@ }, "strip-ansi": { "version": "3.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "dev": true, "requires": { @@ -5672,14 +5753,14 @@ }, "strip-json-comments": { "version": "2.0.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", "dev": true, "optional": true }, "tar": { "version": "4.4.1", - "resolved": false, + "resolved": "https://registry.npmjs.org/tar/-/tar-4.4.1.tgz", "integrity": "sha512-O+v1r9yN4tOsvl90p5HAP4AEqbYhx4036AGMm075fH9F8Qwi3oJ+v4u50FkT/KkvywNGtwkk0zRI+8eYm1X/xg==", "dev": true, "optional": true, @@ -5695,14 +5776,14 @@ }, "util-deprecate": { "version": "1.0.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", "dev": true, "optional": true }, "wide-align": { "version": "1.1.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.2.tgz", "integrity": "sha512-ijDLlyQ7s6x1JgCLur53osjm/UXUYD9+0PbYKrBsYisYXzCxN+HC3mYDNy/dWdmf3AwqwU3CXwDCvsNgGK1S0w==", "dev": true, "optional": true, @@ -5712,13 +5793,13 @@ }, "wrappy": { "version": "1.0.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true }, "yallist": { "version": "3.0.2", - "resolved": false, + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.0.2.tgz", "integrity": "sha1-hFK0u36Dx8GI2AQcGoN8dz1ti7k=", "dev": true } @@ -6128,9 +6209,9 @@ } }, "hapi": { - "version": "17.6.2", - "resolved": "https://registry.npmjs.org/hapi/-/hapi-17.6.2.tgz", - "integrity": "sha512-vvOfssoAmRVczKMVC0lyGtpB0bvgdHVnzRrMGe5A9jy0JVnj24Kplt+mFIOVHmPt7zsZgUiqpGzF1R4grOh/Yg==", + "version": "17.6.0", + "resolved": "https://registry.npmjs.org/hapi/-/hapi-17.6.0.tgz", + "integrity": "sha512-GSHjE1hJExluAukrT/QuYSk96irmbYBDd3wOgywiHsPoR2QeKgDnIttD+dB6NbADEmSdb9MS5gTUIVq0uHTdkA==", "dev": true, "requires": { "accept": "3.x.x", @@ -6141,8 +6222,8 @@ "catbox": "10.x.x", "catbox-memory": "3.x.x", "heavy": "6.x.x", - "hoek": "6.x.x", - "joi": "14.x.x", + "hoek": "5.x.x", + "joi": "13.x.x", "mimos": "4.x.x", "podium": "3.x.x", "shot": "4.x.x", @@ -6150,279 +6231,6 @@ "subtext": "6.x.x", "teamwork": "3.x.x", "topo": "3.x.x" - }, - "dependencies": { - "accept": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/accept/-/accept-3.1.2.tgz", - "integrity": "sha512-oOWpPqk7QP+ZSwgmsxwvPTZprzGlJc0fy9N0rpHRf320F5mmnPohOoTUwhoC4BpZBghOQ6hCnlI9Ew20L0yerg==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "6.x.x" - } - }, - "ammo": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/ammo/-/ammo-3.0.2.tgz", - "integrity": "sha512-wn3lgiJkshPcNcn+8SKqBtEeTE2ktMCpqkQzJPDEl33pD2h/2AEjcQkZfzFlMctMDPoGMY8GHW53jH0TBzwDmA==", - "dev": true, - "requires": { - "hoek": "6.x.x" - } - }, - "b64": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/b64/-/b64-4.1.1.tgz", - "integrity": "sha512-l89U3YQnHDoRavvYvA8duXHSDvmD9q4j0nscasRXuDo7ChCfX0sR7X8jLrqbr9kvnxOG5RtR+ZvYpxInvGcevA==", - "dev": true, - "requires": { - "hoek": "6.x.x" - } - }, - "big-time": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/big-time/-/big-time-2.0.1.tgz", - "integrity": "sha512-qtwYYoocwpiAxTXC5sIpB6nH5j6ckt+n/jhD7J5OEiFHnUZEFn0Xk8STUaE5s10LdazN/87bTDMe+fSihaW7Kg==", - "dev": true - }, - "boom": { - "version": "7.2.1", - "resolved": "https://registry.npmjs.org/boom/-/boom-7.2.1.tgz", - "integrity": "sha512-vZh9c/HzXdlRV/AT95GKem0lglza3IlEnD4bvQxmMxDpF6c06uchRX7/f5Fhx9R+aCWHZpHsHvrSHKPlN4GwRA==", - "dev": true, - "requires": { - "hoek": "6.x.x" - } - }, - "bounce": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/bounce/-/bounce-1.2.1.tgz", - "integrity": "sha512-6I1aXdh1yJAj45ga361mNf/yIDHfHyeOxlL/yA/9ri2b59GN7IQmkbZphzgwFoRpTzRp9LuVpO9QSLiVRqGZaw==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "6.x.x" - } - }, - "call": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/call/-/call-5.0.2.tgz", - "integrity": "sha512-GNgWuC6j4FKBziAczCQo/In5Nh6TKS6QoMvvE6qF8xTiEEV4azq4s5K2CmutE2VNNU7PQ47oPqp7J7F3c6/uxQ==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "6.x.x" - } - }, - "catbox": { - "version": "10.0.4", - "resolved": "https://registry.npmjs.org/catbox/-/catbox-10.0.4.tgz", - "integrity": "sha512-mSGF/OfDFjiCIfDvCZeQzhHHlGO1SCI0AL8AWBn9g9gYs8QiP8rWiQz6ymPq+4E6uVYQqDXk83aJ51NzVLQ/TA==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "6.x.x", - "joi": "14.x.x" - } - }, - "catbox-memory": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/catbox-memory/-/catbox-memory-3.1.3.tgz", - "integrity": "sha512-++WfmXZVe7g8GE6w0CrvJwJprSEWZ30cMjuaxfWyiFJmHoRYgoHSPzm4WEJt+kTDF8Jofkn8Yk+PU6qdnOyqrQ==", - "dev": true, - "requires": { - "big-time": "2.x.x", - "boom": "7.x.x", - "hoek": "6.x.x" - } - }, - "content": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/content/-/content-4.0.5.tgz", - "integrity": "sha512-wDP6CTWDpwCf791fNxlCCkZGRkrNzSEU/8ju9Hnr3Uc5mF/gFR5W+fcoGm6zUSlVPdSXYn5pCbySADKj7YM4Cg==", - "dev": true, - "requires": { - "boom": "7.x.x" - } - }, - "cryptiles": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-4.1.2.tgz", - "integrity": "sha512-U2ALcoAHvA1oO2xOreyHvtkQ+IELqDG2WVWRI1GH/XEmmfGIOalnM5MU5Dd2ITyWfr3m6kNqXiy8XuYyd4wKJw==", - "dev": true, - "requires": { - "boom": "7.x.x" - } - }, - "heavy": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/heavy/-/heavy-6.1.1.tgz", - "integrity": "sha512-Y+QRMABaxgIT1wjbtsBe2V/z+JYAmG7XAkQ2gSSsU0BSpg/T/NKzj/0zUKLcgOiEeuDwDXpJJRE79xVwhQOoMw==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "6.x.x", - "joi": "14.x.x" - } - }, - "hoek": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/hoek/-/hoek-6.0.0.tgz", - "integrity": "sha512-NCB2kQcmiazLBKaM/uTvw+2XWSuwA8Q1ACBkvbEL9ScCe7DP8Divg3MF2aFOYLGdA64SPf9+gr2QESO9l0ULVQ==", - "dev": true - }, - "iron": { - "version": "5.0.5", - "resolved": "https://registry.npmjs.org/iron/-/iron-5.0.5.tgz", - "integrity": "sha512-unM1u+XkSfQGM6X1ByVOAnrM32VhYVgDeHV/2kHHOD19E+6AVQrVDYefcIJGxbY3CZ3sREXs7J6nSQoYsAwNgw==", - "dev": true, - "requires": { - "b64": "4.x.x", - "boom": "7.x.x", - "cryptiles": "4.x.x", - "hoek": "6.x.x" - } - }, - "joi": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/joi/-/joi-14.0.3.tgz", - "integrity": "sha512-EtFiturEwhrNuTn1bpR4VodSPsi6r1A661BjLC6OMnETU+ClDdyV1aKWXgPTYKs+mVjvsPRtdn7rsgxbXU+jiQ==", - "dev": true, - "requires": { - "hoek": "6.x.x", - "isemail": "3.x.x", - "topo": "3.x.x" - } - }, - "mime-db": { - "version": "1.37.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.37.0.tgz", - "integrity": "sha512-R3C4db6bgQhlIhPU48fUtdVmKnflq+hRdad7IyKhtFj06VPNVdk2RhiYL3UjQIlso8L+YxAtFkobT0VK+S/ybg==", - "dev": true - }, - "mimos": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/mimos/-/mimos-4.0.1.tgz", - "integrity": "sha512-czGtWzZ2/RKGjkDbRyVHNmxtaoMOT70RilC1kSZ28UDenALaw8KQEnEeTvUaN5NrTTWnpt3KK63/JJLJF9meFA==", - "dev": true, - "requires": { - "hoek": "6.x.x", - "mime-db": "1.x.x" - } - }, - "nigel": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/nigel/-/nigel-3.0.3.tgz", - "integrity": "sha512-9cTwTCkT01RUHRbeAlY4bJDXlcdEE6g7KPjiEwiJlwA4FyJMVxJRBFJk7kPPcoaqA3SEKJtUnY+HqiFZKv/+CA==", - "dev": true, - "requires": { - "hoek": "6.x.x", - "vise": "3.x.x" - } - }, - "pez": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/pez/-/pez-4.0.4.tgz", - "integrity": "sha512-fpClWiM4RJV+zZ7iWU14g+OVsGLDt98B6kaTify55ppvF1zDmQCI2m7mUXB1z/MRKnkWCaKjl3QZD4HPNPtrQA==", - "dev": true, - "requires": { - "b64": "4.x.x", - "boom": "7.x.x", - "content": "4.x.x", - "hoek": "6.x.x", - "nigel": "3.x.x" - } - }, - "podium": { - "version": "3.1.4", - "resolved": "https://registry.npmjs.org/podium/-/podium-3.1.4.tgz", - "integrity": "sha512-OGLjVaK1McE/tMNbWM5jQMbrwWBYG+lSy8xlmi/hvlBO2qwyC7lVDO/3/D5hETD+8BAIjHs+xrbHN+2ScNluSw==", - "dev": true, - "requires": { - "hoek": "6.x.x", - "joi": "14.x.x" - } - }, - "shot": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/shot/-/shot-4.0.6.tgz", - "integrity": "sha512-dhgIEZfjAVDBy2PYXlN30F0auuGfLkGATMTtAJGtNGL1AFPqza4M5qLOEm6h/JDRx06B0wxJiyhUCn1SVsxE5w==", - "dev": true, - "requires": { - "hoek": "6.x.x", - "joi": "14.x.x" - } - }, - "statehood": { - "version": "6.0.7", - "resolved": "https://registry.npmjs.org/statehood/-/statehood-6.0.7.tgz", - "integrity": "sha512-qezTt0KfZshh7n4iRj8mFNOEgy9KKM8wVTQZDZkY288qslw6a3K8em1ig5ysyczVJB4ERN7oq2RNPes+WcVqSA==", - "dev": true, - "requires": { - "boom": "7.x.x", - "bounce": "1.x.x", - "cryptiles": "4.x.x", - "hoek": "6.x.x", - "iron": "5.x.x", - "joi": "14.x.x" - } - }, - "subtext": { - "version": "6.0.9", - "resolved": "https://registry.npmjs.org/subtext/-/subtext-6.0.9.tgz", - "integrity": "sha512-UX8Y6GCHfo4Dw0ED7vLQVc+2E3SR1f1rKvqUf2HwDjLjT18SGejX73RIcwYia298+gU/ACZJKEJ8v9MBNVIvdw==", - "dev": true, - "requires": { - "boom": "7.x.x", - "content": "4.x.x", - "hoek": "6.x.x", - "pez": "4.x.x", - "wreck": "14.x.x" - } - }, - "teamwork": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/teamwork/-/teamwork-3.0.1.tgz", - "integrity": "sha1-/zjHFh9B+AcLeBNxbrYVQDbs4ZY=", - "dev": true - }, - "topo": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/topo/-/topo-3.0.2.tgz", - "integrity": "sha512-fGuXH4Ee+RCiZ6edV/lZVY1VNVD4mR+VklPS+bSjYug06im3AlUcPaEB4Lss2pPM/u1h+zxiE/X0Pkhj7pFuKw==", - "dev": true, - "requires": { - "hoek": "6.x.x" - } - }, - "vise": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/vise/-/vise-3.0.0.tgz", - "integrity": "sha512-kBFZLmiL1Vm3rHXphkhvvAcsjgeQXRrOFCbJb0I50YZZP4HGRNH+xGzK3matIMcpbsfr3I02u9odj4oCD0TWgA==", - "dev": true, - "requires": { - "hoek": "5.x.x" - }, - "dependencies": { - "hoek": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/hoek/-/hoek-5.0.4.tgz", - "integrity": "sha512-Alr4ZQgoMlnere5FZJsIyfIjORBqZll5POhDsF4q64dPuJR6rNxXdDxtHSQq8OXRurhmx+PWYEE8bXRROY8h0w==", - "dev": true - } - } - }, - "wreck": { - "version": "14.1.2", - "resolved": "https://registry.npmjs.org/wreck/-/wreck-14.1.2.tgz", - "integrity": "sha512-lzpOgaQESUSGn82WoEWvIHt8R2GxTc1sIIVfb8uDABND1ZoEW9+aWoyaYaYvssXnY86enHR2boVFA2nHkvzQOw==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "6.x.x" - } - } } }, "har-schema": { @@ -6553,6 +6361,17 @@ "simple-lru-cache": "0.0.x" } }, + "heavy": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/heavy/-/heavy-6.1.0.tgz", + "integrity": "sha512-TKS9DC9NOTGulHQI31Lx+bmeWmNOstbJbGMiN3pX6bF+Zc2GKSpbbym4oasNnB6yPGkqJ9TQXXYDGohqNSJRxA==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "5.x.x", + "joi": "13.x.x" + } + }, "hoek": { "version": "5.0.4", "resolved": "https://registry.npmjs.org/hoek/-/hoek-5.0.4.tgz", @@ -6691,9 +6510,9 @@ } }, "husky": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/husky/-/husky-1.1.3.tgz", - "integrity": "sha512-6uc48B/A2Mqi65yeg37d/TPcTb0bZ1GTkMYOM0nXLOPuPaTRhXCeee80/noOrbavWd12x72Tusja7GJ5rzvV6g==", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/husky/-/husky-1.1.2.tgz", + "integrity": "sha512-9TdkUpBeEOjz0AnFdUN4i3w8kEbOsVs9/WSeJqWLq2OO6bcKQhVW64Zi+pVd/AMRLpN3QTINb6ZXiELczvdmqQ==", "dev": true, "requires": { "cosmiconfig": "^5.0.6", @@ -6902,6 +6721,17 @@ "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.8.0.tgz", "integrity": "sha1-6qM9bd16zo9/b+DJygRA5wZzix4=" }, + "iron": { + "version": "5.0.4", + "resolved": "https://registry.npmjs.org/iron/-/iron-5.0.4.tgz", + "integrity": "sha512-7iQ5/xFMIYaNt9g2oiNiWdhrOTdRUMFaWENUd0KghxwPUhrIH8DUY8FEyLNTTzf75jaII+jMexLdY/2HfV61RQ==", + "dev": true, + "requires": { + "boom": "7.x.x", + "cryptiles": "4.x.x", + "hoek": "5.x.x" + } + }, "is-accessor-descriptor": { "version": "0.1.6", "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", @@ -7178,9 +7008,9 @@ "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=" }, "isemail": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/isemail/-/isemail-3.2.0.tgz", - "integrity": "sha512-zKqkK+O+dGqevc93KNsbZ/TqTUFd46MwWjYOoMrjIMZ51eU7DtQG3Wmd9SQQT7i7RVnuTPEiYEWHU3MSbxC1Tg==", + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/isemail/-/isemail-3.1.3.tgz", + "integrity": "sha512-5xbsG5wYADIcB+mfLsd+nst1V/D+I7EU7LEZPo2GOIMu4JzfcRs5yQoypP4avA7QtUqgxYLKBYNv4IdzBmbhdw==", "dev": true, "requires": { "punycode": "2.x.x" @@ -7802,6 +7632,17 @@ "merge-stream": "^1.0.1" } }, + "joi": { + "version": "13.7.0", + "resolved": "https://registry.npmjs.org/joi/-/joi-13.7.0.tgz", + "integrity": "sha512-xuY5VkHfeOYK3Hdi91ulocfuFopwgbSORmIwzcwHKESQhC7w1kD5jaVSPnqDxS2I8t3RZ9omCKAxNwXN5zG1/Q==", + "dev": true, + "requires": { + "hoek": "5.x.x", + "isemail": "3.x.x", + "topo": "3.x.x" + } + }, "js-sha256": { "version": "0.9.0", "resolved": "https://registry.npmjs.org/js-sha256/-/js-sha256-0.9.0.tgz", @@ -8708,7 +8549,7 @@ }, "onetime": { "version": "1.1.0", - "resolved": "http://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", "integrity": "sha1-ofeDj4MUxRbwXs78vEzP4EtO14k=", "dev": true }, @@ -8741,7 +8582,7 @@ }, "load-json-file": { "version": "1.1.0", - "resolved": "http://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", + "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", "integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=", "dev": true, "requires": { @@ -8851,7 +8692,7 @@ }, "onetime": { "version": "1.1.0", - "resolved": "http://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", "integrity": "sha1-ofeDj4MUxRbwXs78vEzP4EtO14k=", "dev": true }, @@ -9297,6 +9138,16 @@ "integrity": "sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==", "dev": true }, + "mimos": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/mimos/-/mimos-4.0.0.tgz", + "integrity": "sha512-JvlvRLqGIlk+AYypWrbrDmhsM+6JVx/xBM5S3AMwTBz1trPCEoPN/swO2L4Wu653fL7oJdgk8DMQyG/Gq3JkZg==", + "dev": true, + "requires": { + "hoek": "5.x.x", + "mime-db": "1.x.x" + } + }, "minimalistic-assert": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", @@ -9539,6 +9390,16 @@ "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", "dev": true }, + "nigel": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/nigel/-/nigel-3.0.1.tgz", + "integrity": "sha512-kCVtUG9JyD//tsYrZY+/Y+2gUrANVSba8y23QkM5Znx0FOxlnl9Z4OVPBODmstKWTOvigfTO+Va1VPOu3eWSOQ==", + "dev": true, + "requires": { + "hoek": "5.x.x", + "vise": "3.x.x" + } + }, "node-fetch": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.2.0.tgz", @@ -10124,7 +9985,7 @@ }, "readable-stream": { "version": "2.3.6", - "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", "integrity": "sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==", "dev": true, "requires": { @@ -10259,6 +10120,19 @@ "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", "dev": true }, + "pez": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/pez/-/pez-4.0.2.tgz", + "integrity": "sha512-HuPxmGxHsEFPWhdkwBs2gIrHhFqktIxMtudISTFN95RQ85ZZAOl8Ki6u3nnN/X8OUaGlIGldk/l8p2IR4/i76w==", + "dev": true, + "requires": { + "b64": "4.x.x", + "boom": "7.x.x", + "content": "4.x.x", + "hoek": "5.x.x", + "nigel": "3.x.x" + } + }, "pify": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", @@ -10304,6 +10178,16 @@ "integrity": "sha512-2qHaIQr2VLRFoxe2nASzsV6ef4yOOH+Fi9FBOVH6cqeSgUnoyySPZkxzLuzd+RYOQTRpROA0ztTMqxROKSb/nA==", "dev": true }, + "podium": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/podium/-/podium-3.1.2.tgz", + "integrity": "sha512-18VrjJAduIdPv7d9zWsfmKxTj3cQTYC5Pv5gtKxcWujYBpGbV+mhNSPYhlHW5xeWoazYyKfB9FEsPT12r5rY1A==", + "dev": true, + "requires": { + "hoek": "5.x.x", + "joi": "13.x.x" + } + }, "posix-character-classes": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/posix-character-classes/-/posix-character-classes-0.1.1.tgz", @@ -11430,6 +11314,16 @@ "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==", "dev": true }, + "shot": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/shot/-/shot-4.0.5.tgz", + "integrity": "sha1-x+dFXRHWD2ts08Q+FaO0McF+VWY=", + "dev": true, + "requires": { + "hoek": "5.x.x", + "joi": "13.x.x" + } + }, "signal-exit": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", @@ -11745,6 +11639,20 @@ "integrity": "sha512-H89UNKr1rQJvI1c/PIR3kiAMBV23yvR7LItZiV74HWZwzt7f3YHuujJ9nJZlt58WlFox7XQsOahexwk7nTe69A==", "dev": true }, + "statehood": { + "version": "6.0.6", + "resolved": "https://registry.npmjs.org/statehood/-/statehood-6.0.6.tgz", + "integrity": "sha512-jR45n5ZMAkasw0xoE9j9TuLmJv4Sa3AkXe+6yIFT6a07kXYHgSbuD2OVGECdZGFxTmvNqLwL1iRIgvq6O6rq+A==", + "dev": true, + "requires": { + "boom": "7.x.x", + "bounce": "1.x.x", + "cryptiles": "4.x.x", + "hoek": "5.x.x", + "iron": "5.x.x", + "joi": "13.x.x" + } + }, "static-extend": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/static-extend/-/static-extend-0.1.2.tgz", @@ -11892,7 +11800,7 @@ "dependencies": { "minimist": { "version": "1.2.0", - "resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true } @@ -11920,6 +11828,19 @@ } } }, + "subtext": { + "version": "6.0.7", + "resolved": "https://registry.npmjs.org/subtext/-/subtext-6.0.7.tgz", + "integrity": "sha512-IcJUvRjeR+NB437Iq+LORFNJW4L6Knqkj3oQrBrkdhIaS2VKJvx/9aYEq7vi+PEx5/OuehOL/40SkSZotLi/MA==", + "dev": true, + "requires": { + "boom": "7.x.x", + "content": "4.x.x", + "hoek": "5.x.x", + "pez": "4.x.x", + "wreck": "14.x.x" + } + }, "superagent": { "version": "3.8.3", "resolved": "https://registry.npmjs.org/superagent/-/superagent-3.8.3.tgz", @@ -12031,6 +11952,12 @@ "inherits": "2" } }, + "teamwork": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/teamwork/-/teamwork-3.0.1.tgz", + "integrity": "sha512-hEkJIpDOfOYe9NYaLFk00zQbzZeKNCY8T2pRH3I13Y1mJwxaSQ6NEsjY5rCp+11ezCiZpWGoGFTbOuhg4qKevQ==", + "dev": true + }, "temp-dir": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/temp-dir/-/temp-dir-1.0.0.tgz", @@ -12198,6 +12125,15 @@ "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==" }, + "topo": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/topo/-/topo-3.0.0.tgz", + "integrity": "sha512-Tlu1fGlR90iCdIPURqPiufqAlCZYzLjHYVVbcFWDMcX7+tK8hdZWAfsMrD/pBul9jqHHwFjNdf1WaxA9vTRRhw==", + "dev": true, + "requires": { + "hoek": "5.x.x" + } + }, "toposort": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/toposort/-/toposort-2.0.2.tgz", @@ -12276,7 +12212,7 @@ }, "minimist": { "version": "1.2.0", - "resolved": "http://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=", "dev": true }, @@ -12377,9 +12313,9 @@ "dev": true }, "typescript": { - "version": "3.2.0-dev.20181102", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.2.0-dev.20181102.tgz", - "integrity": "sha512-fjHMxgzARm5KkT3WBS2j0/TaD2l49Oj9DknJUT3pMpg+wtE7EY7wMQsxgB3++8fDZzD++ybJ7L34y6G+59c24Q==", + "version": "3.2.0-dev.20181030", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.2.0-dev.20181030.tgz", + "integrity": "sha512-UqZfZY7xAojS2f9SdLTEJ78Itxs1rlZZSlIHffQwFxdnO/jhMBmcVgaVpT+dsjnbuWnZKcX3Dozkdw06TjB8pg==", "dev": true }, "uglify-js": { @@ -12613,6 +12549,15 @@ "extsprintf": "^1.2.0" } }, + "vise": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/vise/-/vise-3.0.0.tgz", + "integrity": "sha512-kBFZLmiL1Vm3rHXphkhvvAcsjgeQXRrOFCbJb0I50YZZP4HGRNH+xGzK3matIMcpbsfr3I02u9odj4oCD0TWgA==", + "dev": true, + "requires": { + "hoek": "5.x.x" + } + }, "w3c-hr-time": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/w3c-hr-time/-/w3c-hr-time-1.0.1.tgz", @@ -12784,6 +12729,16 @@ "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true }, + "wreck": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/wreck/-/wreck-14.1.0.tgz", + "integrity": "sha512-y/iwFhwdGoM8Hk1t1I4LbuLhM3curVD8STd5NcFI0c/4b4cQAMLcnCRxXX9sLQAggDC8dXYSaQNsT64hga6lvA==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "5.x.x" + } + }, "write-file-atomic": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.3.0.tgz", diff --git a/packages/apollo-server-testing/src/createTestClient.ts b/packages/apollo-server-testing/src/createTestClient.ts index 701482e09be..136bfca27bc 100644 --- a/packages/apollo-server-testing/src/createTestClient.ts +++ b/packages/apollo-server-testing/src/createTestClient.ts @@ -1,4 +1,4 @@ -import { ApolloServerBase, gql } from 'apollo-server-core'; +import { ApolloServerBase } from 'apollo-server-core'; import { print } from 'graphql'; export default (server: ApolloServerBase, ctxFn: (...args: any[]) => any) => { From 675e52cc97c74aaea80e8f8a054309f59a727eb1 Mon Sep 17 00:00:00 2001 From: Jake Date: Sun, 4 Nov 2018 11:05:05 -0500 Subject: [PATCH 10/14] revert package-lock --- package-lock.json | 527 +++++++++++++++++++++++++--------------------- 1 file changed, 282 insertions(+), 245 deletions(-) diff --git a/package-lock.json b/package-lock.json index 7b2a445543b..4fd3ae1e72e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1470,9 +1470,9 @@ } }, "@types/node": { - "version": "10.12.1", - "resolved": "https://registry.npmjs.org/@types/node/-/node-10.12.1.tgz", - "integrity": "sha512-i1sl+WCX2OCHeUi9oi7PiCNUtYFrpWhpcx878vpeq/tlZTKzcFdHePlyFHVbWqeuKN0SRPl/9ZFDSTsfv9h7VQ==" + "version": "10.12.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-10.12.2.tgz", + "integrity": "sha512-53ElVDSnZeFUUFIYzI8WLQ25IhWzb6vbddNp8UHlXQyU0ET2RhV5zg0NfubzU7iNMh5bBXb0htCzfvrSVNgzaQ==" }, "@types/node-fetch": { "version": "2.1.2", @@ -1676,15 +1676,6 @@ "json-schema-traverse": "^0.3.0" } }, - "ammo": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/ammo/-/ammo-3.0.1.tgz", - "integrity": "sha512-4UqoM8xQjwkQ78oiU4NbBK0UgYqeKMAKmwE4ec7Rz3rGU8ZEBFxzgF2sUYKOAlqIXExBDYLN6y1ShF5yQ4hwLQ==", - "dev": true, - "requires": { - "hoek": "5.x.x" - } - }, "ansi-escapes": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.1.0.tgz", @@ -2528,12 +2519,6 @@ "integrity": "sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==", "dev": true }, - "b64": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/b64/-/b64-4.0.0.tgz", - "integrity": "sha512-EhmUQodKB0sdzPPrbIWbGqA5cQeTWxYrAgNeeT1rLZWtD3tbNTnphz8J4vkXI3cPgBNlXBjzEbzDzq0Nwi4f9A==", - "dev": true - }, "babel-code-frame": { "version": "6.26.0", "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz", @@ -2908,12 +2893,6 @@ "tweetnacl": "^0.14.3" } }, - "big-time": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/big-time/-/big-time-2.0.1.tgz", - "integrity": "sha1-aMffjcMPl+lT8lpnp2rJcTwWyd4=", - "dev": true - }, "block-stream": { "version": "0.0.9", "resolved": "https://registry.npmjs.org/block-stream/-/block-stream-0.0.9.tgz", @@ -2954,16 +2933,6 @@ "hoek": "5.x.x" } }, - "bounce": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/bounce/-/bounce-1.2.0.tgz", - "integrity": "sha512-8syCGe8B2/WC53118/F/tFy5aW00j+eaGPXmAUP7iBhxc+EBZZxS1vKelWyBCH6IqojgS2t1gF0glH30qAJKEw==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "5.x.x" - } - }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -3126,16 +3095,6 @@ "ylru": "^1.2.0" } }, - "call": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/call/-/call-5.0.1.tgz", - "integrity": "sha512-ollfFPSshiuYLp7AsrmpkQJ/PxCi6AzV81rCjBwWhyF2QGyUY/vPDMzoh4aUcWyucheRglG2LaS5qkIEfLRh6A==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "5.x.x" - } - }, "call-me-maybe": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/call-me-maybe/-/call-me-maybe-1.0.1.tgz", @@ -3180,28 +3139,6 @@ "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", "dev": true }, - "catbox": { - "version": "10.0.3", - "resolved": "https://registry.npmjs.org/catbox/-/catbox-10.0.3.tgz", - "integrity": "sha512-qwus6RnVctHXYwfxvvDwvlMWHwCjQdIpQQbtyHnRF0JpwmxbQJ/UIZi9y8O6DpphKCdfO9gpxgb2ne9ZDx39BQ==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "5.x.x", - "joi": "13.x.x" - } - }, - "catbox-memory": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/catbox-memory/-/catbox-memory-3.1.2.tgz", - "integrity": "sha512-lhWtutLVhsq3Mucxk2McxBPPibJ34WcHuWFz3xqub9u9Ve/IQYpZv3ijLhQXfQped9DXozURiaq9O3aZpP91eg==", - "dev": true, - "requires": { - "big-time": "2.x.x", - "boom": "7.x.x", - "hoek": "5.x.x" - } - }, "chalk": { "version": "2.4.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.0.tgz", @@ -3596,15 +3533,6 @@ "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=", "dev": true }, - "content": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/content/-/content-4.0.5.tgz", - "integrity": "sha512-wDP6CTWDpwCf791fNxlCCkZGRkrNzSEU/8ju9Hnr3Uc5mF/gFR5W+fcoGm6zUSlVPdSXYn5pCbySADKj7YM4Cg==", - "dev": true, - "requires": { - "boom": "7.x.x" - } - }, "content-disposition": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.2.tgz", @@ -3841,15 +3769,6 @@ "which": "^1.2.9" } }, - "cryptiles": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-4.1.2.tgz", - "integrity": "sha512-U2ALcoAHvA1oO2xOreyHvtkQ+IELqDG2WVWRI1GH/XEmmfGIOalnM5MU5Dd2ITyWfr3m6kNqXiy8XuYyd4wKJw==", - "dev": true, - "requires": { - "boom": "7.x.x" - } - }, "cssom": { "version": "0.3.4", "resolved": "https://registry.npmjs.org/cssom/-/cssom-0.3.4.tgz", @@ -6209,9 +6128,9 @@ } }, "hapi": { - "version": "17.6.0", - "resolved": "https://registry.npmjs.org/hapi/-/hapi-17.6.0.tgz", - "integrity": "sha512-GSHjE1hJExluAukrT/QuYSk96irmbYBDd3wOgywiHsPoR2QeKgDnIttD+dB6NbADEmSdb9MS5gTUIVq0uHTdkA==", + "version": "17.6.4", + "resolved": "https://registry.npmjs.org/hapi/-/hapi-17.6.4.tgz", + "integrity": "sha512-PkVXt3Y7MpWr9sZVcwBT0ijiWkbs8uYo/pJYCSHrr6E9mZT6EyFpXcSr9Cxv0eikmlHUlEdHDhP6IPk2WdMeTA==", "dev": true, "requires": { "accept": "3.x.x", @@ -6222,8 +6141,8 @@ "catbox": "10.x.x", "catbox-memory": "3.x.x", "heavy": "6.x.x", - "hoek": "5.x.x", - "joi": "13.x.x", + "hoek": "6.x.x", + "joi": "14.x.x", "mimos": "4.x.x", "podium": "3.x.x", "shot": "4.x.x", @@ -6231,6 +6150,271 @@ "subtext": "6.x.x", "teamwork": "3.x.x", "topo": "3.x.x" + }, + "dependencies": { + "accept": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/accept/-/accept-3.1.3.tgz", + "integrity": "sha512-OgOEAidVEOKPup+Gv2+2wdH2AgVKI9LxsJ4hicdJ6cY0faUuZdZoi56kkXWlHp9qicN1nWQLmW5ZRGk+SBS5xg==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "6.x.x" + } + }, + "ammo": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/ammo/-/ammo-3.0.3.tgz", + "integrity": "sha512-vo76VJ44MkUBZL/BzpGXaKzMfroF4ZR6+haRuw9p+eSWfoNaH2AxVc8xmiEPC08jhzJSeM6w7/iMUGet8b4oBQ==", + "dev": true, + "requires": { + "hoek": "6.x.x" + } + }, + "b64": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/b64/-/b64-4.1.2.tgz", + "integrity": "sha512-+GUspBxlH3CJaxMUGUE1EBoWM6RKgWiYwUDal0qdf8m3ArnXNN1KzKVo5HOnE/FSq4HHyWf3TlHLsZI8PKQgrQ==", + "dev": true, + "requires": { + "hoek": "6.x.x" + } + }, + "big-time": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/big-time/-/big-time-2.0.1.tgz", + "integrity": "sha512-qtwYYoocwpiAxTXC5sIpB6nH5j6ckt+n/jhD7J5OEiFHnUZEFn0Xk8STUaE5s10LdazN/87bTDMe+fSihaW7Kg==", + "dev": true + }, + "boom": { + "version": "7.2.2", + "resolved": "https://registry.npmjs.org/boom/-/boom-7.2.2.tgz", + "integrity": "sha512-IFUbOa8PS7xqmhIjpeStwT3d09hGkNYQ6aj2iELSTxcVs2u0aKn1NzhkdUQSzsRg1FVkj3uit3I6mXQCBixw+A==", + "dev": true, + "requires": { + "hoek": "6.x.x" + } + }, + "bounce": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/bounce/-/bounce-1.2.2.tgz", + "integrity": "sha512-1LPcXg3fkGVhjdA/P3DcR5cDktKEYtDpruJv9Nhmy36RoYaoxZfC82Zr2JmS3vysDJKqMtP0qJw3/P6iisTASg==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "6.x.x" + } + }, + "call": { + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/call/-/call-5.0.3.tgz", + "integrity": "sha512-eX16KHiAYXugbFu6VifstSdwH6aMuWWb4s0qvpq1nR1b+Sf+u68jjttg8ixDBEldPqBi30bDU35OJQWKeTLKxg==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "6.x.x" + } + }, + "catbox": { + "version": "10.0.5", + "resolved": "https://registry.npmjs.org/catbox/-/catbox-10.0.5.tgz", + "integrity": "sha512-5SpI/tEP3SiLE1qkkV+/hdVW48sHVBEbzPX4jBiwl6hsZh/gkl4bqfGLkvh7mjpMK5evJ0Rm/6NRlhF/Jsy9ow==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "6.x.x", + "joi": "14.x.x" + } + }, + "catbox-memory": { + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/catbox-memory/-/catbox-memory-3.1.4.tgz", + "integrity": "sha512-1tDnll066au0HXBSDHS/YQ34MQ2omBsmnA9g/jseyq/M3m7UPrajVtPDZK/rXgikSC1dfjo9Pa+kQ1qcyG2d3g==", + "dev": true, + "requires": { + "big-time": "2.x.x", + "boom": "7.x.x", + "hoek": "6.x.x" + } + }, + "content": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/content/-/content-4.0.6.tgz", + "integrity": "sha512-lR9ND3dXiMdmsE84K6l02rMdgiBVmtYWu1Vr/gfSGHcIcznBj2QxmSdUgDuNFOA+G9yrb1IIWkZ7aKtB6hDGyA==", + "dev": true, + "requires": { + "boom": "7.x.x" + } + }, + "cryptiles": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-4.1.3.tgz", + "integrity": "sha512-gT9nyTMSUC1JnziQpPbxKGBbUg8VL7Zn2NB4E1cJYvuXdElHrwxrV9bmltZGDzet45zSDGyYceueke1TjynGzw==", + "dev": true, + "requires": { + "boom": "7.x.x" + } + }, + "heavy": { + "version": "6.1.2", + "resolved": "https://registry.npmjs.org/heavy/-/heavy-6.1.2.tgz", + "integrity": "sha512-cJp884bqhiebNcEHydW0g6V1MUGYOXRPw9c7MFiHQnuGxtbWuSZpsbojwb2kxb3AA1/Rfs8CNiV9MMOF8pFRDg==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "6.x.x", + "joi": "14.x.x" + } + }, + "hoek": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/hoek/-/hoek-6.0.1.tgz", + "integrity": "sha512-3PvUwBerLNVJiIVQdpkWF9F/M0ekgb2NPJWOhsE28RXSQPsY42YSnaJ8d1kZjcAz58TZ/Fk9Tw64xJsENFlJNw==", + "dev": true + }, + "iron": { + "version": "5.0.6", + "resolved": "https://registry.npmjs.org/iron/-/iron-5.0.6.tgz", + "integrity": "sha512-zYUMOSkEXGBdwlV/AXF9zJC0aLuTJUKHkGeYS5I2g225M5i6SrxQyGJGhPgOR8BK1omL6N5i6TcwfsXbP8/Exw==", + "dev": true, + "requires": { + "b64": "4.x.x", + "boom": "7.x.x", + "cryptiles": "4.x.x", + "hoek": "6.x.x" + } + }, + "joi": { + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/joi/-/joi-14.0.4.tgz", + "integrity": "sha512-KUXRcinDUMMbtlOk7YLGHQvG73dLyf8bmgE+6sBTkdJbZpeGVGAlPXEHLiQBV7KinD/VLD5OA0EUgoTTfbRAJQ==", + "dev": true, + "requires": { + "hoek": "6.x.x", + "isemail": "3.x.x", + "topo": "3.x.x" + } + }, + "mime-db": { + "version": "1.37.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.37.0.tgz", + "integrity": "sha512-R3C4db6bgQhlIhPU48fUtdVmKnflq+hRdad7IyKhtFj06VPNVdk2RhiYL3UjQIlso8L+YxAtFkobT0VK+S/ybg==", + "dev": true + }, + "mimos": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/mimos/-/mimos-4.0.2.tgz", + "integrity": "sha512-5XBsDqBqzSN88XPPH/TFpOalWOjHJM5Z2d3AMx/30iq+qXvYKd/8MPhqBwZDOLtoaIWInR3nLzMQcxfGK9djXA==", + "dev": true, + "requires": { + "hoek": "6.x.x", + "mime-db": "1.x.x" + } + }, + "nigel": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/nigel/-/nigel-3.0.4.tgz", + "integrity": "sha512-3SZCCS/duVDGxFpTROHEieC+itDo4UqL9JNUyQJv3rljudQbK6aqus5B4470OxhESPJLN93Qqxg16rH7DUjbfQ==", + "dev": true, + "requires": { + "hoek": "6.x.x", + "vise": "3.x.x" + } + }, + "pez": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/pez/-/pez-4.0.5.tgz", + "integrity": "sha512-HvL8uiFIlkXbx/qw4B8jKDCWzo7Pnnd65Uvanf9OOCtb20MRcb9gtTVBf9NCnhETif1/nzbDHIjAWC/sUp7LIQ==", + "dev": true, + "requires": { + "b64": "4.x.x", + "boom": "7.x.x", + "content": "4.x.x", + "hoek": "6.x.x", + "nigel": "3.x.x" + } + }, + "podium": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/podium/-/podium-3.1.5.tgz", + "integrity": "sha512-+fAPmAj3d5fWKx5oSjQKeBIcl46/qZnGLhzyi/dJ/HzNiOpuxyX/Y4091LiVxZQ4ALdf/LCS7siV6ai5nNLlOg==", + "dev": true, + "requires": { + "hoek": "6.x.x", + "joi": "14.x.x" + } + }, + "shot": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/shot/-/shot-4.0.7.tgz", + "integrity": "sha512-RKaKAGKxJ11EjJl0cf2fYVSsd4KB5Cncb9J0v7w+0iIaXpxNqFWTYNDNhBX7f0XSyDrjOH9a4OWZ9Gp/ZML+ew==", + "dev": true, + "requires": { + "hoek": "6.x.x", + "joi": "14.x.x" + } + }, + "statehood": { + "version": "6.0.8", + "resolved": "https://registry.npmjs.org/statehood/-/statehood-6.0.8.tgz", + "integrity": "sha512-/uk2Iq5VXCAGmYnRTjez6gDfU8fROm1Um5WH2C9aNCdG7DAqD94dqZgeuqXrvVFnfDqxAtorUBLUtD9El/uJ6w==", + "dev": true, + "requires": { + "boom": "7.x.x", + "bounce": "1.x.x", + "cryptiles": "4.x.x", + "hoek": "6.x.x", + "iron": "5.x.x", + "joi": "14.x.x" + } + }, + "subtext": { + "version": "6.0.11", + "resolved": "https://registry.npmjs.org/subtext/-/subtext-6.0.11.tgz", + "integrity": "sha512-jap1ev33dbVTBPxpIyJ5OvD9/J4oWlx1qHQ8bBnKpiwItxXt3+7tvmNZqZeTEQVTjvkReHY1ZnP/7iltNdGnOA==", + "dev": true, + "requires": { + "boom": "7.x.x", + "content": "4.x.x", + "hoek": "6.x.x", + "pez": "4.x.x", + "wreck": "14.x.x" + } + }, + "teamwork": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/teamwork/-/teamwork-3.0.2.tgz", + "integrity": "sha512-tpG01+9Qws/oGhMBiZN3BnB32gn5QeKY84AmLxxaCJw4mNeRzhEZ6jEj/vBhKerHD7Hgq9/vOZ58pyryYSn9gA==", + "dev": true + }, + "topo": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/topo/-/topo-3.0.3.tgz", + "integrity": "sha512-IgpPtvD4kjrJ7CRA3ov2FhWQADwv+Tdqbsf1ZnPUSAtCJ9e1Z44MmoSGDXGk4IppoZA7jd/QRkNddlLJWlUZsQ==", + "dev": true, + "requires": { + "hoek": "6.x.x" + } + }, + "vise": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/vise/-/vise-3.0.1.tgz", + "integrity": "sha512-7BJNjsv2o83+E6AHAFSnjQF324UTgypsR/Sw/iFmLvr7RgJrEXF1xNBvb5LJfi+1FvWQXjJK4X41WMuHMeunPQ==", + "dev": true, + "requires": { + "hoek": "6.x.x" + } + }, + "wreck": { + "version": "14.1.3", + "resolved": "https://registry.npmjs.org/wreck/-/wreck-14.1.3.tgz", + "integrity": "sha512-hb/BUtjX3ObbwO3slCOLCenQ4EP8e+n8j6FmTne3VhEFp5XV1faSJojiyxVSvw34vgdeTG5baLTl4NmjwokLlw==", + "dev": true, + "requires": { + "boom": "7.x.x", + "hoek": "6.x.x" + } + } } }, "har-schema": { @@ -6361,17 +6545,6 @@ "simple-lru-cache": "0.0.x" } }, - "heavy": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/heavy/-/heavy-6.1.0.tgz", - "integrity": "sha512-TKS9DC9NOTGulHQI31Lx+bmeWmNOstbJbGMiN3pX6bF+Zc2GKSpbbym4oasNnB6yPGkqJ9TQXXYDGohqNSJRxA==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "5.x.x", - "joi": "13.x.x" - } - }, "hoek": { "version": "5.0.4", "resolved": "https://registry.npmjs.org/hoek/-/hoek-5.0.4.tgz", @@ -6510,9 +6683,9 @@ } }, "husky": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/husky/-/husky-1.1.2.tgz", - "integrity": "sha512-9TdkUpBeEOjz0AnFdUN4i3w8kEbOsVs9/WSeJqWLq2OO6bcKQhVW64Zi+pVd/AMRLpN3QTINb6ZXiELczvdmqQ==", + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/husky/-/husky-1.1.3.tgz", + "integrity": "sha512-6uc48B/A2Mqi65yeg37d/TPcTb0bZ1GTkMYOM0nXLOPuPaTRhXCeee80/noOrbavWd12x72Tusja7GJ5rzvV6g==", "dev": true, "requires": { "cosmiconfig": "^5.0.6", @@ -6721,17 +6894,6 @@ "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.8.0.tgz", "integrity": "sha1-6qM9bd16zo9/b+DJygRA5wZzix4=" }, - "iron": { - "version": "5.0.4", - "resolved": "https://registry.npmjs.org/iron/-/iron-5.0.4.tgz", - "integrity": "sha512-7iQ5/xFMIYaNt9g2oiNiWdhrOTdRUMFaWENUd0KghxwPUhrIH8DUY8FEyLNTTzf75jaII+jMexLdY/2HfV61RQ==", - "dev": true, - "requires": { - "boom": "7.x.x", - "cryptiles": "4.x.x", - "hoek": "5.x.x" - } - }, "is-accessor-descriptor": { "version": "0.1.6", "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", @@ -7008,9 +7170,9 @@ "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=" }, "isemail": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/isemail/-/isemail-3.1.3.tgz", - "integrity": "sha512-5xbsG5wYADIcB+mfLsd+nst1V/D+I7EU7LEZPo2GOIMu4JzfcRs5yQoypP4avA7QtUqgxYLKBYNv4IdzBmbhdw==", + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/isemail/-/isemail-3.2.0.tgz", + "integrity": "sha512-zKqkK+O+dGqevc93KNsbZ/TqTUFd46MwWjYOoMrjIMZ51eU7DtQG3Wmd9SQQT7i7RVnuTPEiYEWHU3MSbxC1Tg==", "dev": true, "requires": { "punycode": "2.x.x" @@ -7632,17 +7794,6 @@ "merge-stream": "^1.0.1" } }, - "joi": { - "version": "13.7.0", - "resolved": "https://registry.npmjs.org/joi/-/joi-13.7.0.tgz", - "integrity": "sha512-xuY5VkHfeOYK3Hdi91ulocfuFopwgbSORmIwzcwHKESQhC7w1kD5jaVSPnqDxS2I8t3RZ9omCKAxNwXN5zG1/Q==", - "dev": true, - "requires": { - "hoek": "5.x.x", - "isemail": "3.x.x", - "topo": "3.x.x" - } - }, "js-sha256": { "version": "0.9.0", "resolved": "https://registry.npmjs.org/js-sha256/-/js-sha256-0.9.0.tgz", @@ -9138,16 +9289,6 @@ "integrity": "sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ==", "dev": true }, - "mimos": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mimos/-/mimos-4.0.0.tgz", - "integrity": "sha512-JvlvRLqGIlk+AYypWrbrDmhsM+6JVx/xBM5S3AMwTBz1trPCEoPN/swO2L4Wu653fL7oJdgk8DMQyG/Gq3JkZg==", - "dev": true, - "requires": { - "hoek": "5.x.x", - "mime-db": "1.x.x" - } - }, "minimalistic-assert": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", @@ -9390,16 +9531,6 @@ "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", "dev": true }, - "nigel": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/nigel/-/nigel-3.0.1.tgz", - "integrity": "sha512-kCVtUG9JyD//tsYrZY+/Y+2gUrANVSba8y23QkM5Znx0FOxlnl9Z4OVPBODmstKWTOvigfTO+Va1VPOu3eWSOQ==", - "dev": true, - "requires": { - "hoek": "5.x.x", - "vise": "3.x.x" - } - }, "node-fetch": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.2.0.tgz", @@ -10120,19 +10251,6 @@ "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", "dev": true }, - "pez": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/pez/-/pez-4.0.2.tgz", - "integrity": "sha512-HuPxmGxHsEFPWhdkwBs2gIrHhFqktIxMtudISTFN95RQ85ZZAOl8Ki6u3nnN/X8OUaGlIGldk/l8p2IR4/i76w==", - "dev": true, - "requires": { - "b64": "4.x.x", - "boom": "7.x.x", - "content": "4.x.x", - "hoek": "5.x.x", - "nigel": "3.x.x" - } - }, "pify": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/pify/-/pify-3.0.0.tgz", @@ -10178,16 +10296,6 @@ "integrity": "sha512-2qHaIQr2VLRFoxe2nASzsV6ef4yOOH+Fi9FBOVH6cqeSgUnoyySPZkxzLuzd+RYOQTRpROA0ztTMqxROKSb/nA==", "dev": true }, - "podium": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/podium/-/podium-3.1.2.tgz", - "integrity": "sha512-18VrjJAduIdPv7d9zWsfmKxTj3cQTYC5Pv5gtKxcWujYBpGbV+mhNSPYhlHW5xeWoazYyKfB9FEsPT12r5rY1A==", - "dev": true, - "requires": { - "hoek": "5.x.x", - "joi": "13.x.x" - } - }, "posix-character-classes": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/posix-character-classes/-/posix-character-classes-0.1.1.tgz", @@ -11314,16 +11422,6 @@ "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==", "dev": true }, - "shot": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/shot/-/shot-4.0.5.tgz", - "integrity": "sha1-x+dFXRHWD2ts08Q+FaO0McF+VWY=", - "dev": true, - "requires": { - "hoek": "5.x.x", - "joi": "13.x.x" - } - }, "signal-exit": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", @@ -11639,20 +11737,6 @@ "integrity": "sha512-H89UNKr1rQJvI1c/PIR3kiAMBV23yvR7LItZiV74HWZwzt7f3YHuujJ9nJZlt58WlFox7XQsOahexwk7nTe69A==", "dev": true }, - "statehood": { - "version": "6.0.6", - "resolved": "https://registry.npmjs.org/statehood/-/statehood-6.0.6.tgz", - "integrity": "sha512-jR45n5ZMAkasw0xoE9j9TuLmJv4Sa3AkXe+6yIFT6a07kXYHgSbuD2OVGECdZGFxTmvNqLwL1iRIgvq6O6rq+A==", - "dev": true, - "requires": { - "boom": "7.x.x", - "bounce": "1.x.x", - "cryptiles": "4.x.x", - "hoek": "5.x.x", - "iron": "5.x.x", - "joi": "13.x.x" - } - }, "static-extend": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/static-extend/-/static-extend-0.1.2.tgz", @@ -11828,19 +11912,6 @@ } } }, - "subtext": { - "version": "6.0.7", - "resolved": "https://registry.npmjs.org/subtext/-/subtext-6.0.7.tgz", - "integrity": "sha512-IcJUvRjeR+NB437Iq+LORFNJW4L6Knqkj3oQrBrkdhIaS2VKJvx/9aYEq7vi+PEx5/OuehOL/40SkSZotLi/MA==", - "dev": true, - "requires": { - "boom": "7.x.x", - "content": "4.x.x", - "hoek": "5.x.x", - "pez": "4.x.x", - "wreck": "14.x.x" - } - }, "superagent": { "version": "3.8.3", "resolved": "https://registry.npmjs.org/superagent/-/superagent-3.8.3.tgz", @@ -11952,12 +12023,6 @@ "inherits": "2" } }, - "teamwork": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/teamwork/-/teamwork-3.0.1.tgz", - "integrity": "sha512-hEkJIpDOfOYe9NYaLFk00zQbzZeKNCY8T2pRH3I13Y1mJwxaSQ6NEsjY5rCp+11ezCiZpWGoGFTbOuhg4qKevQ==", - "dev": true - }, "temp-dir": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/temp-dir/-/temp-dir-1.0.0.tgz", @@ -12125,15 +12190,6 @@ "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==" }, - "topo": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/topo/-/topo-3.0.0.tgz", - "integrity": "sha512-Tlu1fGlR90iCdIPURqPiufqAlCZYzLjHYVVbcFWDMcX7+tK8hdZWAfsMrD/pBul9jqHHwFjNdf1WaxA9vTRRhw==", - "dev": true, - "requires": { - "hoek": "5.x.x" - } - }, "toposort": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/toposort/-/toposort-2.0.2.tgz", @@ -12313,9 +12369,9 @@ "dev": true }, "typescript": { - "version": "3.2.0-dev.20181030", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.2.0-dev.20181030.tgz", - "integrity": "sha512-UqZfZY7xAojS2f9SdLTEJ78Itxs1rlZZSlIHffQwFxdnO/jhMBmcVgaVpT+dsjnbuWnZKcX3Dozkdw06TjB8pg==", + "version": "3.2.0-dev.20181102", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.2.0-dev.20181102.tgz", + "integrity": "sha512-fjHMxgzARm5KkT3WBS2j0/TaD2l49Oj9DknJUT3pMpg+wtE7EY7wMQsxgB3++8fDZzD++ybJ7L34y6G+59c24Q==", "dev": true }, "uglify-js": { @@ -12549,15 +12605,6 @@ "extsprintf": "^1.2.0" } }, - "vise": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/vise/-/vise-3.0.0.tgz", - "integrity": "sha512-kBFZLmiL1Vm3rHXphkhvvAcsjgeQXRrOFCbJb0I50YZZP4HGRNH+xGzK3matIMcpbsfr3I02u9odj4oCD0TWgA==", - "dev": true, - "requires": { - "hoek": "5.x.x" - } - }, "w3c-hr-time": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/w3c-hr-time/-/w3c-hr-time-1.0.1.tgz", @@ -12729,16 +12776,6 @@ "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true }, - "wreck": { - "version": "14.1.0", - "resolved": "https://registry.npmjs.org/wreck/-/wreck-14.1.0.tgz", - "integrity": "sha512-y/iwFhwdGoM8Hk1t1I4LbuLhM3curVD8STd5NcFI0c/4b4cQAMLcnCRxXX9sLQAggDC8dXYSaQNsT64hga6lvA==", - "dev": true, - "requires": { - "boom": "7.x.x", - "hoek": "5.x.x" - } - }, "write-file-atomic": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.3.0.tgz", From 72b956ca95f1f806258a2b6b4c300fbb68cee2e6 Mon Sep 17 00:00:00 2001 From: Jake Date: Mon, 5 Nov 2018 08:23:00 -0800 Subject: [PATCH 11/14] remove context mock --- .../src/__tests__/createTestClient.test.ts | 9 +-------- packages/apollo-server-testing/src/createTestClient.ts | 6 +----- 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts b/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts index dd43ce24f6b..e3fd1c7e06d 100644 --- a/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts +++ b/packages/apollo-server-testing/src/__tests__/createTestClient.test.ts @@ -53,20 +53,13 @@ describe('createTestClient', () => { expect(res.data).toEqual({ test: 'wow' }); }); - it('uses default context function if not overwritten', async () => { + it('resolves with context', async () => { const query = `{ hello }`; const client = createTestClient(myTestServer); const res = await client.query({ query }); expect(res.data).toEqual({ hello: 'hello tom' }); }); - it('allows mocking of context', async () => { - const query = `{ hello }`; - const client = createTestClient(myTestServer, () => ({ person: 'mary' })); - const res = await client.query({ query }); - expect(res.data).toEqual({ hello: 'hello mary' }); - }); - it('allows query documents as input', async () => { const query = gql` { diff --git a/packages/apollo-server-testing/src/createTestClient.ts b/packages/apollo-server-testing/src/createTestClient.ts index 136bfca27bc..835e01a3ba5 100644 --- a/packages/apollo-server-testing/src/createTestClient.ts +++ b/packages/apollo-server-testing/src/createTestClient.ts @@ -1,11 +1,7 @@ import { ApolloServerBase } from 'apollo-server-core'; import { print } from 'graphql'; -export default (server: ApolloServerBase, ctxFn: (...args: any[]) => any) => { - // if a context fn is required, overwrite the old one - // allows easy mocking of the context - if (ctxFn) server.context = ctxFn; - +export default (server: ApolloServerBase) => { const executeOperation = server.executeOperation.bind(server); const test = ({ query, mutation, ...rest }) => { const operation = query || mutation; From 9af76f985a5e6535679d4d3e547908c0b73a7308 Mon Sep 17 00:00:00 2001 From: Jake Date: Mon, 5 Nov 2018 08:41:28 -0800 Subject: [PATCH 12/14] updated types --- package-lock.json | 6 ++++++ packages/apollo-server-core/src/ApolloServer.ts | 5 ++--- .../apollo-server-testing/src/createTestClient.ts | 11 +++++++++-- 3 files changed, 17 insertions(+), 5 deletions(-) diff --git a/package-lock.json b/package-lock.json index a5be2d97812..ea6c5e67cb2 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2264,6 +2264,12 @@ "apollo-server-plugin-base": { "version": "file:packages/apollo-server-plugin-base" }, + "apollo-server-testing": { + "version": "file:packages/apollo-server-testing", + "requires": { + "apollo-server-core": "file:packages/apollo-server-core" + } + }, "apollo-tracing": { "version": "file:packages/apollo-tracing", "requires": { diff --git a/packages/apollo-server-core/src/ApolloServer.ts b/packages/apollo-server-core/src/ApolloServer.ts index 7be54d921fe..34d36618f26 100644 --- a/packages/apollo-server-core/src/ApolloServer.ts +++ b/packages/apollo-server-core/src/ApolloServer.ts @@ -511,13 +511,12 @@ export class ApolloServerBase { } public async executeOperation( - request: GraphQLRequest, - contextArgs: Record, + request: GraphQLRequest ) { let options; try { - options = await this.graphQLServerOptions(contextArgs); + options = await this.graphQLServerOptions(); } catch (e) { e.message = `Invalid options provided to ApolloServer: ${e.message}`; throw new Error(e); diff --git a/packages/apollo-server-testing/src/createTestClient.ts b/packages/apollo-server-testing/src/createTestClient.ts index 835e01a3ba5..d74a735d006 100644 --- a/packages/apollo-server-testing/src/createTestClient.ts +++ b/packages/apollo-server-testing/src/createTestClient.ts @@ -1,9 +1,16 @@ import { ApolloServerBase } from 'apollo-server-core'; -import { print } from 'graphql'; +import { print, DocumentNode } from 'graphql'; export default (server: ApolloServerBase) => { const executeOperation = server.executeOperation.bind(server); - const test = ({ query, mutation, ...rest }) => { + const test = ({ + query, + mutation, + ...rest + }: { + query: string | DocumentNode; + mutation: string | DocumentNode; + }) => { const operation = query || mutation; return executeOperation({ // Convert ASTs, which are produced by `graphql-tag` but not currently From 26780e4a299bedd059d63f6ac711318c8c3e91ec Mon Sep 17 00:00:00 2001 From: Jake Date: Mon, 5 Nov 2018 08:44:34 -0800 Subject: [PATCH 13/14] fix prettier errors --- packages/apollo-server-core/src/ApolloServer.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/apollo-server-core/src/ApolloServer.ts b/packages/apollo-server-core/src/ApolloServer.ts index 34d36618f26..ec8bad60913 100644 --- a/packages/apollo-server-core/src/ApolloServer.ts +++ b/packages/apollo-server-core/src/ApolloServer.ts @@ -510,9 +510,7 @@ export class ApolloServerBase { } as GraphQLOptions; } - public async executeOperation( - request: GraphQLRequest - ) { + public async executeOperation(request: GraphQLRequest) { let options; try { From 8f7b6629c8d2bfcc41afe883b220c2ff70521586 Mon Sep 17 00:00:00 2001 From: Jesse Rosenberger Date: Mon, 5 Nov 2018 11:07:40 -0800 Subject: [PATCH 14/14] Either `query` or `mutation` must be passed, but not both. Couldn't actually figure out the right typing here, but the type assertion should do the trick. --- .../src/createTestClient.ts | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/packages/apollo-server-testing/src/createTestClient.ts b/packages/apollo-server-testing/src/createTestClient.ts index d74a735d006..15c82a18170 100644 --- a/packages/apollo-server-testing/src/createTestClient.ts +++ b/packages/apollo-server-testing/src/createTestClient.ts @@ -1,22 +1,26 @@ import { ApolloServerBase } from 'apollo-server-core'; import { print, DocumentNode } from 'graphql'; +type StringOrAst = string | DocumentNode; +interface QueryOrMutation { + query?: StringOrAst; + mutation?: StringOrAst; +} + export default (server: ApolloServerBase) => { const executeOperation = server.executeOperation.bind(server); - const test = ({ - query, - mutation, - ...rest - }: { - query: string | DocumentNode; - mutation: string | DocumentNode; - }) => { + const test = ({ query, mutation, ...args }: QueryOrMutation) => { const operation = query || mutation; + + if ((!query && !mutation) || (query && mutation)) { + throw new Error('Either `query` or `mutation` must be passed'); + } + return executeOperation({ // Convert ASTs, which are produced by `graphql-tag` but not currently // used by `executeOperation`, to a String using `graphql/language/print`. query: typeof operation === 'string' ? operation : print(operation), - ...rest, + ...args, }); };