From d4ce1ef80baac3e91f7e3864e5b920f812909c85 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Fri, 12 Apr 2019 16:00:44 +0200 Subject: [PATCH 01/82] Localized HC link on Login page --- webapp/locales/de.json | 1 + webapp/locales/en.json | 1 + webapp/pages/login.vue | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/webapp/locales/de.json b/webapp/locales/de.json index 6e47d7122..ef9600c0e 100644 --- a/webapp/locales/de.json +++ b/webapp/locales/de.json @@ -6,6 +6,7 @@ "email": "Deine E-Mail", "password": "Dein Passwort", "moreInfo": "Was ist Human Connection?", + "moreInfoHint": "zur Präsentationsseite", "hello": "Hallo" }, "profile": { diff --git a/webapp/locales/en.json b/webapp/locales/en.json index 62c8f3e19..7c0b747c8 100644 --- a/webapp/locales/en.json +++ b/webapp/locales/en.json @@ -6,6 +6,7 @@ "email": "Your Email", "password": "Your Password", "moreInfo": "What is Human Connection?", + "moreInfoHint": "to the presentation page", "hello": "Hello" }, "profile": { diff --git a/webapp/pages/login.vue b/webapp/pages/login.vue index 846191c40..be2215fab 100644 --- a/webapp/pages/login.vue +++ b/webapp/pages/login.vue @@ -80,7 +80,7 @@ {{ $t('login.moreInfo') }} From 26be224464771b835fe062f9e3eddc0119d82f55 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Fri, 12 Apr 2019 16:08:39 +0200 Subject: [PATCH 02/82] Localised HC URL on Login page --- webapp/locales/de.json | 1 + webapp/locales/en.json | 1 + webapp/pages/login.vue | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/webapp/locales/de.json b/webapp/locales/de.json index ef9600c0e..43885ea17 100644 --- a/webapp/locales/de.json +++ b/webapp/locales/de.json @@ -6,6 +6,7 @@ "email": "Deine E-Mail", "password": "Dein Passwort", "moreInfo": "Was ist Human Connection?", + "moreInfoURL": "https://human-connection.org", "moreInfoHint": "zur Präsentationsseite", "hello": "Hallo" }, diff --git a/webapp/locales/en.json b/webapp/locales/en.json index 7c0b747c8..9ea58225f 100644 --- a/webapp/locales/en.json +++ b/webapp/locales/en.json @@ -6,6 +6,7 @@ "email": "Your Email", "password": "Your Password", "moreInfo": "What is Human Connection?", + "moreInfoURL": "https://human-connection.org/en/", "moreInfoHint": "to the presentation page", "hello": "Hello" }, diff --git a/webapp/pages/login.vue b/webapp/pages/login.vue index be2215fab..92269143b 100644 --- a/webapp/pages/login.vue +++ b/webapp/pages/login.vue @@ -79,7 +79,7 @@ From 7b1be0cb7d6b4c17d6c330b5537f98bd9e8d0a51 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Thu, 25 Apr 2019 17:17:12 -0300 Subject: [PATCH 03/82] Add test coverage --- .gitignore | 1 + backend/package.json | 2 ++ package.json | 4 ++- webapp/package.json | 2 ++ yarn.lock | 70 ++++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 78 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 07094a43b..07623b965 100644 --- a/.gitignore +++ b/.gitignore @@ -16,3 +16,4 @@ cypress/screenshots/ cypress.env.json !.gitkeep +**/coverage diff --git a/backend/package.json b/backend/package.json index a258b1f27..b9660315b 100644 --- a/backend/package.json +++ b/backend/package.json @@ -26,6 +26,8 @@ "license": "MIT", "jest": { "verbose": true, + "collectCoverage": true, + "coverageReporters": ["text", "lcov"], "testMatch": [ "**/src/**/?(*.)+(spec|test).js?(x)" ] diff --git a/package.json b/package.json index 703997ee1..ec511da35 100644 --- a/package.json +++ b/package.json @@ -15,9 +15,11 @@ "cypress:webapp": "cd webapp && cross-env GRAPHQL_URI=http://localhost:4123 yarn run dev", "cypress:setup": "run-p cypress:backend:* cypress:webapp", "cypress:run": "cypress run --browser chromium", - "cypress:open": "cypress open --browser chromium" + "cypress:open": "cypress open --browser chromium", + "test:jest": "cd webapp && yarn test && cd ../backend && yarn test:jest && codecov" }, "devDependencies": { + "codecov": "^3.3.0", "cross-env": "^5.2.0", "cypress": "^3.2.0", "cypress-cucumber-preprocessor": "^1.11.0", diff --git a/webapp/package.json b/webapp/package.json index 80a0ff427..dd649c10e 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -17,6 +17,8 @@ }, "jest": { "verbose": true, + "collectCoverage": true, + "coverageReporters": ["text", "lcov"], "moduleFileExtensions": [ "js", "json", diff --git a/yarn.lock b/yarn.lock index 1d7745f03..a1f294474 100644 --- a/yarn.lock +++ b/yarn.lock @@ -762,6 +762,13 @@ acorn@^6.0.2: resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.1.1.tgz#7d25ae05bb8ad1f9b699108e1094ecd7884adc1f" integrity sha512-jPTiwtOxaHNaAPg/dmrJ/beuzLRnXtB0kQPQ8JpotKJgTB6rX6c8mlf315941pyjBSaPg8NHXS9fhP4u17DpGA== +agent-base@^4.1.0: + version "4.2.1" + resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-4.2.1.tgz#d89e5999f797875674c07d87f260fc41e83e8ca9" + integrity sha512-JVwXMr9nHYTUXsBFKUqhJwvlcYU/blreOEUkhNR2eXZIvwd+c+o5V4MgDPKWnMS/56awN3TRzIP+KoPn+roQtg== + dependencies: + es6-promisify "^5.0.0" + ajv@^6.5.5: version "6.10.0" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.0.tgz#90d0d54439da587cd7e843bfb7045f50bd22bdf1" @@ -840,6 +847,11 @@ argparse@^1.0.7: dependencies: sprintf-js "~1.0.2" +argv@^0.0.2: + version "0.0.2" + resolved "https://registry.yarnpkg.com/argv/-/argv-0.0.2.tgz#ecbd16f8949b157183711b1bda334f37840185ab" + integrity sha1-7L0W+JSbFXGDcRsb2jNPN4QBhas= + arr-diff@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-2.0.0.tgz#8f3b827f955a8bd669697e4a4256ac3ceae356cf" @@ -1491,6 +1503,17 @@ code-point-at@^1.0.0: resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= +codecov@^3.3.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/codecov/-/codecov-3.3.0.tgz#7bf337b3f7b0474606b5c31c56dd9e44e395e15d" + integrity sha512-S70c3Eg9SixumOvxaKE/yKUxb9ihu/uebD9iPO2IR73IdP4i6ZzjXEULj3d0HeyWPr0DqBfDkjNBWxURjVO5hw== + dependencies: + argv "^0.0.2" + ignore-walk "^3.0.1" + js-yaml "^3.12.0" + teeny-request "^3.7.0" + urlgrey "^0.4.4" + coffee-react-transform@^3.1.0: version "3.3.0" resolved "https://registry.yarnpkg.com/coffee-react-transform/-/coffee-react-transform-3.3.0.tgz#f1f90fa22de8d767fca2793e3b70f0f7d7a2e467" @@ -2103,6 +2126,18 @@ es6-iterator@~2.0.3: es5-ext "^0.10.35" es6-symbol "^3.1.1" +es6-promise@^4.0.3: + version "4.2.6" + resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.6.tgz#b685edd8258886365ea62b57d30de28fadcd974f" + integrity sha512-aRVgGdnmW2OiySVPUC9e6m+plolMAJKjZnQlCwNSuK5yQ0JN61DZSO1X1Ufd1foqWRAlig0rhduTCHe7sVtK5Q== + +es6-promisify@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/es6-promisify/-/es6-promisify-5.0.0.tgz#5109d62f3e56ea967c4b63505aef08291c8a5203" + integrity sha1-UQnWLz5W6pZ8S2NQWu8IKRyKUgM= + dependencies: + es6-promise "^4.0.3" + es6-symbol@^3.1.1, es6-symbol@~3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.1.tgz#bf00ef4fdab6ba1b46ecb7b629b4c7ed5715cc77" @@ -2632,6 +2667,14 @@ https-browserify@^1.0.0: resolved "https://registry.yarnpkg.com/https-browserify/-/https-browserify-1.0.0.tgz#ec06c10e0a34c0f2faf199f7fd7fc78fffd03c73" integrity sha1-7AbBDgo0wPL68Zn3/X/Hj//QPHM= +https-proxy-agent@^2.2.1: + version "2.2.1" + resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-2.2.1.tgz#51552970fa04d723e04c56d04178c3f92592bbc0" + integrity sha512-HPCTS1LW51bcyMYbxUIOO4HEOlQ1/1qRaFWcyxvwaqUS9TY88aoEuHUY33kuAh1YhVVaDQhLZsnPd+XNARWZlQ== + dependencies: + agent-base "^4.1.0" + debug "^3.1.0" + iconv-lite@^0.4.4: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" @@ -3007,6 +3050,14 @@ js-levenshtein@^1.1.3: resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== +js-yaml@^3.12.0: + version "3.13.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" + integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + js-yaml@^3.9.0: version "3.13.0" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.0.tgz#38ee7178ac0eea2c97ff6d96fff4b18c7d8cf98e" @@ -3509,6 +3560,11 @@ node-fetch@2.1.2: resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.1.2.tgz#ab884e8e7e57e38a944753cec706f788d1768bb5" integrity sha1-q4hOjn5X44qUR1POxwb3iNF2i7U= +node-fetch@^2.2.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.3.0.tgz#1a1d940bbfb916a1d3e0219f037e89e71f8c5fa5" + integrity sha512-MOd8pV3fxENbryESLgVIeaGKrdl+uaYhCSSVkjeOb/31/njTpcis5aWfdqgNlHIrKOLRbMnfPINPOML2CIFeXA== + node-pre-gyp@^0.10.0: version "0.10.3" resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.10.3.tgz#3070040716afdc778747b61b6887bf78880b80fc" @@ -4621,6 +4677,15 @@ tar@^4: safe-buffer "^5.1.2" yallist "^3.0.2" +teeny-request@^3.7.0: + version "3.11.3" + resolved "https://registry.yarnpkg.com/teeny-request/-/teeny-request-3.11.3.tgz#335c629f7645e5d6599362df2f3230c4cbc23a55" + integrity sha512-CKncqSF7sH6p4rzCgkb/z/Pcos5efl0DmolzvlqRQUNcpRIruOhY9+T1FsIlyEbfWd7MsFpodROOwHYh2BaXzw== + dependencies: + https-proxy-agent "^2.2.1" + node-fetch "^2.2.0" + uuid "^3.3.2" + text-encoding@^0.6.4: version "0.6.4" resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" @@ -4847,6 +4912,11 @@ url@0.11.0, url@~0.11.0: punycode "1.3.2" querystring "0.2.0" +urlgrey@^0.4.4: + version "0.4.4" + resolved "https://registry.yarnpkg.com/urlgrey/-/urlgrey-0.4.4.tgz#892fe95960805e85519f1cd4389f2cb4cbb7652f" + integrity sha1-iS/pWWCAXoVRnxzUOJ8stMu3ZS8= + use@^3.1.0: version "3.1.1" resolved "https://registry.yarnpkg.com/use/-/use-3.1.1.tgz#d50c8cac79a19fbc20f2911f56eb973f4e10070f" From 06650de30f62e813e1b5ab6e2f6aa7be7caf918e Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Thu, 25 Apr 2019 18:05:49 -0300 Subject: [PATCH 04/82] Update travis to run codecov --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index cd43b771f..9e983ec76 100644 --- a/.travis.yml +++ b/.travis.yml @@ -31,6 +31,7 @@ script: - yarn run cypress:run after_success: + - codecov --token=$CODECOV_TOKEN - wget https://raw.githubusercontent.com/DiscordHooks/travis-ci-discord-webhook/master/send.sh - chmod +x send.sh - ./send.sh success $WEBHOOK_URL From f72a6e8a42dc69a6fa5f95839dc4151b54a41b78 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Thu, 25 Apr 2019 18:37:03 -0300 Subject: [PATCH 05/82] Add codecov globally in travis.yml, add badge --- .travis.yml | 1 + README.md | 1 + 2 files changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index 9e983ec76..7f1f8ccfc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,6 +10,7 @@ addons: before_install: - yarn global add wait-on + - yarn global add codecov - yarn install - cp cypress.env.template.json cypress.env.json diff --git a/README.md b/README.md index 3f92be96d..ac7d2a024 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,7 @@ # Human-Connection [![Build Status](https://travis-ci.com/Human-Connection/Human-Connection.svg?branch=master)](https://travis-ci.com/Human-Connection/Human-Connection) +[![Codecov Coverage](https://img.shields.io/codecov/c/github/Human-Connection/Human-Connection/master.svg?style=flat-square)](https://codecov.io/gh/Human-Connection/Human-Connection/) [![MIT License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/Human-Connection/Nitro-Backend/blob/backend/LICENSE.md) [![Discord Channel](https://img.shields.io/discord/489522408076738561.svg)](https://discord.gg/6ub73U3) From 341e4b9c9f29be3fd0c217d9b46a88b5ee3c3e3c Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Thu, 25 Apr 2019 19:09:31 -0300 Subject: [PATCH 06/82] Remove codecov from .travis.yml - errored out when running the latest, but was adding coverage previously --- .travis.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 7f1f8ccfc..cd43b771f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,7 +10,6 @@ addons: before_install: - yarn global add wait-on - - yarn global add codecov - yarn install - cp cypress.env.template.json cypress.env.json @@ -32,7 +31,6 @@ script: - yarn run cypress:run after_success: - - codecov --token=$CODECOV_TOKEN - wget https://raw.githubusercontent.com/DiscordHooks/travis-ci-discord-webhook/master/send.sh - chmod +x send.sh - ./send.sh success $WEBHOOK_URL From b8e17fa321b4208af4213aaa0aece3abe9498cbf Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Sat, 27 Apr 2019 13:45:37 -0300 Subject: [PATCH 07/82] Rerun moderation/report tests on failure - intermittent failing test --- cypress/integration/common/report.js | 2 ++ package.json | 1 + yarn.lock | 5 +++++ 3 files changed, 8 insertions(+) diff --git a/cypress/integration/common/report.js b/cypress/integration/common/report.js index 78abf5378..fb4eb4794 100644 --- a/cypress/integration/common/report.js +++ b/cypress/integration/common/report.js @@ -1,4 +1,6 @@ import { Given, When, Then } from 'cypress-cucumber-preprocessor/steps' +// intermittent failing tests +Cypress.env('RETRIES', 2) /* global cy */ diff --git a/package.json b/package.json index 703997ee1..56bed0c01 100644 --- a/package.json +++ b/package.json @@ -21,6 +21,7 @@ "cross-env": "^5.2.0", "cypress": "^3.2.0", "cypress-cucumber-preprocessor": "^1.11.0", + "cypress-plugin-retries": "^1.2.0", "dotenv": "^7.0.0", "faker": "^4.1.0", "graphql-request": "^1.8.2", diff --git a/yarn.lock b/yarn.lock index 1d7745f03..ba9e54364 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1787,6 +1787,11 @@ cypress-cucumber-preprocessor@^1.11.0: glob "^7.1.2" through "^2.3.8" +cypress-plugin-retries@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/cypress-plugin-retries/-/cypress-plugin-retries-1.2.0.tgz#a4e120c1bc417d1be525632e7d38e52a87bc0578" + integrity sha512-seQFI/0j5WCqX7IVN2k0tbd3FLdhbPuSCWdDtdzDmU9oJfUkRUlluV47TYD+qQ/l+fJYkQkpw8csLg8/LohfRg== + cypress@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/cypress/-/cypress-3.2.0.tgz#c2d5befd5077dab6fb52ad70721e0868ac057001" From b7b9f8c46459c59fc1f432104db26247bd0dfa6d Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Sat, 27 Apr 2019 15:24:39 -0300 Subject: [PATCH 08/82] Require cypress plugin retries --- cypress/cypress/support/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cypress/cypress/support/index.js b/cypress/cypress/support/index.js index d68db96df..a24e4442d 100644 --- a/cypress/cypress/support/index.js +++ b/cypress/cypress/support/index.js @@ -15,6 +15,6 @@ // Import commands.js using ES2015 syntax: import './commands' - +require('cypress-plugin-retries') // Alternatively you can use CommonJS syntax: // require('./commands') From 2fa06356586b8ed1656c37763edf9f568fee54eb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 30 Apr 2019 11:28:54 +0000 Subject: [PATCH 09/82] Bump neo4j from 3.5.4 to 3.5.5 in /neo4j Bumps neo4j from 3.5.4 to 3.5.5. Signed-off-by: dependabot[bot] --- neo4j/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/neo4j/Dockerfile b/neo4j/Dockerfile index a02d41f38..e94a89431 100644 --- a/neo4j/Dockerfile +++ b/neo4j/Dockerfile @@ -1,3 +1,3 @@ -FROM neo4j:3.5.4 +FROM neo4j:3.5.5 RUN wget https://github.com/neo4j-contrib/neo4j-apoc-procedures/releases/download/3.5.0.1/apoc-3.5.0.1-all.jar -P plugins/ COPY migrate.sh /usr/local/bin/migrate From 497f77ae10c1ac502cf2715b180ea4944b294746 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Wed, 1 May 2019 12:25:28 +0200 Subject: [PATCH 10/82] Breakthrough! Use split+indices for performance @appinteractive thanks for pointing out `split`. You just saved me some days of work to refactor the import statements to use CSV instead of JSON files. @Tirokk when I enter `:schema` in Neo4J web UI, I see the following: ``` :schema Indexes ON :Badge(id) ONLINE ON :Category(id) ONLINE ON :Comment(id) ONLINE ON :Post(id) ONLINE ON :Tag(id) ONLINE ON :User(id) ONLINE No constraints ``` So I temporarily removed the unique constraints on `slug` and added plain indices on `id` for all relevant node types. We cannot omit the `:Label` unfortunately, neo4j does not allow this. So I had to add all indices for all known node labels instead. With indices the import finishes in: ``` Time elapsed: 351 seconds ``` :tada: @appinteractive when I keep the unique indices on slug, I get an error during import that a node with label `:User` and slug `tobias` already exists. Ie. we have unqiue constraint violations in our production data. @mattwr18 @ulfgebhardt @ogerly I started the application on my machine on the production data and it turns out that the index page http://localhost:3000/ takes way to long. Visiting my profile page at http://localhost:3000/profile/5b1693daf850c11207fa6109/robert-schafer is fine, though. Even pagination works. When I visit a post page with not too many comments, the application is fast enough, too: http://localhost:3000/post/5bbf49ebc428ea001c7ca89c/neues-video-format-human-connection-tech-news --- .../maintenance-worker/migration/mongo/import.sh | 7 ++++--- .../maintenance-worker/migration/neo4j/badges.cql | 2 +- .../maintenance-worker/migration/neo4j/categories.cql | 2 +- .../maintenance-worker/migration/neo4j/comments.cql | 3 ++- .../migration/neo4j/contributions.cql | 2 +- .../maintenance-worker/migration/neo4j/follows.cql | 2 +- .../maintenance-worker/migration/neo4j/import.sh | 11 +++++++++-- .../maintenance-worker/migration/neo4j/shouts.cql | 2 +- .../maintenance-worker/migration/neo4j/users.cql | 2 +- 9 files changed, 21 insertions(+), 12 deletions(-) diff --git a/deployment/legacy-migration/maintenance-worker/migration/mongo/import.sh b/deployment/legacy-migration/maintenance-worker/migration/mongo/import.sh index 328560bfc..8958dd2a8 100755 --- a/deployment/legacy-migration/maintenance-worker/migration/mongo/import.sh +++ b/deployment/legacy-migration/maintenance-worker/migration/mongo/import.sh @@ -9,16 +9,17 @@ echo "MONGODB_DATABASE ${MONGODB_DATABASE}" echo "MONGODB_AUTH_DB ${MONGODB_AUTH_DB}" echo "-------------------------------------------------" -[ -z "$SSH_PRIVATE_KEY" ] || create_private_ssh_key_from_env rm -rf /tmp/mongo-export/* -mkdir -p /tmp/mongo-export +mkdir -p /tmp/mongo-export/ ssh -4 -M -S my-ctrl-socket -fnNT -L 27018:localhost:27017 -l ${SSH_USERNAME} ${SSH_HOST} for collection in "categories" "badges" "users" "contributions" "comments" "follows" "shouts" do - mongoexport --host localhost -d ${MONGODB_DATABASE} --port 27018 --username ${MONGODB_USERNAME} --password ${MONGODB_PASSWORD} --authenticationDatabase ${MONGODB_AUTH_DB} --db ${MONGODB_DATABASE} --collection $collection --out "/tmp/mongo-export/$collection.json" + mongoexport --db ${MONGODB_DATABASE} --host localhost -d ${MONGODB_DATABASE} --port 27018 --username ${MONGODB_USERNAME} --password ${MONGODB_PASSWORD} --authenticationDatabase ${MONGODB_AUTH_DB} --collection $collection --collection $collection --out "/tmp/mongo-export/$collection.json" + mkdir -p /tmp/mongo-export/splits/$collection/ + split -l 500 /tmp/mongo-export/$collection.json /tmp/mongo-export/splits/$collection/ done ssh -S my-ctrl-socket -O check -l ${SSH_USERNAME} ${SSH_HOST} diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/badges.cql b/deployment/legacy-migration/maintenance-worker/migration/neo4j/badges.cql index f4bf67dda..6b6a09592 100644 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/badges.cql +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/badges.cql @@ -1,4 +1,4 @@ -CALL apoc.load.json('file:/tmp/mongo-export/badges.json') YIELD value as badge +CALL apoc.load.json('file:/tmp/mongo-export/splits/current-chunk.json') YIELD value as badge MERGE(b:Badge {id: badge._id["$oid"]}) ON CREATE SET b.key = badge.key, diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/categories.cql b/deployment/legacy-migration/maintenance-worker/migration/neo4j/categories.cql index c22354cbe..776811bec 100644 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/categories.cql +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/categories.cql @@ -1,4 +1,4 @@ -CALL apoc.load.json('file:/tmp/mongo-export/categories.json') YIELD value as category +CALL apoc.load.json('file:/tmp/mongo-export/splits/current-chunk.json') YIELD value as category MERGE(c:Category {id: category._id["$oid"]}) ON CREATE SET c.name = category.title, diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/comments.cql b/deployment/legacy-migration/maintenance-worker/migration/neo4j/comments.cql index eb645108a..234d29d26 100644 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/comments.cql +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/comments.cql @@ -1,4 +1,5 @@ -CALL apoc.load.json('file:/tmp/mongo-export/comments.json') YIELD value as json +CALL apoc.load.json('file:/tmp/mongo-export/splits/current-chunk.json') YIELD value as json + MERGE (comment:Comment {id: json._id["$oid"]}) ON CREATE SET comment.content = json.content, diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/contributions.cql b/deployment/legacy-migration/maintenance-worker/migration/neo4j/contributions.cql index 134c276cf..01647f7fb 100644 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/contributions.cql +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/contributions.cql @@ -1,4 +1,4 @@ -CALL apoc.load.json('file:/tmp/mongo-export/contributions.json') YIELD value as post +CALL apoc.load.json('file:/tmp/mongo-export/splits/current-chunk.json') YIELD value as post MERGE (p:Post {id: post._id["$oid"]}) ON CREATE SET p.title = post.title, diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/follows.cql b/deployment/legacy-migration/maintenance-worker/migration/neo4j/follows.cql index 6f5416723..0cd6d9cfc 100644 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/follows.cql +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/follows.cql @@ -1,4 +1,4 @@ -CALL apoc.load.json('file:/tmp/mongo-export/follows.json') YIELD value as follow +CALL apoc.load.json('file:/tmp/mongo-export/splits/current-chunk.json') YIELD value as follow MATCH (u1:User {id: follow.userId}), (u2:User {id: follow.foreignId}) MERGE (u1)-[:FOLLOWS]->(u2) ; diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/import.sh b/deployment/legacy-migration/maintenance-worker/migration/neo4j/import.sh index 6f539c501..ed033c1b9 100755 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/import.sh +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/import.sh @@ -2,8 +2,15 @@ set -e SCRIPT_DIRECTORY="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" -echo "MATCH (n) OPTIONAL MATCH (n)-[r]-() DELETE n,r;" | cypher-shell -a $NEO4J_URI +echo "MATCH (n) DETACH DELETE n;" | cypher-shell + +SECONDS=0 for collection in "badges" "categories" "users" "follows" "contributions" "shouts" "comments" do - echo "Import ${collection}..." && cypher-shell -a $NEO4J_URI < $SCRIPT_DIRECTORY/$collection.cql + for chunk in /tmp/mongo-export/splits/$collection/* + do + mv $chunk /tmp/mongo-export/splits/current-chunk.json + echo "Import ${chunk}" && cypher-shell < $SCRIPT_DIRECTORY/$collection.cql + done done +echo "Time elapsed: $SECONDS seconds" diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/shouts.cql b/deployment/legacy-migration/maintenance-worker/migration/neo4j/shouts.cql index cd72ab66b..5019cdc32 100644 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/shouts.cql +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/shouts.cql @@ -1,4 +1,4 @@ -CALL apoc.load.json('file:/tmp/mongo-export/shouts.json') YIELD value as shout +CALL apoc.load.json('file:/tmp/mongo-export/splits/current-chunk.json') YIELD value as shout MATCH (u:User {id: shout.userId}), (p:Post {id: shout.foreignId}) MERGE (u)-[:SHOUTED]->(p) ; diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/users.cql b/deployment/legacy-migration/maintenance-worker/migration/neo4j/users.cql index 22eb46882..c877f8377 100644 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/users.cql +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/users.cql @@ -1,4 +1,4 @@ -CALL apoc.load.json('file:/tmp/mongo-export/users.json') YIELD value as user +CALL apoc.load.json('file:/tmp/mongo-export/splits/current-chunk.json') YIELD value as user MERGE(u:User {id: user._id["$oid"]}) ON CREATE SET u.name = user.name, From 4f0ded1ff000b982515db332b174aadcaacfd3d7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Thu, 2 May 2019 04:50:47 +0000 Subject: [PATCH 11/82] Bump nodemon from 1.18.11 to 1.19.0 in /webapp Bumps [nodemon](https://github.com/remy/nodemon) from 1.18.11 to 1.19.0. - [Release notes](https://github.com/remy/nodemon/releases) - [Commits](https://github.com/remy/nodemon/compare/v1.18.11...v1.19.0) Signed-off-by: dependabot[bot] --- webapp/package.json | 2 +- webapp/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/webapp/package.json b/webapp/package.json index c0ae69579..a5c54c605 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -77,7 +77,7 @@ "fuse.js": "^3.4.4", "jest": "~24.7.1", "node-sass": "~4.11.0", - "nodemon": "~1.18.11", + "nodemon": "~1.19.0", "prettier": "~1.14.3", "sass-loader": "~7.1.0", "tippy.js": "^4.3.0", diff --git a/webapp/yarn.lock b/webapp/yarn.lock index 7f0d207f2..8323c3744 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -7444,10 +7444,10 @@ node-sass@~4.11.0: stdout-stream "^1.4.0" "true-case-path" "^1.0.2" -nodemon@^1.18.9, nodemon@~1.18.11: - version "1.18.11" - resolved "https://registry.yarnpkg.com/nodemon/-/nodemon-1.18.11.tgz#d836ab663776e7995570b963da5bfc807e53f6b8" - integrity sha512-KdN3tm1zkarlqNo4+W9raU3ihM4H15MVMSE/f9rYDZmFgDHAfAJsomYrHhApAkuUemYjFyEeXlpCOQ2v5gtBEw== +nodemon@^1.18.9, nodemon@~1.19.0: + version "1.19.0" + resolved "https://registry.yarnpkg.com/nodemon/-/nodemon-1.19.0.tgz#358e005549a1e9e1148cb2b9b8b28957dc4e4527" + integrity sha512-NHKpb/Je0Urmwi3QPDHlYuFY9m1vaVfTsRZG5X73rY46xPj0JpNe8WhUGQdkDXQDOxrBNIU3JrcflE9Y44EcuA== dependencies: chokidar "^2.1.5" debug "^3.1.0" From 57dfd6fb66b48f7616bf71f27897f4722a3b9c7a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Thu, 2 May 2019 04:50:59 +0000 Subject: [PATCH 12/82] Bump nodemon from 1.18.11 to 1.19.0 in /backend Bumps [nodemon](https://github.com/remy/nodemon) from 1.18.11 to 1.19.0. - [Release notes](https://github.com/remy/nodemon/releases) - [Commits](https://github.com/remy/nodemon/compare/v1.18.11...v1.19.0) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/backend/package.json b/backend/package.json index 7e972d0e6..8c071f260 100644 --- a/backend/package.json +++ b/backend/package.json @@ -91,7 +91,7 @@ "eslint-plugin-standard": "~4.0.0", "graphql-request": "~1.8.2", "jest": "~24.7.1", - "nodemon": "~1.18.11", + "nodemon": "~1.19.0", "supertest": "~4.0.2" } } diff --git a/backend/yarn.lock b/backend/yarn.lock index fab84f08e..47b7f6531 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -5687,10 +5687,10 @@ node-releases@^1.1.13: dependencies: semver "^5.3.0" -nodemon@~1.18.11: - version "1.18.11" - resolved "https://registry.yarnpkg.com/nodemon/-/nodemon-1.18.11.tgz#d836ab663776e7995570b963da5bfc807e53f6b8" - integrity sha512-KdN3tm1zkarlqNo4+W9raU3ihM4H15MVMSE/f9rYDZmFgDHAfAJsomYrHhApAkuUemYjFyEeXlpCOQ2v5gtBEw== +nodemon@~1.19.0: + version "1.19.0" + resolved "https://registry.yarnpkg.com/nodemon/-/nodemon-1.19.0.tgz#358e005549a1e9e1148cb2b9b8b28957dc4e4527" + integrity sha512-NHKpb/Je0Urmwi3QPDHlYuFY9m1vaVfTsRZG5X73rY46xPj0JpNe8WhUGQdkDXQDOxrBNIU3JrcflE9Y44EcuA== dependencies: chokidar "^2.1.5" debug "^3.1.0" From a4f5fdc3242515999c674358230156009fcf373b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Thu, 2 May 2019 07:22:32 +0200 Subject: [PATCH 13/82] Make SocialMedia Links to target="_blank" --- webapp/pages/settings/my-social-media.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/webapp/pages/settings/my-social-media.vue b/webapp/pages/settings/my-social-media.vue index c031f54a4..f1714655f 100644 --- a/webapp/pages/settings/my-social-media.vue +++ b/webapp/pages/settings/my-social-media.vue @@ -10,7 +10,10 @@ v-for="link in socialMediaLinks" :key="link.url" > - + Social Media link Date: Thu, 2 May 2019 17:41:54 +0200 Subject: [PATCH 14/82] First Vue design of delete SocialMedia, custom mutation DeleteSocialMedia Backend Jest tests for DeleteSocialMedia New backend Jest tests for CreateSocialMedia --- .../src/middleware/permissionsMiddleware.js | 1 + backend/src/resolvers/socialMedia.js | 8 +++ backend/src/resolvers/socialMedia.spec.js | 58 ++++++++++++++++++- webapp/pages/settings/my-social-media.vue | 49 +++++++++++----- 4 files changed, 99 insertions(+), 17 deletions(-) diff --git a/backend/src/middleware/permissionsMiddleware.js b/backend/src/middleware/permissionsMiddleware.js index 3688aec16..85c584407 100644 --- a/backend/src/middleware/permissionsMiddleware.js +++ b/backend/src/middleware/permissionsMiddleware.js @@ -75,6 +75,7 @@ const permissions = shield({ DeleteBadge: isAdmin, AddUserBadges: isAdmin, CreateSocialMedia: isAuthenticated, + DeleteSocialMedia: isAuthenticated, // AddBadgeRewarded: isAdmin, // RemoveBadgeRewarded: isAdmin, reward: isAdmin, diff --git a/backend/src/resolvers/socialMedia.js b/backend/src/resolvers/socialMedia.js index 310375820..ef143a478 100644 --- a/backend/src/resolvers/socialMedia.js +++ b/backend/src/resolvers/socialMedia.js @@ -3,6 +3,9 @@ import { neo4jgraphql } from 'neo4j-graphql-js' export default { Mutation: { CreateSocialMedia: async (object, params, context, resolveInfo) => { + /** + * TODO?: Creates double Nodes! + */ const socialMedia = await neo4jgraphql(object, params, context, resolveInfo, false) const session = context.driver.session() await session.run( @@ -15,6 +18,11 @@ export default { ) session.close() + return socialMedia + }, + DeleteSocialMedia: async (object, params, context, resolveInfo) => { + const socialMedia = await neo4jgraphql(object, params, context, resolveInfo, false) + return socialMedia } } diff --git a/backend/src/resolvers/socialMedia.spec.js b/backend/src/resolvers/socialMedia.spec.js index b97316543..b09dae178 100644 --- a/backend/src/resolvers/socialMedia.spec.js +++ b/backend/src/resolvers/socialMedia.spec.js @@ -7,9 +7,18 @@ const factory = Factory() describe('CreateSocialMedia', () => { let client let headers - const mutation = ` + const mutationC = ` mutation($url: String!) { CreateSocialMedia(url: $url) { + id + url + } + } + ` + const mutationD = ` + mutation($id: ID!) { + DeleteSocialMedia(id: $id) { + id url } } @@ -30,20 +39,63 @@ describe('CreateSocialMedia', () => { await factory.cleanDatabase() }) + describe('unauthenticated', () => { + it('throws authorization error', async () => { + client = new GraphQLClient(host) + const variables = { url: 'http://nsosp.org' } + await expect( + client.request(mutationC, variables) + ).rejects.toThrow('Not Authorised') + }) + }) + describe('authenticated', () => { beforeEach(async () => { headers = await login({ email: 'test@example.org', password: '1234' }) client = new GraphQLClient(host, { headers }) }) + it('creates social media with correct URL', async () => { + const variables = { url: 'http://nsosp.org' } + await expect( + client.request(mutationC, variables) + ).resolves.toEqual(expect.objectContaining({ + CreateSocialMedia: { + id: expect.any(String), + url: 'http://nsosp.org' + } + })) + }) + + it('deletes social media', async () => { + const variablesC = { url: 'http://nsosp.org' } + const { CreateSocialMedia } = await client.request(mutationC, variablesC) + const { id } = CreateSocialMedia + + const variablesD = { id } + const expected = { + DeleteSocialMedia: { + id: id, + url: 'http://nsosp.org' + } + } + await expect( + client.request(mutationD, variablesD) + ).resolves.toEqual(expected) + }) + it('rejects empty string', async () => { const variables = { url: '' } - await expect(client.request(mutation, variables)).rejects.toThrow('Input is not a URL') + await expect( + client.request(mutationC, variables) + ).rejects.toThrow('Input is not a URL') }) it('validates URLs', async () => { const variables = { url: 'not-a-url' } - await expect(client.request(mutation, variables)).rejects.toThrow('Input is not a URL') + await expect( + client.request(mutationC, variables) + ).rejects.toThrow('Input is not a URL') }) }) }) diff --git a/webapp/pages/settings/my-social-media.vue b/webapp/pages/settings/my-social-media.vue index f1714655f..425f4c726 100644 --- a/webapp/pages/settings/my-social-media.vue +++ b/webapp/pages/settings/my-social-media.vue @@ -22,26 +22,38 @@ > {{ link.url }} +    |    + + + + -
- -
- - {{ $t('settings.social-media.submit') }} - +
+ +
+ + {{ $t('settings.social-media.submit') }} + +
+
@@ -104,7 +116,16 @@ export default { this.$toast.success(this.$t('settings.social-media.success')), (this.value = '') ) + }, + onDelete(link) { + console.log(link) } } } + + From 3294cffa88bb150018b09fc2ba262f0283a3e322 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Thu, 2 May 2019 18:09:46 +0200 Subject: [PATCH 15/82] Renamed handleDeleteSocialMedia --- webapp/pages/settings/my-social-media.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/webapp/pages/settings/my-social-media.vue b/webapp/pages/settings/my-social-media.vue index 425f4c726..0eba9c3f0 100644 --- a/webapp/pages/settings/my-social-media.vue +++ b/webapp/pages/settings/my-social-media.vue @@ -28,7 +28,7 @@ class="layout-leave-active" /> @@ -117,7 +117,7 @@ export default { (this.value = '') ) }, - onDelete(link) { + handleDeleteSocialMedia(link) { console.log(link) } } From 154082a251a944633395594f326569de50191f15 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Thu, 2 May 2019 15:54:44 -0300 Subject: [PATCH 16/82] Add authorship to commments at creation - Co-authored-by: Mike Aono --- backend/src/resolvers/comments.js | 10 +++++++ backend/src/resolvers/comments.spec.js | 28 ++++++++++++++---- backend/src/seed/seed-db.js | 39 ++++++++------------------ 3 files changed, 45 insertions(+), 32 deletions(-) diff --git a/backend/src/resolvers/comments.js b/backend/src/resolvers/comments.js index 97b99f4ab..b2dc0fbcf 100644 --- a/backend/src/resolvers/comments.js +++ b/backend/src/resolvers/comments.js @@ -44,6 +44,16 @@ export default { commentId: comment.id } ) + + await session.run(` + MATCH (comment:Comment {id: $commentId}), (author:User {id: $userId}) + MERGE (comment)<-[:WROTE]-(author) + RETURN comment {.id, .content}`, { + commentId: comment.id, + userId: context.user.id + } + ) + session.close() return comment diff --git a/backend/src/resolvers/comments.spec.js b/backend/src/resolvers/comments.spec.js index 34a18d807..e572e206b 100644 --- a/backend/src/resolvers/comments.spec.js +++ b/backend/src/resolvers/comments.spec.js @@ -19,12 +19,12 @@ afterEach(async () => { describe('CreateComment', () => { const mutation = ` - mutation($postId: ID, $content: String!) { - CreateComment(postId: $postId, content: $content) { - id - content - } + mutation($postId: ID, $content: String!) { + CreateComment(postId: $postId, content: $content) { + id + content } + } ` describe('unauthenticated', () => { it('throws authorization error', async () => { @@ -58,6 +58,24 @@ describe('CreateComment', () => { await expect(client.request(mutation, variables)).resolves.toMatchObject(expected) }) + it('assigns the authenticated user as author', async () => { + variables = { + postId: 'p1', + content: 'I\'m authorised to comment' + } + await client.request(mutation, variables) + + const { User } = await client.request(`{ + User(email: "test@example.org") { + comments { + content + } + } + }`) + + expect(User).toEqual([ { comments: [ { content: 'I\'m authorised to comment' } ] } ]) + }) + it('throw an error if an empty string is sent as content', async () => { variables = { postId: 'p1', diff --git a/backend/src/seed/seed-db.js b/backend/src/seed/seed-db.js index f17c20315..8694a7948 100644 --- a/backend/src/seed/seed-db.js +++ b/backend/src/seed/seed-db.js @@ -189,33 +189,18 @@ import Factory from './factories' ]) await Promise.all([ - f.create('Comment', { id: 'c1', postId: 'p1' }), - f.create('Comment', { id: 'c2', postId: 'p1' }), - f.create('Comment', { id: 'c3', postId: 'p3' }), - f.create('Comment', { id: 'c4', postId: 'p2' }), - f.create('Comment', { id: 'c5', postId: 'p3' }), - f.create('Comment', { id: 'c6', postId: 'p4' }), - f.create('Comment', { id: 'c7', postId: 'p2' }), - f.create('Comment', { id: 'c8', postId: 'p15' }), - f.create('Comment', { id: 'c9', postId: 'p15' }), - f.create('Comment', { id: 'c10', postId: 'p15' }), - f.create('Comment', { id: 'c11', postId: 'p15' }), - f.create('Comment', { id: 'c12', postId: 'p15' }) - ]) - - await Promise.all([ - f.relate('Comment', 'Author', { from: 'u3', to: 'c1' }), - f.relate('Comment', 'Author', { from: 'u1', to: 'c2' }), - f.relate('Comment', 'Author', { from: 'u1', to: 'c3' }), - f.relate('Comment', 'Author', { from: 'u4', to: 'c4' }), - f.relate('Comment', 'Author', { from: 'u4', to: 'c5' }), - f.relate('Comment', 'Author', { from: 'u3', to: 'c6' }), - f.relate('Comment', 'Author', { from: 'u2', to: 'c7' }), - f.relate('Comment', 'Author', { from: 'u5', to: 'c8' }), - f.relate('Comment', 'Author', { from: 'u6', to: 'c9' }), - f.relate('Comment', 'Author', { from: 'u7', to: 'c10' }), - f.relate('Comment', 'Author', { from: 'u5', to: 'c11' }), - f.relate('Comment', 'Author', { from: 'u6', to: 'c12' }) + asUser.create('Comment', { id: 'c1', postId: 'p1' }), + asTick.create('Comment', { id: 'c2', postId: 'p1' }), + asTrack.create('Comment', { id: 'c3', postId: 'p3' }), + asTrick.create('Comment', { id: 'c4', postId: 'p2' }), + asModerator.create('Comment', { id: 'c5', postId: 'p3' }), + asAdmin.create('Comment', { id: 'c6', postId: 'p4' }), + asUser.create('Comment', { id: 'c7', postId: 'p2' }), + asTick.create('Comment', { id: 'c8', postId: 'p15' }), + asTrick.create('Comment', { id: 'c9', postId: 'p15' }), + asTrack.create('Comment', { id: 'c10', postId: 'p15' }), + asUser.create('Comment', { id: 'c11', postId: 'p15' }), + asUser.create('Comment', { id: 'c12', postId: 'p15' }) ]) const disableMutation = 'mutation($id: ID!) { disable(id: $id) }' From 346158da7fba9da7de1a915d5da273023fa06a67 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Thu, 2 May 2019 19:55:54 -0300 Subject: [PATCH 17/82] Update to use autogenerated Comment Query - using the custom CommentByPost Query was not returning the author of the Post, therefore the users avatar was not showing up - there are some weird bugs with the comments, if you dblclick on the button, two comments with the same content are created - sometimes the comments appear as the bottom of the list, sometimes they appear three comments from the bottom(?) --- backend/src/resolvers/comments.js | 45 +++++++-------------------- webapp/graphql/CommentQuery.js | 26 ++++++++++++++-- webapp/pages/post/_id/_slug/index.vue | 6 ++-- 3 files changed, 38 insertions(+), 39 deletions(-) diff --git a/backend/src/resolvers/comments.js b/backend/src/resolvers/comments.js index b2dc0fbcf..56280d6ea 100644 --- a/backend/src/resolvers/comments.js +++ b/backend/src/resolvers/comments.js @@ -3,26 +3,6 @@ import { UserInputError } from 'apollo-server' const COMMENT_MIN_LENGTH = 1 export default { - Query: { - CommentByPost: async (object, params, context, resolveInfo) => { - const { postId } = params - - const session = context.driver.session() - const transactionRes = await session.run(` - MATCH (comment:Comment)-[:COMMENTS]->(post:Post {id: $postId}) - RETURN comment {.id, .contentExcerpt, .createdAt} ORDER BY comment.createdAt ASC`, { - postId - }) - - session.close() - let comments = [] - transactionRes.records.map(record => { - comments.push(record.get('comment')) - }) - - return comments - } - }, Mutation: { CreateComment: async (object, params, context, resolveInfo) => { const content = params.content.replace(/<(?:.|\n)*?>/gm, '').trim() @@ -31,29 +11,26 @@ export default { throw new UserInputError(`Comment must be at least ${COMMENT_MIN_LENGTH} character long!`) } const { postId } = params - delete params.postId const comment = await neo4jgraphql(object, params, context, resolveInfo, false) const session = context.driver.session() await session.run(` - MATCH (post:Post {id: $postId}), (comment:Comment {id: $commentId}) - MERGE (post)<-[:COMMENTS]-(comment) - RETURN comment {.id, .content}`, { + MATCH (author:User {id: $userId}), (comment:Comment {id: $commentId}) + MERGE (comment)<-[:WROTE]-(author) + RETURN author`, { + userId: context.user.id, + commentId: comment.id + } + ) + await session.run(` + MATCH (post:Post {id: $postId}), (comment:Comment {id: $commentId}) + MERGE (post)<-[:COMMENTS]-(comment) + RETURN post`, { postId, commentId: comment.id } ) - - await session.run(` - MATCH (comment:Comment {id: $commentId}), (author:User {id: $userId}) - MERGE (comment)<-[:WROTE]-(author) - RETURN comment {.id, .content}`, { - commentId: comment.id, - userId: context.user.id - } - ) - session.close() return comment diff --git a/webapp/graphql/CommentQuery.js b/webapp/graphql/CommentQuery.js index 299916823..0e61a8a6c 100644 --- a/webapp/graphql/CommentQuery.js +++ b/webapp/graphql/CommentQuery.js @@ -1,12 +1,34 @@ import gql from 'graphql-tag' export default app => { + const lang = app.$i18n.locale().toUpperCase() return gql(` - query CommentByPost($postId: ID!) { - CommentByPost(postId: $postId) { + query Comment($postId: ID) { + Comment(postId: $postId) { id contentExcerpt createdAt + author { + id + slug + name + avatar + disabled + deleted + shoutedCount + contributionsCount + commentsCount + followedByCount + followedByCurrentUser + location { + name: name${lang} + } + badges { + id + key + icon + } + } } } `) diff --git a/webapp/pages/post/_id/_slug/index.vue b/webapp/pages/post/_id/_slug/index.vue index f83925f68..7ae683425 100644 --- a/webapp/pages/post/_id/_slug/index.vue +++ b/webapp/pages/post/_id/_slug/index.vue @@ -179,7 +179,7 @@ export default { this.post = post[0] || {} this.title = this.post.title }, - CommentByPost(comments) { + Comment(comments) { this.comments = comments || [] } }, @@ -291,11 +291,11 @@ export default { return this.$store.getters['auth/user'].id === id }, addComment(comment) { - this.$apollo.queries.CommentByPost.refetch() + this.$apollo.queries.Comment.refetch() } }, apollo: { - CommentByPost: { + Comment: { query() { return require('~/graphql/CommentQuery.js').default(this) }, From 40f5b6acd5545dcbf8a5bc60abed29cf9b2bb435 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Thu, 2 May 2019 21:03:31 -0300 Subject: [PATCH 18/82] Extract CommentsList component - this allows to Query for comments by Post --- webapp/components/CommentForm/index.vue | 2 +- webapp/components/CommentList/index.vue | 79 +++++++++++++++++++++++++ webapp/graphql/PostCommentsQuery.js | 40 +++++++++++++ webapp/pages/post/_id/_slug/index.vue | 62 ++----------------- 4 files changed, 125 insertions(+), 58 deletions(-) create mode 100644 webapp/components/CommentList/index.vue create mode 100644 webapp/graphql/PostCommentsQuery.js diff --git a/webapp/components/CommentForm/index.vue b/webapp/components/CommentForm/index.vue index fdb1761dc..6019b0965 100644 --- a/webapp/components/CommentForm/index.vue +++ b/webapp/components/CommentForm/index.vue @@ -91,7 +91,7 @@ export default { } }) .then(res => { - this.$emit('addComment', res.data.CreateComment) + this.$root.$emit('addComment', res.data.CreateComment) this.$refs.editor.clear() this.$toast.success(this.$t('post.comment.submitted')) }) diff --git a/webapp/components/CommentList/index.vue b/webapp/components/CommentList/index.vue new file mode 100644 index 000000000..ba9ada717 --- /dev/null +++ b/webapp/components/CommentList/index.vue @@ -0,0 +1,79 @@ + + diff --git a/webapp/graphql/PostCommentsQuery.js b/webapp/graphql/PostCommentsQuery.js new file mode 100644 index 000000000..2c37f2933 --- /dev/null +++ b/webapp/graphql/PostCommentsQuery.js @@ -0,0 +1,40 @@ +import gql from 'graphql-tag' + +export default app => { + const lang = app.$i18n.locale().toUpperCase() + return gql(` + query Post($slug: String!) { + Post(slug: $slug) { + commentsCount + comments(orderBy: createdAt_asc) { + id + contentExcerpt + createdAt + disabled + deleted + author { + id + slug + name + avatar + disabled + deleted + shoutedCount + contributionsCount + commentsCount + followedByCount + followedByCurrentUser + location { + name: name${lang} + } + badges { + id + key + icon + } + } + } + } + } + `) +} diff --git a/webapp/pages/post/_id/_slug/index.vue b/webapp/pages/post/_id/_slug/index.vue index 7ae683425..692dbe69e 100644 --- a/webapp/pages/post/_id/_slug/index.vue +++ b/webapp/pages/post/_id/_slug/index.vue @@ -96,39 +96,9 @@ -

- - - {{ comments.length }}  Comments - -

+ -
- -
- - - +
@@ -142,9 +112,8 @@ import HcTag from '~/components/Tag' import ContentMenu from '~/components/ContentMenu' import HcUser from '~/components/User' import HcShoutButton from '~/components/ShoutButton.vue' -import HcEmpty from '~/components/Empty.vue' import HcCommentForm from '~/components/CommentForm' -import Comment from '~/components/Comment.vue' +import HcCommentList from '~/components/CommentList' export default { transition: { @@ -156,10 +125,9 @@ export default { HcCategory, HcUser, HcShoutButton, - HcEmpty, - Comment, ContentMenu, - HcCommentForm + HcCommentForm, + HcCommentList }, head() { return { @@ -169,7 +137,6 @@ export default { data() { return { post: null, - comments: null, ready: false, title: 'loading' } @@ -178,9 +145,6 @@ export default { Post(post) { this.post = post[0] || {} this.title = this.post.title - }, - Comment(comments) { - this.comments = comments || [] } }, async asyncData(context) { @@ -289,22 +253,6 @@ export default { methods: { isAuthor(id) { return this.$store.getters['auth/user'].id === id - }, - addComment(comment) { - this.$apollo.queries.Comment.refetch() - } - }, - apollo: { - Comment: { - query() { - return require('~/graphql/CommentQuery.js').default(this) - }, - variables() { - return { - postId: this.post.id - } - }, - fetchPolicy: 'cache-and-network' } } } From 54fe0a58e2f56ebcce1d42baadf3cfee6ef7ea01 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Fri, 3 May 2019 04:51:08 +0000 Subject: [PATCH 19/82] Bump graphql-shield from 5.3.4 to 5.3.5 in /backend Bumps [graphql-shield](https://github.com/maticzav/graphql-shield) from 5.3.4 to 5.3.5. - [Release notes](https://github.com/maticzav/graphql-shield/releases) - [Commits](https://github.com/maticzav/graphql-shield/compare/v5.3.4...v5.3.5) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/backend/package.json b/backend/package.json index 7e972d0e6..de72d1744 100644 --- a/backend/package.json +++ b/backend/package.json @@ -50,7 +50,7 @@ "graphql-custom-directives": "~0.2.14", "graphql-iso-date": "~3.6.1", "graphql-middleware": "~3.0.2", - "graphql-shield": "~5.3.4", + "graphql-shield": "~5.3.5", "graphql-tag": "~2.10.1", "graphql-yoga": "~1.17.4", "helmet": "~3.16.0", diff --git a/backend/yarn.lock b/backend/yarn.lock index fab84f08e..845fc8146 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -1104,10 +1104,10 @@ resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-12.0.9.tgz#693e76a52f61a2f1e7fb48c0eef167b95ea4ffd0" integrity sha512-sCZy4SxP9rN2w30Hlmg5dtdRwgYQfYRiLo9usw8X9cxlf+H4FqM1xX7+sNH7NNKVdbXMJWqva7iyy+fxh/V7fA== -"@types/yup@0.26.12": - version "0.26.12" - resolved "https://registry.yarnpkg.com/@types/yup/-/yup-0.26.12.tgz#60fc1a485923a929699d2107fac46e6769707c4a" - integrity sha512-lWCsvLer6G84Gj7yh+oFGRuGHsqZd1Dwu47CVVL0ATw+bOnGDgMNHbTn80p1onT66fvLfN8FnRA3eRANsnnbbQ== +"@types/yup@0.26.13": + version "0.26.13" + resolved "https://registry.yarnpkg.com/@types/yup/-/yup-0.26.13.tgz#0aeeba85231a34ddc68c74b3a2c64eeb2ccf68bf" + integrity sha512-sMMtb+c2xxf/FcK0kW36+0uuSWpNwvCBZYI7vpnD9J9Z6OYk09P4TmDkMWV+NWdi9Nzt2tUJjtpnPpkiUklBaw== "@types/zen-observable@^0.5.3": version "0.5.4" @@ -3752,12 +3752,12 @@ graphql-request@~1.8.2: dependencies: cross-fetch "2.2.2" -graphql-shield@~5.3.4: - version "5.3.4" - resolved "https://registry.yarnpkg.com/graphql-shield/-/graphql-shield-5.3.4.tgz#bd126d7d39adc6ae5b91d93ab5f65ae25f93ce80" - integrity sha512-YasNfKk7d0hiSU9eh0zvJmRmUMDLZrfVTwSke/4y46cBRXFiI9fv6OA12Ux+1DB4TyDAjGGnqx8d92ptL7ZN3w== +graphql-shield@~5.3.5: + version "5.3.5" + resolved "https://registry.yarnpkg.com/graphql-shield/-/graphql-shield-5.3.5.tgz#cba409f4c1714e107212cff0a1cb2d934273392b" + integrity sha512-3kmL9x+b85NK2ipH3VGudUgUo1vXy0Z44WXhnGi3b0T0peg53DOSlXBbZOO4PNh1AcULnUjYf+DpDrP8Uc97Gw== dependencies: - "@types/yup" "0.26.12" + "@types/yup" "0.26.13" lightercollective "^0.3.0" object-hash "^1.3.1" yup "^0.27.0" From 957d8943227bef2c4c4c8acd8352c1e00c969254 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Fri, 3 May 2019 11:18:14 -0300 Subject: [PATCH 20/82] Start writing component test - restructured directories --- .../comments/CommentForm/CommentForm.test.js | 74 +++++++++++++++++++ .../{ => comments}/CommentForm/index.vue | 2 + .../{ => comments}/CommentList/index.vue | 0 webapp/graphql/PostCommentsQuery.js | 1 - webapp/pages/post/_id/_slug/index.vue | 4 +- 5 files changed, 78 insertions(+), 3 deletions(-) create mode 100644 webapp/components/comments/CommentForm/CommentForm.test.js rename webapp/components/{ => comments}/CommentForm/index.vue (96%) rename webapp/components/{ => comments}/CommentList/index.vue (100%) diff --git a/webapp/components/comments/CommentForm/CommentForm.test.js b/webapp/components/comments/CommentForm/CommentForm.test.js new file mode 100644 index 000000000..6453f689a --- /dev/null +++ b/webapp/components/comments/CommentForm/CommentForm.test.js @@ -0,0 +1,74 @@ +import { config, mount, createLocalVue } from '@vue/test-utils' +import CommentForm from './index.vue' +import Vue from 'vue' +import Styleguide from '@human-connection/styleguide' + +const localVue = createLocalVue() + +localVue.use(Styleguide) + +config.stubs['no-ssr'] = '' + +describe('CommentForm.vue', () => { + let mocks + let wrapper + let form + let propsData + let submitBtn + let cancelBtn + + beforeEach(() => { + mocks = { + $t: jest.fn(), + $apollo: { + mutate: jest + .fn() + .mockRejectedValue({ message: 'Ouch!' }) + .mockResolvedValueOnce({ data: { CreateComment: { contentExcerpt: 'this is a comment' } } }) + }, + $toast: { + error: jest.fn(), + success: jest.fn() + }, + $root: { + $emit: jest.fn() + } + }, + propsData = { + post: { id: 1 } + } + }) + + describe('mount', () => { + const Wrapper = () => { + return mount(CommentForm, { mocks, localVue, propsData }) + } + + beforeEach(() => { + wrapper = Wrapper() + }) + + it('calls the apollo mutation when form is submitted', () => { + wrapper.vm.updateEditorContent('ok') + form = wrapper.find('form') + form.trigger('submit') + expect(mocks.$apollo.mutate).toHaveBeenCalledTimes(1) + }) + + it("calls clear method when the cancel button is clicked", () => { + const spy = jest.spyOn(wrapper.vm, 'clear') + wrapper.vm.updateEditorContent('ok') + cancelBtn = wrapper.find('.cancelBtn') + cancelBtn.trigger('click') + expect(spy).toHaveBeenCalledTimes(1) + }) + + it('shows a success toaster if the mutation resolves', () => { + wrapper.vm.updateEditorContent('ok') + form = wrapper.find('form') + form.trigger('submit') + expect(mocks.$root.$emit).toHaveBeenCalledTimes(1) + expect(mocks.$toast.success).toHaveBeenCalledTimes(1) + }) + }) +}) \ No newline at end of file diff --git a/webapp/components/CommentForm/index.vue b/webapp/components/comments/CommentForm/index.vue similarity index 96% rename from webapp/components/CommentForm/index.vue rename to webapp/components/comments/CommentForm/index.vue index 6019b0965..4377e2e2c 100644 --- a/webapp/components/CommentForm/index.vue +++ b/webapp/components/comments/CommentForm/index.vue @@ -21,6 +21,7 @@ :disabled="disabled" ghost @click.prevent="clear" + class="cancelBtn" > {{ $t('actions.cancel') }} @@ -91,6 +92,7 @@ export default { } }) .then(res => { + // console.log(this.$toast.success.mockResolvedValue()) this.$root.$emit('addComment', res.data.CreateComment) this.$refs.editor.clear() this.$toast.success(this.$t('post.comment.submitted')) diff --git a/webapp/components/CommentList/index.vue b/webapp/components/comments/CommentList/index.vue similarity index 100% rename from webapp/components/CommentList/index.vue rename to webapp/components/comments/CommentList/index.vue diff --git a/webapp/graphql/PostCommentsQuery.js b/webapp/graphql/PostCommentsQuery.js index 2c37f2933..c0ab1320a 100644 --- a/webapp/graphql/PostCommentsQuery.js +++ b/webapp/graphql/PostCommentsQuery.js @@ -5,7 +5,6 @@ export default app => { return gql(` query Post($slug: String!) { Post(slug: $slug) { - commentsCount comments(orderBy: createdAt_asc) { id contentExcerpt diff --git a/webapp/pages/post/_id/_slug/index.vue b/webapp/pages/post/_id/_slug/index.vue index 692dbe69e..87538eb6d 100644 --- a/webapp/pages/post/_id/_slug/index.vue +++ b/webapp/pages/post/_id/_slug/index.vue @@ -112,8 +112,8 @@ import HcTag from '~/components/Tag' import ContentMenu from '~/components/ContentMenu' import HcUser from '~/components/User' import HcShoutButton from '~/components/ShoutButton.vue' -import HcCommentForm from '~/components/CommentForm' -import HcCommentList from '~/components/CommentList' +import HcCommentForm from '~/components/comments/CommentForm' +import HcCommentList from '~/components/comments/CommentList' export default { transition: { From ebc290c6af3ebd51a297fc58db472bcf4c454e77 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Fri, 3 May 2019 13:39:43 -0300 Subject: [PATCH 21/82] Delete CommentForm.test.js, remove console.log - this test is not part of this PR and I'll create another issue and put in a different PR for it --- .../comments/CommentForm/CommentForm.test.js | 74 ------------------- .../components/comments/CommentForm/index.vue | 3 +- 2 files changed, 1 insertion(+), 76 deletions(-) delete mode 100644 webapp/components/comments/CommentForm/CommentForm.test.js diff --git a/webapp/components/comments/CommentForm/CommentForm.test.js b/webapp/components/comments/CommentForm/CommentForm.test.js deleted file mode 100644 index 6453f689a..000000000 --- a/webapp/components/comments/CommentForm/CommentForm.test.js +++ /dev/null @@ -1,74 +0,0 @@ -import { config, mount, createLocalVue } from '@vue/test-utils' -import CommentForm from './index.vue' -import Vue from 'vue' -import Styleguide from '@human-connection/styleguide' - -const localVue = createLocalVue() - -localVue.use(Styleguide) - -config.stubs['no-ssr'] = '' - -describe('CommentForm.vue', () => { - let mocks - let wrapper - let form - let propsData - let submitBtn - let cancelBtn - - beforeEach(() => { - mocks = { - $t: jest.fn(), - $apollo: { - mutate: jest - .fn() - .mockRejectedValue({ message: 'Ouch!' }) - .mockResolvedValueOnce({ data: { CreateComment: { contentExcerpt: 'this is a comment' } } }) - }, - $toast: { - error: jest.fn(), - success: jest.fn() - }, - $root: { - $emit: jest.fn() - } - }, - propsData = { - post: { id: 1 } - } - }) - - describe('mount', () => { - const Wrapper = () => { - return mount(CommentForm, { mocks, localVue, propsData }) - } - - beforeEach(() => { - wrapper = Wrapper() - }) - - it('calls the apollo mutation when form is submitted', () => { - wrapper.vm.updateEditorContent('ok') - form = wrapper.find('form') - form.trigger('submit') - expect(mocks.$apollo.mutate).toHaveBeenCalledTimes(1) - }) - - it("calls clear method when the cancel button is clicked", () => { - const spy = jest.spyOn(wrapper.vm, 'clear') - wrapper.vm.updateEditorContent('ok') - cancelBtn = wrapper.find('.cancelBtn') - cancelBtn.trigger('click') - expect(spy).toHaveBeenCalledTimes(1) - }) - - it('shows a success toaster if the mutation resolves', () => { - wrapper.vm.updateEditorContent('ok') - form = wrapper.find('form') - form.trigger('submit') - expect(mocks.$root.$emit).toHaveBeenCalledTimes(1) - expect(mocks.$toast.success).toHaveBeenCalledTimes(1) - }) - }) -}) \ No newline at end of file diff --git a/webapp/components/comments/CommentForm/index.vue b/webapp/components/comments/CommentForm/index.vue index 4377e2e2c..585b97dba 100644 --- a/webapp/components/comments/CommentForm/index.vue +++ b/webapp/components/comments/CommentForm/index.vue @@ -20,8 +20,8 @@ {{ $t('actions.cancel') }} @@ -92,7 +92,6 @@ export default { } }) .then(res => { - // console.log(this.$toast.success.mockResolvedValue()) this.$root.$emit('addComment', res.data.CreateComment) this.$refs.editor.clear() this.$toast.success(this.$t('post.comment.submitted')) From 31c8b6e35d2af573c2ef1b1088d381a314a25986 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Fri, 3 May 2019 13:41:20 -0300 Subject: [PATCH 22/82] Use single cypher query in CreateComments - to create relation between post, comment, author - fix test to create a post so said cypher query doesn't silently fail --- backend/src/resolvers/comments.js | 13 ++------ backend/src/resolvers/comments.spec.js | 44 ++++++++++++++++---------- 2 files changed, 30 insertions(+), 27 deletions(-) diff --git a/backend/src/resolvers/comments.js b/backend/src/resolvers/comments.js index 56280d6ea..eb792ecb8 100644 --- a/backend/src/resolvers/comments.js +++ b/backend/src/resolvers/comments.js @@ -16,17 +16,10 @@ export default { const session = context.driver.session() await session.run(` - MATCH (author:User {id: $userId}), (comment:Comment {id: $commentId}) - MERGE (comment)<-[:WROTE]-(author) - RETURN author`, { - userId: context.user.id, - commentId: comment.id - } - ) - await session.run(` - MATCH (post:Post {id: $postId}), (comment:Comment {id: $commentId}) - MERGE (post)<-[:COMMENTS]-(comment) + MATCH (post:Post {id: $postId}), (comment:Comment {id: $commentId}), (author:User {id: $userId}) + MERGE (post)<-[:COMMENTS]-(comment)<-[:WROTE]-(author) RETURN post`, { + userId: context.user.id, postId, commentId: comment.id } diff --git a/backend/src/resolvers/comments.spec.js b/backend/src/resolvers/comments.spec.js index e572e206b..9a54acd17 100644 --- a/backend/src/resolvers/comments.spec.js +++ b/backend/src/resolvers/comments.spec.js @@ -4,7 +4,8 @@ import { host, login } from '../jest/helpers' const factory = Factory() let client -let variables +let createCommentVariables +let createPostVariables beforeEach(async () => { await factory.create('User', { @@ -18,7 +19,7 @@ afterEach(async () => { }) describe('CreateComment', () => { - const mutation = ` + const createCommentMutation = ` mutation($postId: ID, $content: String!) { CreateComment(postId: $postId, content: $content) { id @@ -26,14 +27,21 @@ describe('CreateComment', () => { } } ` + const createPostMutation = ` + mutation($id: ID!, $title: String!, $content: String!) { + CreatePost(id: $id, title: $title, content: $content) { + id + } + } + ` describe('unauthenticated', () => { it('throws authorization error', async () => { - variables = { + createCommentVariables = { postId: 'p1', content: 'I\'m not authorised to comment' } client = new GraphQLClient(host) - await expect(client.request(mutation, variables)).rejects.toThrow('Not Authorised') + await expect(client.request(createCommentMutation, createCommentVariables)).rejects.toThrow('Not Authorised') }) }) @@ -42,28 +50,30 @@ describe('CreateComment', () => { beforeEach(async () => { headers = await login({ email: 'test@example.org', password: '1234' }) client = new GraphQLClient(host, { headers }) - }) - - it('creates a comment', async () => { - variables = { + createCommentVariables = { postId: 'p1', content: 'I\'m authorised to comment' } + }) + + it('creates a comment', async () => { const expected = { CreateComment: { content: 'I\'m authorised to comment' } } - await expect(client.request(mutation, variables)).resolves.toMatchObject(expected) + await expect(client.request(createCommentMutation, createCommentVariables)).resolves.toMatchObject(expected) }) it('assigns the authenticated user as author', async () => { - variables = { - postId: 'p1', - content: 'I\'m authorised to comment' + createPostVariables = { + id: 'p1', + title: 'post to comment on', + content: 'please comment on me' } - await client.request(mutation, variables) + await client.request(createPostMutation, createPostVariables) + await client.request(createCommentMutation, createCommentVariables) const { User } = await client.request(`{ User(email: "test@example.org") { @@ -77,22 +87,22 @@ describe('CreateComment', () => { }) it('throw an error if an empty string is sent as content', async () => { - variables = { + createCommentVariables = { postId: 'p1', content: '

' } - await expect(client.request(mutation, variables)) + await expect(client.request(createCommentMutation, createCommentVariables)) .rejects.toThrow('Comment must be at least 1 character long!') }) it('throws an error if a comment does not contain a single character', async () => { - variables = { + createCommentVariables = { postId: 'p1', content: '

' } - await expect(client.request(mutation, variables)) + await expect(client.request(createCommentMutation, createCommentVariables)) .rejects.toThrow('Comment must be at least 1 character long!') }) }) From d1c86827104fb2df3c3e90d4e279ae5ea8430fa1 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Fri, 3 May 2019 15:47:54 -0300 Subject: [PATCH 23/82] Update method name to be more descriptive/accurate --- webapp/components/comments/CommentForm/index.vue | 2 +- webapp/components/comments/CommentList/index.vue | 11 ++++++----- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/webapp/components/comments/CommentForm/index.vue b/webapp/components/comments/CommentForm/index.vue index 585b97dba..9f5197a06 100644 --- a/webapp/components/comments/CommentForm/index.vue +++ b/webapp/components/comments/CommentForm/index.vue @@ -92,7 +92,7 @@ export default { } }) .then(res => { - this.$root.$emit('addComment', res.data.CreateComment) + this.$root.$emit('refetchPostComments', res.data.CreateComment) this.$refs.editor.clear() this.$toast.success(this.$t('post.comment.submitted')) }) diff --git a/webapp/components/comments/CommentList/index.vue b/webapp/components/comments/CommentList/index.vue index ba9ada717..57b720087 100644 --- a/webapp/components/comments/CommentList/index.vue +++ b/webapp/components/comments/CommentList/index.vue @@ -26,6 +26,7 @@ @@ -44,21 +45,21 @@ export default { }, data() { return { - comments: null + comments: [] } }, watch: { Post(post) { - this.comments = post[0].comments || {} + this.comments = post[0].comments || [] } }, mounted() { - this.$root.$on('addComment', comment => { - this.addComment(comment) + this.$root.$on('refetchPostComments', comment => { + this.refetchPostComments(comment) }) }, methods: { - addComment(comment) { + refetchPostComments(comment) { this.$apollo.queries.Post.refetch() } }, From da218f8a58b2dd596f0f0a92174bd43dce37abe5 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Fri, 3 May 2019 15:48:20 -0300 Subject: [PATCH 24/82] Add component test for extracted CommentList.vue --- .../comments/CommentList/CommentList.spec.js | 64 +++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 webapp/components/comments/CommentList/CommentList.spec.js diff --git a/webapp/components/comments/CommentList/CommentList.spec.js b/webapp/components/comments/CommentList/CommentList.spec.js new file mode 100644 index 000000000..fa6394e53 --- /dev/null +++ b/webapp/components/comments/CommentList/CommentList.spec.js @@ -0,0 +1,64 @@ +import { config, mount, createLocalVue } from '@vue/test-utils' +import CommentList from '.' +import Empty from '~/components/Empty' +import Vue from 'vue' +import Vuex from 'vuex' +import Filters from '~/plugins/vue-filters' +import Styleguide from '@human-connection/styleguide' + +const localVue = createLocalVue() + +localVue.use(Styleguide) +localVue.use(Vuex) +localVue.filter('truncate', string => string) + +config.stubs['v-popover'] = '' +config.stubs['nuxt-link'] = '' +config.stubs['no-ssr'] = '' + +describe('CommentList.vue', () => { + let mocks + let store + let wrapper + let propsData + + propsData = { + post: { id: 1 } + } + store = new Vuex.Store({ + getters: { + 'auth/user': () => { + return {} + } + } + }) + mocks = { + $t: jest.fn() + } + + describe('shallowMount', () => { + const Wrapper = () => { + return mount(CommentList, { store, mocks, localVue, propsData }) + } + + beforeEach(() => { + wrapper = Wrapper() + wrapper.setData({ + comments: [{ id: 'c1', contentExcerpt: 'this is a comment' }] + }) + }) + + it('displays a comments counter', () => { + expect(wrapper.find('span.ds-tag').text()).toEqual('1') + }) + + it('displays comments when there are comments to display', () => { + expect(wrapper.find('div#comments').text()).toEqual('this is a comment') + }) + + it('displays a message icon when there are no comments to display', () => { + wrapper.setData({ comments: [] }) + expect(wrapper.findAll(Empty)).toHaveLength(1) + }) + }) +}) From 70fb34345dde30ae4df302d80e9b9ae721168e42 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Fri, 3 May 2019 15:52:26 -0300 Subject: [PATCH 25/82] Improve test by mounting CommentList with data --- .../comments/CommentList/CommentList.spec.js | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/webapp/components/comments/CommentList/CommentList.spec.js b/webapp/components/comments/CommentList/CommentList.spec.js index fa6394e53..6a96f3e19 100644 --- a/webapp/components/comments/CommentList/CommentList.spec.js +++ b/webapp/components/comments/CommentList/CommentList.spec.js @@ -21,6 +21,7 @@ describe('CommentList.vue', () => { let store let wrapper let propsData + let data propsData = { post: { id: 1 } @@ -35,10 +36,15 @@ describe('CommentList.vue', () => { mocks = { $t: jest.fn() } + data = () => { + return { + comments: [] + } + } describe('shallowMount', () => { const Wrapper = () => { - return mount(CommentList, { store, mocks, localVue, propsData }) + return mount(CommentList, { store, mocks, localVue, propsData, data }) } beforeEach(() => { @@ -48,6 +54,10 @@ describe('CommentList.vue', () => { }) }) + it('displays a message icon when there are no comments to display', () => { + expect(Wrapper().findAll(Empty)).toHaveLength(1) + }) + it('displays a comments counter', () => { expect(wrapper.find('span.ds-tag').text()).toEqual('1') }) @@ -55,10 +65,5 @@ describe('CommentList.vue', () => { it('displays comments when there are comments to display', () => { expect(wrapper.find('div#comments').text()).toEqual('this is a comment') }) - - it('displays a message icon when there are no comments to display', () => { - wrapper.setData({ comments: [] }) - expect(wrapper.findAll(Empty)).toHaveLength(1) - }) }) }) From 2af9b853a14f2f168b164a89a44aa18cad6b89af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Sat, 4 May 2019 10:13:40 +0200 Subject: [PATCH 26/82] Add first try of Webapp Component Test MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add `ìd` to the SocialMedia data --- webapp/pages/settings/my-social-media.spec.js | 6 ++++++ webapp/pages/settings/my-social-media.vue | 5 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/webapp/pages/settings/my-social-media.spec.js b/webapp/pages/settings/my-social-media.spec.js index 4f48a2835..b8c2f8182 100644 --- a/webapp/pages/settings/my-social-media.spec.js +++ b/webapp/pages/settings/my-social-media.spec.js @@ -71,6 +71,12 @@ describe('my-social-media.vue', () => { const socialMediaLink = wrapper.find('a').attributes().href expect(socialMediaLink).toBe(socialMediaUrl) }) + + it('displays a trash sympol after a social media', () => { + wrapper = Wrapper() + iconName = wrapper.find('.ds-icon').attributes().name + expect(iconName).toBe('trash') + }) }) describe('currentUser does not have a social media account linked', () => { diff --git a/webapp/pages/settings/my-social-media.vue b/webapp/pages/settings/my-social-media.vue index 0eba9c3f0..5b3914ff0 100644 --- a/webapp/pages/settings/my-social-media.vue +++ b/webapp/pages/settings/my-social-media.vue @@ -28,6 +28,7 @@ class="layout-leave-active" /> @@ -74,13 +75,13 @@ export default { socialMediaLinks() { const { socialMedia = [] } = this.currentUser return socialMedia.map(socialMedia => { - const { url } = socialMedia + const { id, url } = socialMedia const matches = url.match( /^(?:https?:\/\/)?(?:[^@\n])?(?:www\.)?([^:\/\n?]+)/g ) const [domain] = matches || [] const favicon = domain ? `${domain}/favicon.ico` : null - return { url, favicon } + return { id, url, favicon } }) } }, From 4d631c452d09bc5ea44cb3a04aec14c4a917cea7 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Sat, 4 May 2019 17:42:42 -0300 Subject: [PATCH 27/82] Add more unit tests, add back postId deletion --- backend/src/resolvers/comments.js | 27 +++++++- backend/src/resolvers/comments.spec.js | 85 +++++++++++++++++++++++--- 2 files changed, 102 insertions(+), 10 deletions(-) diff --git a/backend/src/resolvers/comments.js b/backend/src/resolvers/comments.js index eb792ecb8..d4775b235 100644 --- a/backend/src/resolvers/comments.js +++ b/backend/src/resolvers/comments.js @@ -2,18 +2,41 @@ import { neo4jgraphql } from 'neo4j-graphql-js' import { UserInputError } from 'apollo-server' const COMMENT_MIN_LENGTH = 1 +const NO_POST_ERR_MESSAGE = 'Comment cannot be created without a post!' + export default { Mutation: { CreateComment: async (object, params, context, resolveInfo) => { const content = params.content.replace(/<(?:.|\n)*?>/gm, '').trim() + const { postId } = params + // Adding relationship from comment to post by passing in the postId, + // but we do not want to create the comment with postId as an attribute + // because we use relationships for this. So, we are deleting it from params + // before comment creation. + delete params.postId if (!params.content || content.length < COMMENT_MIN_LENGTH) { throw new UserInputError(`Comment must be at least ${COMMENT_MIN_LENGTH} character long!`) } - const { postId } = params - const comment = await neo4jgraphql(object, params, context, resolveInfo, false) + if (!postId.trim()) { + throw new UserInputError(NO_POST_ERR_MESSAGE) + } const session = context.driver.session() + const postQueryRes = await session.run(` + MATCH (post:Post {id: $postId}) + RETURN post`, { + postId + } + ) + const [post] = postQueryRes.records.map(record => { + return record.get('post') + }) + + if (!post) { + throw new UserInputError(NO_POST_ERR_MESSAGE) + } + const comment = await neo4jgraphql(object, params, context, resolveInfo, false) await session.run(` MATCH (post:Post {id: $postId}), (comment:Comment {id: $commentId}), (author:User {id: $userId}) diff --git a/backend/src/resolvers/comments.spec.js b/backend/src/resolvers/comments.spec.js index 9a54acd17..87a0df270 100644 --- a/backend/src/resolvers/comments.spec.js +++ b/backend/src/resolvers/comments.spec.js @@ -6,6 +6,8 @@ const factory = Factory() let client let createCommentVariables let createPostVariables +let createCommentVariablesSansPostId +let createCommentVariablesWithNonExistentPost beforeEach(async () => { await factory.create('User', { @@ -34,6 +36,13 @@ describe('CreateComment', () => { } } ` + const commentQueryForPostId = ` + query($content: String) { + Comment(content: $content) { + postId + } + } + ` describe('unauthenticated', () => { it('throws authorization error', async () => { createCommentVariables = { @@ -54,6 +63,12 @@ describe('CreateComment', () => { postId: 'p1', content: 'I\'m authorised to comment' } + createPostVariables = { + id: 'p1', + title: 'post to comment on', + content: 'please comment on me' + } + await client.request(createPostMutation, createPostVariables) }) it('creates a comment', async () => { @@ -67,12 +82,6 @@ describe('CreateComment', () => { }) it('assigns the authenticated user as author', async () => { - createPostVariables = { - id: 'p1', - title: 'post to comment on', - content: 'please comment on me' - } - await client.request(createPostMutation, createPostVariables) await client.request(createCommentMutation, createCommentVariables) const { User } = await client.request(`{ @@ -86,7 +95,7 @@ describe('CreateComment', () => { expect(User).toEqual([ { comments: [ { content: 'I\'m authorised to comment' } ] } ]) }) - it('throw an error if an empty string is sent as content', async () => { + it('throw an error if an empty string is sent from the editor as content', async () => { createCommentVariables = { postId: 'p1', content: '

' @@ -96,7 +105,7 @@ describe('CreateComment', () => { .rejects.toThrow('Comment must be at least 1 character long!') }) - it('throws an error if a comment does not contain a single character', async () => { + it('throws an error if a comment sent from the editor does not contain a single character', async () => { createCommentVariables = { postId: 'p1', content: '

' @@ -105,5 +114,65 @@ describe('CreateComment', () => { await expect(client.request(createCommentMutation, createCommentVariables)) .rejects.toThrow('Comment must be at least 1 character long!') }) + + it('throws an error if postId is sent as an empty string', async () => { + createCommentVariables = { + postId: 'p1', + content: '' + } + + await expect(client.request(createCommentMutation, createCommentVariables)) + .rejects.toThrow('Comment must be at least 1 character long!') + }) + + it('throws an error if content is sent as an string of empty characters', async () => { + createCommentVariables = { + postId: 'p1', + content: ' ' + } + + await expect(client.request(createCommentMutation, createCommentVariables)) + .rejects.toThrow('Comment must be at least 1 character long!') + }) + + it('throws an error if postId is sent as an empty string', async () => { + createCommentVariablesSansPostId = { + postId: '', + content: 'this comment should not be created' + } + + await expect(client.request(createCommentMutation, createCommentVariablesSansPostId)) + .rejects.toThrow('Comment cannot be created without a post!') + }) + + it('throws an error if postId is sent as an string of empty characters', async () => { + createCommentVariablesSansPostId = { + postId: ' ', + content: 'this comment should not be created' + } + + await expect(client.request(createCommentMutation, createCommentVariablesSansPostId)) + .rejects.toThrow('Comment cannot be created without a post!') + }) + + it('throws an error if the post does not exist in the database', async () => { + createCommentVariablesWithNonExistentPost = { + postId: 'p2', + content: 'comment should not be created cause the post doesn\'t exist' + } + + await expect(client.request(createCommentMutation, createCommentVariablesWithNonExistentPost)) + .rejects.toThrow('Comment cannot be created without a post!') + }) + + it('does not create the comment with the postId as an attribute', async () => { + const commentQueryVariablesByContent = { + content: 'I\'m authorised to comment' + } + + await client.request(createCommentMutation, createCommentVariables) + const { Comment } = await client.request(commentQueryForPostId, commentQueryVariablesByContent) + expect(Comment).toEqual([{ postId: null }]) + }) }) }) From 1fff9bbc46563d5a2f8f0e90dfc4a43056faa0c5 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Sat, 4 May 2019 18:46:34 -0300 Subject: [PATCH 28/82] Add cypress test to expose comment creation bug - at the moment, one can create the same comment by clicking rapidly on the "Comment" button - an idea for a fix https://stackoverflow.com/questions/53101521/prevent-repeated-queries-in-apollo-server-2 --- cypress/integration/common/post.js | 19 +++++++++++++++++++ cypress/integration/common/steps.js | 1 + cypress/integration/post/Comment.feature | 11 +++++++++++ .../components/comments/CommentForm/index.vue | 6 ++++++ 4 files changed, 37 insertions(+) diff --git a/cypress/integration/common/post.js b/cypress/integration/common/post.js index 85a9f3339..ca7e62b30 100644 --- a/cypress/integration/common/post.js +++ b/cypress/integration/common/post.js @@ -1,5 +1,7 @@ import { When, Then } from 'cypress-cucumber-preprocessor/steps' +const narratorAvatar = 'https://s3.amazonaws.com/uifaces/faces/twitter/nerrsoft/128.jpg' + Then('I click on the {string} button', text => { cy.get('button').contains(text).click() }) @@ -12,9 +14,26 @@ Then('my comment should be successfully created', () => { Then('I should see my comment', () => { cy.get('div.comment p') .should('contain', 'Human Connection rocks') + .get('.ds-avatar img') + .should('have.attr', 'src') + .and('contain', narratorAvatar) }) Then('the editor should be cleared', () => { cy.get('.ProseMirror p') .should('have.class', 'is-empty') }) + +Then('I rapidly double click on the {string} button', text => { + cy.get('button').contains(text).click().click() +}) + +Then('I should see my comment once', () => { + cy.get('div.comment p') + .should('contain', 'Human Connection rocks') + .and('have.length', 1) + .get('.ds-avatar img') + .should('have.attr', 'src') + .and('contain', narratorAvatar) + .and('have.length', 1) +}) \ No newline at end of file diff --git a/cypress/integration/common/steps.js b/cypress/integration/common/steps.js index 85a660f43..0be3f882f 100644 --- a/cypress/integration/common/steps.js +++ b/cypress/integration/common/steps.js @@ -11,6 +11,7 @@ let loginCredentials = { } const narratorParams = { name: 'Peter Pan', + avatar: 'https://s3.amazonaws.com/uifaces/faces/twitter/nerrsoft/128.jpg', ...loginCredentials } diff --git a/cypress/integration/post/Comment.feature b/cypress/integration/post/Comment.feature index e7e462824..afac543d9 100644 --- a/cypress/integration/post/Comment.feature +++ b/cypress/integration/post/Comment.feature @@ -20,3 +20,14 @@ Feature: Post Comment Then my comment should be successfully created And I should see my comment And the editor should be cleared + + Scenario: Prevention of multiple comment creation + Given I visit "post/bWBjpkTKZp/101-essays" + And I type in the following text: + """ + Human Connection rocks + """ + And I rapidly double click on the "Comment" button + Then my comment should be successfully created + And I should see my comment once + And the editor should be cleared diff --git a/webapp/components/comments/CommentForm/index.vue b/webapp/components/comments/CommentForm/index.vue index 9f5197a06..3efb3a625 100644 --- a/webapp/components/comments/CommentForm/index.vue +++ b/webapp/components/comments/CommentForm/index.vue @@ -29,6 +29,7 @@ @@ -56,6 +57,7 @@ export default { data() { return { disabled: true, + loading: false, form: { content: '' }, @@ -76,6 +78,8 @@ export default { this.$refs.editor.clear() }, handleSubmit() { + this.loading = true + this.loading = false this.$apollo .mutate({ mutation: gql` @@ -92,9 +96,11 @@ export default { } }) .then(res => { + this.loading = false this.$root.$emit('refetchPostComments', res.data.CreateComment) this.$refs.editor.clear() this.$toast.success(this.$t('post.comment.submitted')) + this.disabled = false }) .catch(err => { this.$toast.error(err.message) From ad46c2d059671b43c81cfb51f0bfc42590a61f90 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Sun, 5 May 2019 12:26:02 -0300 Subject: [PATCH 29/82] Remove cypress test - it is not part of the scope of this ticket, and therefore should be extracted and dealt with separately --- cypress/integration/common/post.js | 14 -------------- cypress/integration/post/Comment.feature | 11 ----------- webapp/components/comments/CommentForm/index.vue | 2 +- 3 files changed, 1 insertion(+), 26 deletions(-) diff --git a/cypress/integration/common/post.js b/cypress/integration/common/post.js index ca7e62b30..f6a1bbedd 100644 --- a/cypress/integration/common/post.js +++ b/cypress/integration/common/post.js @@ -23,17 +23,3 @@ Then('the editor should be cleared', () => { cy.get('.ProseMirror p') .should('have.class', 'is-empty') }) - -Then('I rapidly double click on the {string} button', text => { - cy.get('button').contains(text).click().click() -}) - -Then('I should see my comment once', () => { - cy.get('div.comment p') - .should('contain', 'Human Connection rocks') - .and('have.length', 1) - .get('.ds-avatar img') - .should('have.attr', 'src') - .and('contain', narratorAvatar) - .and('have.length', 1) -}) \ No newline at end of file diff --git a/cypress/integration/post/Comment.feature b/cypress/integration/post/Comment.feature index afac543d9..e7e462824 100644 --- a/cypress/integration/post/Comment.feature +++ b/cypress/integration/post/Comment.feature @@ -20,14 +20,3 @@ Feature: Post Comment Then my comment should be successfully created And I should see my comment And the editor should be cleared - - Scenario: Prevention of multiple comment creation - Given I visit "post/bWBjpkTKZp/101-essays" - And I type in the following text: - """ - Human Connection rocks - """ - And I rapidly double click on the "Comment" button - Then my comment should be successfully created - And I should see my comment once - And the editor should be cleared diff --git a/webapp/components/comments/CommentForm/index.vue b/webapp/components/comments/CommentForm/index.vue index 3efb3a625..d59314e07 100644 --- a/webapp/components/comments/CommentForm/index.vue +++ b/webapp/components/comments/CommentForm/index.vue @@ -79,7 +79,7 @@ export default { }, handleSubmit() { this.loading = true - this.loading = false + this.disabled = true this.$apollo .mutate({ mutation: gql` From 4c09268f49f1911bae816f607cd35dc29c166779 Mon Sep 17 00:00:00 2001 From: Matt Rider Date: Sun, 5 May 2019 13:57:12 -0300 Subject: [PATCH 30/82] Update tests after backend validations - Now a comment cannot be created without a post to associate it with --- backend/src/resolvers/moderation.spec.js | 48 ++++++++++++++---------- backend/src/resolvers/reports.spec.js | 11 +++++- 2 files changed, 38 insertions(+), 21 deletions(-) diff --git a/backend/src/resolvers/moderation.spec.js b/backend/src/resolvers/moderation.spec.js index f8aa6e10b..28f4dc322 100644 --- a/backend/src/resolvers/moderation.spec.js +++ b/backend/src/resolvers/moderation.spec.js @@ -16,6 +16,9 @@ const setupAuthenticateClient = (params) => { let createResource let authenticateClient +let createPostVariables +let createCommentVariables + beforeEach(() => { createResource = () => {} authenticateClient = () => { @@ -103,18 +106,21 @@ describe('disable', () => { variables = { id: 'c47' } - + createPostVariables = { + id: 'p3', + title: 'post to comment on', + content: 'please comment on me' + } + createCommentVariables = { + id: 'c47', + postId: 'p3', + content: 'this comment was created for this post' + } createResource = async () => { await factory.create('User', { id: 'u45', email: 'commenter@example.org', password: '1234' }) - await factory.authenticateAs({ email: 'commenter@example.org', password: '1234' }) - await Promise.all([ - factory.create('Post', { id: 'p3' }), - factory.create('Comment', { id: 'c47', postId: 'p3', content: 'this comment was created for this post' }) - ]) - - await Promise.all([ - factory.relate('Comment', 'Author', { from: 'u45', to: 'c47' }) - ]) + const asAuthenticatedUser = await factory.authenticateAs({ email: 'commenter@example.org', password: '1234' }) + await asAuthenticatedUser.create('Post', createPostVariables) + await asAuthenticatedUser.create('Comment', createCommentVariables) } }) @@ -277,17 +283,21 @@ describe('enable', () => { variables = { id: 'c456' } - + createPostVariables = { + id: 'p9', + title: 'post to comment on', + content: 'please comment on me' + } + createCommentVariables = { + id: 'c456', + postId: 'p9', + content: 'this comment was created for this post' + } createResource = async () => { await factory.create('User', { id: 'u123', email: 'author@example.org', password: '1234' }) - await factory.authenticateAs({ email: 'author@example.org', password: '1234' }) - await Promise.all([ - factory.create('Post', { id: 'p9' }), - factory.create('Comment', { id: 'c456' }) - ]) - await Promise.all([ - factory.relate('Comment', 'Author', { from: 'u123', to: 'c456' }) - ]) + const asAuthenticatedUser = await factory.authenticateAs({ email: 'author@example.org', password: '1234' }) + await asAuthenticatedUser.create('Post', createPostVariables) + await asAuthenticatedUser.create('Comment', createCommentVariables) const disableMutation = ` mutation { diff --git a/backend/src/resolvers/reports.spec.js b/backend/src/resolvers/reports.spec.js index ae8894572..9bd1fe753 100644 --- a/backend/src/resolvers/reports.spec.js +++ b/backend/src/resolvers/reports.spec.js @@ -9,6 +9,7 @@ describe('report', () => { let headers let returnedObject let variables + let createPostVariables beforeEach(async () => { returnedObject = '{ description }' @@ -128,8 +129,14 @@ describe('report', () => { describe('reported resource is a comment', () => { beforeEach(async () => { - await factory.authenticateAs({ email: 'test@example.org', password: '1234' }) - await factory.create('Comment', { id: 'c34', content: 'Robert getting tired.' }) + createPostVariables = { + id: 'p1', + title: 'post to comment on', + content: 'please comment on me' + } + const asAuthenticatedUser = await factory.authenticateAs({ email: 'test@example.org', password: '1234' }) + await asAuthenticatedUser.create('Post', createPostVariables) + await asAuthenticatedUser.create('Comment', { postId: 'p1', id: 'c34', content: 'Robert getting tired.' }) variables = { id: 'c34' } }) From 0beb2d1763c2c81296a18346bf92c2cb5d652bcb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 6 May 2019 04:46:30 +0000 Subject: [PATCH 31/82] Bump neo4j-driver from 1.7.3 to 1.7.4 in /backend Bumps [neo4j-driver](https://github.com/neo4j/neo4j-javascript-driver) from 1.7.3 to 1.7.4. - [Release notes](https://github.com/neo4j/neo4j-javascript-driver/releases) - [Commits](https://github.com/neo4j/neo4j-javascript-driver/compare/1.7.3...1.7.4) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/backend/package.json b/backend/package.json index 7e972d0e6..a70d4c925 100644 --- a/backend/package.json +++ b/backend/package.json @@ -58,7 +58,7 @@ "linkifyjs": "~2.1.8", "lodash": "~4.17.11", "ms": "~2.1.1", - "neo4j-driver": "~1.7.3", + "neo4j-driver": "~1.7.4", "neo4j-graphql-js": "~2.4.2", "node-fetch": "~2.4.1", "npm-run-all": "~4.1.5", diff --git a/backend/yarn.lock b/backend/yarn.lock index fab84f08e..19b86530d 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -5588,10 +5588,10 @@ negotiator@0.6.1: resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.1.tgz#2b327184e8992101177b28563fb5e7102acd0ca9" integrity sha1-KzJxhOiZIQEXeyhWP7XnECrNDKk= -neo4j-driver@^1.7.2, neo4j-driver@~1.7.3: - version "1.7.3" - resolved "https://registry.yarnpkg.com/neo4j-driver/-/neo4j-driver-1.7.3.tgz#1c1108ab26b7243975f1b20045daf31d8f685207" - integrity sha512-UCNOFiQdouq14PvZGTr+psy657BJsBpO6O2cJpP+NprZnEF4APrDzAcydPZSFxE1nfooLNc50vfuZ0q54UyY2Q== +neo4j-driver@^1.7.2, neo4j-driver@~1.7.4: + version "1.7.4" + resolved "https://registry.yarnpkg.com/neo4j-driver/-/neo4j-driver-1.7.4.tgz#9661cf643b63818bff85e82c4691918e75098c1e" + integrity sha512-pbK1HbXh92zNSwMlXL8aNynkHohg9Jx/Tk+EewdJawGm8n8sKIY4NpRkp0nRw6RHvVBU3u9cQXt01ftFVe7j+A== dependencies: babel-runtime "^6.26.0" text-encoding "^0.6.4" From c046524b8f87f09089974bc9ef4b0445eab47400 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 6 May 2019 04:59:48 +0000 Subject: [PATCH 32/82] Bump babel-jest from 24.7.1 to 24.8.0 in /webapp Bumps [babel-jest](https://github.com/facebook/jest/tree/HEAD/packages/babel-jest) from 24.7.1 to 24.8.0. - [Release notes](https://github.com/facebook/jest/releases) - [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md) - [Commits](https://github.com/facebook/jest/commits/v24.8.0/packages/babel-jest) Signed-off-by: dependabot[bot] --- webapp/package.json | 2 +- webapp/yarn.lock | 131 ++++++++++++++++++++++++++++++++++++++------ 2 files changed, 115 insertions(+), 18 deletions(-) diff --git a/webapp/package.json b/webapp/package.json index c0ae69579..67673da56 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -68,7 +68,7 @@ "@vue/test-utils": "~1.0.0-beta.29", "babel-core": "~7.0.0-bridge.0", "babel-eslint": "~10.0.1", - "babel-jest": "~24.7.1", + "babel-jest": "~24.8.0", "eslint": "~5.16.0", "eslint-config-prettier": "~4.2.0", "eslint-loader": "~2.1.2", diff --git a/webapp/yarn.lock b/webapp/yarn.lock index 7f0d207f2..daac89557 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -831,6 +831,15 @@ jest-message-util "^24.7.1" jest-mock "^24.7.0" +"@jest/fake-timers@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-24.8.0.tgz#2e5b80a4f78f284bcb4bd5714b8e10dd36a8d3d1" + integrity sha512-2M4d5MufVXwi6VzZhJ9f5S/wU4ud2ck0kxPof1Iz3zWx6Y+V2eJrES9jEktB6O3o/oEyk+il/uNu9PvASjWXQw== + dependencies: + "@jest/types" "^24.8.0" + jest-message-util "^24.8.0" + jest-mock "^24.8.0" + "@jest/reporters@^24.7.1": version "24.7.1" resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-24.7.1.tgz#38ac0b096cd691bbbe3051ddc25988d42e37773a" @@ -875,6 +884,15 @@ "@jest/types" "^24.7.0" "@types/istanbul-lib-coverage" "^2.0.0" +"@jest/test-result@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-24.8.0.tgz#7675d0aaf9d2484caa65e048d9b467d160f8e9d3" + integrity sha512-+YdLlxwizlfqkFDh7Mc7ONPQAhA4YylU1s529vVM1rsf67vGZH/2GGm5uO8QzPeVyaVMobCQ7FTxl38QrKRlng== + dependencies: + "@jest/console" "^24.7.1" + "@jest/types" "^24.8.0" + "@types/istanbul-lib-coverage" "^2.0.0" + "@jest/test-sequencer@^24.7.1": version "24.7.1" resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-24.7.1.tgz#9c18e428e1ad945fa74f6233a9d35745ca0e63e0" @@ -885,33 +903,34 @@ jest-runner "^24.7.1" jest-runtime "^24.7.1" -"@jest/transform@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-24.7.1.tgz#872318f125bcfab2de11f53b465ab1aa780789c2" - integrity sha512-EsOUqP9ULuJ66IkZQhI5LufCHlTbi7hrcllRMUEV/tOgqBVQi93+9qEvkX0n8mYpVXQ8VjwmICeRgg58mrtIEw== +"@jest/transform@^24.7.1", "@jest/transform@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-24.8.0.tgz#628fb99dce4f9d254c6fd9341e3eea262e06fef5" + integrity sha512-xBMfFUP7TortCs0O+Xtez2W7Zu1PLH9bvJgtraN1CDST6LBM/eTOZ9SfwS/lvV8yOfcDpFmwf9bq5cYbXvqsvA== dependencies: "@babel/core" "^7.1.0" - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" babel-plugin-istanbul "^5.1.0" chalk "^2.0.1" convert-source-map "^1.4.0" fast-json-stable-stringify "^2.0.0" graceful-fs "^4.1.15" - jest-haste-map "^24.7.1" + jest-haste-map "^24.8.0" jest-regex-util "^24.3.0" - jest-util "^24.7.1" + jest-util "^24.8.0" micromatch "^3.1.10" realpath-native "^1.1.0" slash "^2.0.0" source-map "^0.6.1" write-file-atomic "2.4.1" -"@jest/types@^24.7.0": - version "24.7.0" - resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.7.0.tgz#c4ec8d1828cdf23234d9b4ee31f5482a3f04f48b" - integrity sha512-ipJUa2rFWiKoBqMKP63Myb6h9+iT3FHRTF2M8OR6irxWzItisa8i4dcSg14IbvmXUnBlHBlUQPYUHWyX3UPpYA== +"@jest/types@^24.7.0", "@jest/types@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.8.0.tgz#f31e25948c58f0abd8c845ae26fcea1491dea7ad" + integrity sha512-g17UxVr2YfBtaMUxn9u/4+siG1ptg9IGYAYwvpwn61nBg779RXnjE/m7CxYcIzEt0AbHZZAHSEZNhkE2WxURVg== dependencies: "@types/istanbul-lib-coverage" "^2.0.0" + "@types/istanbul-reports" "^1.1.1" "@types/yargs" "^12.0.9" "@nuxt/babel-preset-app@2.6.3": @@ -1350,11 +1369,31 @@ "@types/express-serve-static-core" "*" "@types/serve-static" "*" +"@types/istanbul-lib-coverage@*": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.1.tgz#42995b446db9a48a11a07ec083499a860e9138ff" + integrity sha512-hRJD2ahnnpLgsj6KWMYSrmXkM3rm2Dl1qkx6IOFD5FnuNPXJIG5L0dhgKXCYTRMGzU4n0wImQ/xfmRc4POUFlg== + "@types/istanbul-lib-coverage@^2.0.0": version "2.0.0" resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.0.tgz#1eb8c033e98cf4e1a4cedcaf8bcafe8cb7591e85" integrity sha512-eAtOAFZefEnfJiRFQBGw1eYqa5GTLCZ1y86N0XSI/D6EB+E8z6VPV/UL7Gi5UEclFqoQk+6NRqEDsfmDLXn8sg== +"@types/istanbul-lib-report@*": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-report/-/istanbul-lib-report-1.1.1.tgz#e5471e7fa33c61358dd38426189c037a58433b8c" + integrity sha512-3BUTyMzbZa2DtDI2BkERNC6jJw2Mr2Y0oGI7mRxYNBPxppbtEK1F66u3bKwU2g+wxwWI7PAoRpJnOY1grJqzHg== + dependencies: + "@types/istanbul-lib-coverage" "*" + +"@types/istanbul-reports@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-1.1.1.tgz#7a8cbf6a406f36c8add871625b278eaf0b0d255a" + integrity sha512-UpYjBi8xefVChsCoBpKShdxTllC9pwISirfoZsUa2AAdQg/Jd2KQGtSbw+ya7GPo7x/wAPlH6JBhKhAsXUEZNA== + dependencies: + "@types/istanbul-lib-coverage" "*" + "@types/istanbul-lib-report" "*" + "@types/long@^4.0.0": version "4.0.0" resolved "https://registry.yarnpkg.com/@types/long/-/long-4.0.0.tgz#719551d2352d301ac8b81db732acb6bdc28dbdef" @@ -2322,13 +2361,13 @@ babel-eslint@~10.0.1: eslint-scope "3.7.1" eslint-visitor-keys "^1.0.0" -babel-jest@^24.7.1, babel-jest@~24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-24.7.1.tgz#73902c9ff15a7dfbdc9994b0b17fcefd96042178" - integrity sha512-GPnLqfk8Mtt0i4OemjWkChi73A3ALs4w2/QbG64uAj8b5mmwzxc7jbJVRZt8NJkxi6FopVHog9S3xX6UJKb2qg== +babel-jest@^24.7.1, babel-jest@~24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-24.8.0.tgz#5c15ff2b28e20b0f45df43fe6b7f2aae93dba589" + integrity sha512-+5/kaZt4I9efoXzPlZASyK/lN9qdRKmmUav9smVc0ruPQD7IsfucQ87gpOE8mn2jbDuS6M/YOW6n3v9ZoIfgnw== dependencies: - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" "@types/babel__core" "^7.1.0" babel-plugin-istanbul "^5.1.0" babel-preset-jest "^24.6.0" @@ -6168,6 +6207,25 @@ jest-haste-map@^24.7.1: optionalDependencies: fsevents "^1.2.7" +jest-haste-map@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.8.0.tgz#51794182d877b3ddfd6e6d23920e3fe72f305800" + integrity sha512-ZBPRGHdPt1rHajWelXdqygIDpJx8u3xOoLyUBWRW28r3tagrgoepPrzAozW7kW9HrQfhvmiv1tncsxqHJO1onQ== + dependencies: + "@jest/types" "^24.8.0" + anymatch "^2.0.0" + fb-watchman "^2.0.0" + graceful-fs "^4.1.15" + invariant "^2.2.4" + jest-serializer "^24.4.0" + jest-util "^24.8.0" + jest-worker "^24.6.0" + micromatch "^3.1.10" + sane "^4.0.3" + walker "^1.0.7" + optionalDependencies: + fsevents "^1.2.7" + jest-jasmine2@^24.7.1: version "24.7.1" resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-24.7.1.tgz#01398686dabe46553716303993f3be62e5d9d818" @@ -6221,6 +6279,20 @@ jest-message-util@^24.7.1: slash "^2.0.0" stack-utils "^1.0.1" +jest-message-util@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-24.8.0.tgz#0d6891e72a4beacc0292b638685df42e28d6218b" + integrity sha512-p2k71rf/b6ns8btdB0uVdljWo9h0ovpnEe05ZKWceQGfXYr4KkzgKo3PBi8wdnd9OtNh46VpNIJynUn/3MKm1g== + dependencies: + "@babel/code-frame" "^7.0.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" + "@types/stack-utils" "^1.0.1" + chalk "^2.0.1" + micromatch "^3.1.10" + slash "^2.0.0" + stack-utils "^1.0.1" + jest-mock@^24.7.0: version "24.7.0" resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.7.0.tgz#e49ce7262c12d7f5897b0d8af77f6db8e538023b" @@ -6228,6 +6300,13 @@ jest-mock@^24.7.0: dependencies: "@jest/types" "^24.7.0" +jest-mock@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.8.0.tgz#2f9d14d37699e863f1febf4e4d5a33b7fdbbde56" + integrity sha512-6kWugwjGjJw+ZkK4mDa0Df3sDlUTsV47MSrT0nGQ0RBWJbpODDQ8MHDVtGtUYBne3IwZUhtB7elxHspU79WH3A== + dependencies: + "@jest/types" "^24.8.0" + jest-pnp-resolver@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/jest-pnp-resolver/-/jest-pnp-resolver-1.2.1.tgz#ecdae604c077a7fbc70defb6d517c3c1c898923a" @@ -6353,6 +6432,24 @@ jest-util@^24.7.1: slash "^2.0.0" source-map "^0.6.0" +jest-util@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-24.8.0.tgz#41f0e945da11df44cc76d64ffb915d0716f46cd1" + integrity sha512-DYZeE+XyAnbNt0BG1OQqKy/4GVLPtzwGx5tsnDrFcax36rVE3lTA5fbvgmbVPUZf9w77AJ8otqR4VBbfFJkUZA== + dependencies: + "@jest/console" "^24.7.1" + "@jest/fake-timers" "^24.8.0" + "@jest/source-map" "^24.3.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" + callsites "^3.0.0" + chalk "^2.0.1" + graceful-fs "^4.1.15" + is-ci "^2.0.0" + mkdirp "^0.5.1" + slash "^2.0.0" + source-map "^0.6.0" + jest-validate@^24.7.0: version "24.7.0" resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-24.7.0.tgz#70007076f338528ee1b1c8a8258b1b0bb982508d" From 41711c316acf1d531dc3ae349d7640e909b49f6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Mon, 6 May 2019 17:31:02 +0200 Subject: [PATCH 33/82] Get delete SocialMedia to work, refactored Frontend Jest tests, written Cypress tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Optimised tests and Vue for add Social Media a bit. Added localisation. Finished this commit together with @mattwr18 !!! Thank you so much dude! You did great stuff … --- backend/src/resolvers/socialMedia.spec.js | 8 ++-- cypress/integration/common/settings.js | 19 +++++++- .../user_profile/SocialMedia.feature | 9 ++++ webapp/locales/de.json | 4 +- webapp/locales/en.json | 4 +- webapp/pages/settings/my-social-media.spec.js | 4 +- webapp/pages/settings/my-social-media.vue | 44 ++++++++++++++++--- 7 files changed, 75 insertions(+), 17 deletions(-) diff --git a/backend/src/resolvers/socialMedia.spec.js b/backend/src/resolvers/socialMedia.spec.js index b09dae178..9d1d76726 100644 --- a/backend/src/resolvers/socialMedia.spec.js +++ b/backend/src/resolvers/socialMedia.spec.js @@ -68,11 +68,11 @@ describe('CreateSocialMedia', () => { }) it('deletes social media', async () => { - const variablesC = { url: 'http://nsosp.org' } - const { CreateSocialMedia } = await client.request(mutationC, variablesC) + const creationVariables = { url: 'http://nsosp.org' } + const { CreateSocialMedia } = await client.request(mutationC, creationVariables) const { id } = CreateSocialMedia - const variablesD = { id } + const deletionVariables = { id } const expected = { DeleteSocialMedia: { id: id, @@ -80,7 +80,7 @@ describe('CreateSocialMedia', () => { } } await expect( - client.request(mutationD, variablesD) + client.request(mutationD, deletionVariables) ).resolves.toEqual(expected) }) diff --git a/cypress/integration/common/settings.js b/cypress/integration/common/settings.js index e1f3cc5a8..fa2962dfb 100644 --- a/cypress/integration/common/settings.js +++ b/cypress/integration/common/settings.js @@ -77,7 +77,7 @@ Then('I should be on the {string} page', page => { .should('contain', 'Social media') }) -Then('I add a social media link', () => { +When('I add a social media link', () => { cy.get("input[name='social-media']") .type('https://freeradical.zone/peter-pan') .get('button') @@ -87,7 +87,7 @@ Then('I add a social media link', () => { Then('it gets saved successfully', () => { cy.get('.iziToast-message') - .should('contain', 'Updated user') + .should('contain', 'Added social media') }) Then('the new social media link shows up on the page', () => { @@ -110,3 +110,18 @@ Then('they should be able to see my social media links', () => { .get('a[href="https://freeradical.zone/peter-pan"]') .should('have.length', 1) }) + +When('I delete a social media link', () => { + cy.get("a[name='delete']") + .click() +}) + +// Then('Shows delete modal', () => { +// cy.get("a[name='delete']") +// .click() +// }) + +Then('it gets deleted successfully', () => { + cy.get('.iziToast-message') + .should('contain', 'Deleted social media') +}) diff --git a/cypress/integration/user_profile/SocialMedia.feature b/cypress/integration/user_profile/SocialMedia.feature index 988923c17..4466b9537 100644 --- a/cypress/integration/user_profile/SocialMedia.feature +++ b/cypress/integration/user_profile/SocialMedia.feature @@ -19,3 +19,12 @@ Feature: List Social Media Accounts Given I have added a social media link When people visit my profile page Then they should be able to see my social media links + + Scenario: Deleting Social Media + Given I am on the "settings" page + And I click on the "Social media" link + Then I should be on the "/settings/my-social-media" page + Given I have added a social media link + When I delete a social media link + Then it gets deleted successfully + # And the new social media link shows up on the page diff --git a/webapp/locales/de.json b/webapp/locales/de.json index 7e69b5bbb..0d079cc15 100644 --- a/webapp/locales/de.json +++ b/webapp/locales/de.json @@ -63,8 +63,10 @@ }, "social-media": { "name": "Soziale Medien", + "placeholder": "Füge eine Social-Media URL hinzu", "submit": "Link hinzufügen", - "success": "Profil aktualisiert" + "successAdd": "Social-Media hinzugefügt. Profil aktualisiert!", + "successDelete": "Social-Media gelöscht. Profil aktualisiert!" } }, "admin": { diff --git a/webapp/locales/en.json b/webapp/locales/en.json index 02bea7bae..65074e667 100644 --- a/webapp/locales/en.json +++ b/webapp/locales/en.json @@ -63,8 +63,10 @@ }, "social-media": { "name": "Social media", + "placeholder": "Add social media url", "submit": "Add link", - "success": "Updated user profile" + "successAdd": "Added social media. Updated user profile!", + "successDelete": "Deleted social media. Updated user profile!" } }, "admin": { diff --git a/webapp/pages/settings/my-social-media.spec.js b/webapp/pages/settings/my-social-media.spec.js index b8c2f8182..673c1cd70 100644 --- a/webapp/pages/settings/my-social-media.spec.js +++ b/webapp/pages/settings/my-social-media.spec.js @@ -74,8 +74,8 @@ describe('my-social-media.vue', () => { it('displays a trash sympol after a social media', () => { wrapper = Wrapper() - iconName = wrapper.find('.ds-icon').attributes().name - expect(iconName).toBe('trash') + const deleteSelector = wrapper.find({ name: 'delete' }) + expect(deleteSelector).toEqual({ selector: 'Component' }) }) }) diff --git a/webapp/pages/settings/my-social-media.vue b/webapp/pages/settings/my-social-media.vue index 5b3914ff0..d0d805730 100644 --- a/webapp/pages/settings/my-social-media.vue +++ b/webapp/pages/settings/my-social-media.vue @@ -8,7 +8,7 @@
{{ link.url }} -    |    +    |    @@ -95,6 +95,7 @@ export default { mutation: gql` mutation($url: String!) { CreateSocialMedia(url: $url) { + id url } } @@ -113,13 +114,42 @@ export default { }) } }) - .then( - this.$toast.success(this.$t('settings.social-media.success')), + .then(() => { + this.$toast.success(this.$t('settings.social-media.successAdd')), (this.value = '') - ) + }) + .catch(error => { + this.$toast.error(error.message) + }) }, handleDeleteSocialMedia(link) { - console.log(link) + this.$apollo + .mutate({ + mutation: gql` + mutation($id: ID!) { + DeleteSocialMedia(id: $id) { + id + url + } + } + `, + variables: { + id: link.id + }, + update: (store, { data }) => { + const socialMedia = this.currentUser.socialMedia.filter(element => element.id !== link.id ) + this.setCurrentUser({ + ...this.currentUser, + socialMedia + }) + } + }) + .then(() => { + this.$toast.success(this.$t('settings.social-media.successDelete')) + }) + .catch(error => { + this.$toast.error(error.message) + }) } } } From 1ef1b7ef3da5a4318b1ad5486c422a4560900604 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 6 May 2019 21:07:42 +0000 Subject: [PATCH 34/82] Bump helmet from 3.16.0 to 3.18.0 in /backend Bumps [helmet](https://github.com/helmetjs/helmet) from 3.16.0 to 3.18.0. - [Release notes](https://github.com/helmetjs/helmet/releases) - [Changelog](https://github.com/helmetjs/helmet/blob/master/CHANGELOG.md) - [Commits](https://github.com/helmetjs/helmet/compare/v3.16.0...v3.18.0) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 58 ++++++++++++++++++++++---------------------- 2 files changed, 30 insertions(+), 30 deletions(-) diff --git a/backend/package.json b/backend/package.json index 2a02a2b89..e3c4300f0 100644 --- a/backend/package.json +++ b/backend/package.json @@ -53,7 +53,7 @@ "graphql-shield": "~5.3.5", "graphql-tag": "~2.10.1", "graphql-yoga": "~1.17.4", - "helmet": "~3.16.0", + "helmet": "~3.18.0", "jsonwebtoken": "~8.5.1", "linkifyjs": "~2.1.8", "lodash": "~4.17.11", diff --git a/backend/yarn.lock b/backend/yarn.lock index 4dccfd39d..c4e51c3be 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -3232,10 +3232,10 @@ expand-brackets@^2.1.4: snapdragon "^0.8.1" to-regex "^3.0.1" -expect-ct@0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/expect-ct/-/expect-ct-0.1.1.tgz#de84476a2dbcb85000d5903737e9bc8a5ba7b897" - integrity sha512-ngXzTfoRGG7fYens3/RMb6yYoVLvLMfmsSllP/mZPxNHgFq41TmPSLF/nLY7fwoclI2vElvAmILFWGUYqdjfCg== +expect-ct@0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/expect-ct/-/expect-ct-0.2.0.tgz#3a54741b6ed34cc7a93305c605f63cd268a54a62" + integrity sha512-6SK3MG/Bbhm8MsgyJAylg+ucIOU71/FzyFalcfu5nY19dH8y/z0tBJU0wrNBXD4B27EoQtqPF/9wqH0iYAd04g== expect@^24.7.1: version "24.7.1" @@ -3370,10 +3370,10 @@ fb-watchman@^2.0.0: dependencies: bser "^2.0.0" -feature-policy@0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/feature-policy/-/feature-policy-0.2.0.tgz#22096de49ab240176878ffe2bde2f6ff04d48c43" - integrity sha512-2hGrlv6efG4hscYVZeaYjpzpT6I2OZgYqE2yDUzeAcKj2D1SH0AsEzqJNXzdoglEddcIXQQYop3lD97XpG75Jw== +feature-policy@0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/feature-policy/-/feature-policy-0.3.0.tgz#7430e8e54a40da01156ca30aaec1a381ce536069" + integrity sha512-ZtijOTFN7TzCujt1fnNhfWPFPSHeZkesff9AXZj+UEjYBynWNUIYpC87Ve4wHzyexQsImicLu7WsC2LHq7/xrQ== figures@2.0.0, figures@^2.0.0: version "2.0.0" @@ -3498,10 +3498,10 @@ fragment-cache@^0.2.1: dependencies: map-cache "^0.2.2" -frameguard@3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/frameguard/-/frameguard-3.0.0.tgz#7bcad469ee7b96e91d12ceb3959c78235a9272e9" - integrity sha1-e8rUae57lukdEs6zlZx4I1qScuk= +frameguard@3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/frameguard/-/frameguard-3.1.0.tgz#bd1442cca1d67dc346a6751559b6d04502103a22" + integrity sha512-TxgSKM+7LTA6sidjOiSZK9wxY0ffMPY3Wta//MqwmX0nZuEHc8QrkV8Fh3ZhMJeiH+Uyh/tcaarImRy8u77O7g== fresh@0.5.2: version "0.5.2" @@ -3946,25 +3946,25 @@ helmet-csp@2.7.1: dasherize "2.0.0" platform "1.3.5" -helmet@~3.16.0: - version "3.16.0" - resolved "https://registry.yarnpkg.com/helmet/-/helmet-3.16.0.tgz#7df41a4bfe4c83d90147c1e30d70893f92a9d97c" - integrity sha512-rsTKRogc5OYGlvSHuq5QsmOsOzF6uDoMqpfh+Np8r23+QxDq+SUx90Rf8HyIKQVl7H6NswZEwfcykinbAeZ6UQ== +helmet@~3.18.0: + version "3.18.0" + resolved "https://registry.yarnpkg.com/helmet/-/helmet-3.18.0.tgz#37666f7c861bd1ff3015e0cdb903a43501e3da3e" + integrity sha512-TsKlGE5UVkV0NiQ4PllV9EVfZklPjyzcMEMjWlyI/8S6epqgRT+4s4GHVgc25x0TixsKvp3L7c91HQQt5l0+QA== dependencies: depd "2.0.0" dns-prefetch-control "0.1.0" dont-sniff-mimetype "1.0.0" - expect-ct "0.1.1" - feature-policy "0.2.0" - frameguard "3.0.0" + expect-ct "0.2.0" + feature-policy "0.3.0" + frameguard "3.1.0" helmet-crossdomain "0.3.0" helmet-csp "2.7.1" hide-powered-by "1.0.0" hpkp "2.0.0" hsts "2.2.0" ienoopen "1.1.0" - nocache "2.0.0" - referrer-policy "1.1.0" + nocache "2.1.0" + referrer-policy "1.2.0" x-xss-protection "1.1.0" hide-powered-by@1.0.0: @@ -5624,10 +5624,10 @@ no-case@^2.2.0: dependencies: lower-case "^1.1.1" -nocache@2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/nocache/-/nocache-2.0.0.tgz#202b48021a0c4cbde2df80de15a17443c8b43980" - integrity sha1-ICtIAhoMTL3i34DeFaF0Q8i0OYA= +nocache@2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/nocache/-/nocache-2.1.0.tgz#120c9ffec43b5729b1d5de88cd71aa75a0ba491f" + integrity sha512-0L9FvHG3nfnnmaEQPjT9xhfN4ISk0A8/2j4M37Np4mcDesJjHgEUfgPhdCyZuFI954tjokaIj/A3NdpFNdEh4Q== node-fetch@2.1.2: version "2.1.2" @@ -6492,10 +6492,10 @@ reasoner@2.0.0: vocabs-rdfs "^0.11.1" vocabs-xsd "^0.11.1" -referrer-policy@1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/referrer-policy/-/referrer-policy-1.1.0.tgz#35774eb735bf50fb6c078e83334b472350207d79" - integrity sha1-NXdOtzW/UPtsB46DM0tHI1AgfXk= +referrer-policy@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/referrer-policy/-/referrer-policy-1.2.0.tgz#b99cfb8b57090dc454895ef897a4cc35ef67a98e" + integrity sha512-LgQJIuS6nAy1Jd88DCQRemyE3mS+ispwlqMk3b0yjZ257fI1v9c+/p6SD5gP5FGyXUIgrNOAfmyioHwZtYv2VA== regenerate-unicode-properties@^8.0.2: version "8.0.2" From a58258c6688e636f41b3c4b2265f0f1e170524f0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 6 May 2019 21:08:52 +0000 Subject: [PATCH 35/82] Bump node-sass from 4.11.0 to 4.12.0 in /webapp Bumps [node-sass](https://github.com/sass/node-sass) from 4.11.0 to 4.12.0. - [Release notes](https://github.com/sass/node-sass/releases) - [Changelog](https://github.com/sass/node-sass/blob/master/CHANGELOG.md) - [Commits](https://github.com/sass/node-sass/compare/v4.11.0...v4.12.0) Signed-off-by: dependabot[bot] --- webapp/package.json | 2 +- webapp/yarn.lock | 37 ++++++++++--------------------------- 2 files changed, 11 insertions(+), 28 deletions(-) diff --git a/webapp/package.json b/webapp/package.json index f0d455558..1a6515c34 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -76,7 +76,7 @@ "eslint-plugin-vue": "~5.2.2", "fuse.js": "^3.4.4", "jest": "~24.7.1", - "node-sass": "~4.11.0", + "node-sass": "~4.12.0", "nodemon": "~1.19.0", "prettier": "~1.14.3", "sass-loader": "~7.1.0", diff --git a/webapp/yarn.lock b/webapp/yarn.lock index b1d5fb255..c113ee306 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -6866,16 +6866,6 @@ lodash._reinterpolate@~3.0.0: resolved "https://registry.yarnpkg.com/lodash._reinterpolate/-/lodash._reinterpolate-3.0.0.tgz#0ccf2d89166af03b3663c796538b75ac6e114d9d" integrity sha1-DM8tiRZq8Ds2Y8eWU4t1rG4RTZ0= -lodash.assign@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-4.2.0.tgz#0d99f3ccd7a6d261d19bdaeb9245005d285808e7" - integrity sha1-DZnzzNem0mHRm9rrkkUAXShYCOc= - -lodash.clonedeep@^4.3.2: - version "4.5.0" - resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" - integrity sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8= - lodash.includes@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/lodash.includes/-/lodash.includes-4.3.0.tgz#60bb98a87cb923c68ca1e51325483314849f553f" @@ -6916,11 +6906,6 @@ lodash.memoize@^4.1.2: resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe" integrity sha1-vMbEmkKihA7Zl/Mj6tpezRguC/4= -lodash.mergewith@^4.6.0: - version "4.6.1" - resolved "https://registry.yarnpkg.com/lodash.mergewith/-/lodash.mergewith-4.6.1.tgz#639057e726c3afbdb3e7d42741caa8d6e4335927" - integrity sha512-eWw5r+PYICtEBgrBE5hhlT6aAa75f411bgDz/ZL2KZqYV03USvucsxcHUIlGTDTECs1eunpI7HOV7U+WLDvNdQ== - lodash.once@^4.0.0: version "4.1.1" resolved "https://registry.yarnpkg.com/lodash.once/-/lodash.once-4.1.1.tgz#0dd3971213c7c56df880977d504c88fb471a97ac" @@ -7332,10 +7317,10 @@ mute-stream@0.0.7: resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= -nan@^2.10.0, nan@^2.9.2: - version "2.12.1" - resolved "https://registry.yarnpkg.com/nan/-/nan-2.12.1.tgz#7b1aa193e9aa86057e3c7bbd0ac448e770925552" - integrity sha512-JY7V6lRkStKcKTvHO5NVSQRv+RV+FIL5pvDoLiAtSL9pKlC5x9PKQcZDsq7m4FO4d57mkhC6Z+QhAh3Jdk5JFw== +nan@^2.13.2, nan@^2.9.2: + version "2.13.2" + resolved "https://registry.yarnpkg.com/nan/-/nan-2.13.2.tgz#f51dc7ae66ba7d5d55e1e6d4d8092e802c9aefe7" + integrity sha512-TghvYc72wlMGMVMluVo9WRJc0mB8KxxF/gZ4YYFy7V2ZQX9l7rgbPg7vjS9mt6U5HXODVFVI2bOduCzwOMv/lw== nanomatch@^1.2.9: version "1.2.13" @@ -7516,10 +7501,10 @@ node-releases@^1.1.13: dependencies: semver "^5.3.0" -node-sass@~4.11.0: - version "4.11.0" - resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.11.0.tgz#183faec398e9cbe93ba43362e2768ca988a6369a" - integrity sha512-bHUdHTphgQJZaF1LASx0kAviPH7sGlcyNhWade4eVIpFp6tsn7SV8xNMTbsQFpEV9VXpnwTTnNYlfsZXgGgmkA== +node-sass@~4.12.0: + version "4.12.0" + resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.12.0.tgz#0914f531932380114a30cc5fa4fa63233a25f017" + integrity sha512-A1Iv4oN+Iel6EPv77/HddXErL2a+gZ4uBeZUy+a8O35CFYTXhgA8MgLCWBtwpGZdCvTvQ9d+bQxX/QC36GDPpQ== dependencies: async-foreach "^0.1.3" chalk "^1.1.1" @@ -7528,12 +7513,10 @@ node-sass@~4.11.0: get-stdin "^4.0.1" glob "^7.0.3" in-publish "^2.0.0" - lodash.assign "^4.2.0" - lodash.clonedeep "^4.3.2" - lodash.mergewith "^4.6.0" + lodash "^4.17.11" meow "^3.7.0" mkdirp "^0.5.1" - nan "^2.10.0" + nan "^2.13.2" node-gyp "^3.8.0" npmlog "^4.0.0" request "^2.88.0" From fc7d8a5c6c544966395c2b9ec86c1711b988a426 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 6 May 2019 21:08:57 +0000 Subject: [PATCH 36/82] Bump neo4j-driver from 1.7.3 to 1.7.4 Bumps [neo4j-driver](https://github.com/neo4j/neo4j-javascript-driver) from 1.7.3 to 1.7.4. - [Release notes](https://github.com/neo4j/neo4j-javascript-driver/releases) - [Commits](https://github.com/neo4j/neo4j-javascript-driver/compare/1.7.3...1.7.4) Signed-off-by: dependabot[bot] --- package.json | 2 +- yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 703997ee1..0eb343e0d 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "dotenv": "^7.0.0", "faker": "^4.1.0", "graphql-request": "^1.8.2", - "neo4j-driver": "^1.7.3", + "neo4j-driver": "^1.7.4", "npm-run-all": "^4.1.5" } } diff --git a/yarn.lock b/yarn.lock index 1d7745f03..6f8bc6716 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3473,10 +3473,10 @@ needle@^2.2.1: iconv-lite "^0.4.4" sax "^1.2.4" -neo4j-driver@^1.7.3: - version "1.7.3" - resolved "https://registry.yarnpkg.com/neo4j-driver/-/neo4j-driver-1.7.3.tgz#1c1108ab26b7243975f1b20045daf31d8f685207" - integrity sha512-UCNOFiQdouq14PvZGTr+psy657BJsBpO6O2cJpP+NprZnEF4APrDzAcydPZSFxE1nfooLNc50vfuZ0q54UyY2Q== +neo4j-driver@^1.7.4: + version "1.7.4" + resolved "https://registry.yarnpkg.com/neo4j-driver/-/neo4j-driver-1.7.4.tgz#9661cf643b63818bff85e82c4691918e75098c1e" + integrity sha512-pbK1HbXh92zNSwMlXL8aNynkHohg9Jx/Tk+EewdJawGm8n8sKIY4NpRkp0nRw6RHvVBU3u9cQXt01ftFVe7j+A== dependencies: babel-runtime "^6.26.0" text-encoding "^0.6.4" From d255a165b4a38e821cc8ab4c4396624b291bf086 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Tue, 7 May 2019 00:49:48 +0200 Subject: [PATCH 37/82] Delete unused folder cypres/cypress/ Where did that come from? @mattwr18 --- cypress/cypress/plugins/index.js | 17 ----------------- cypress/cypress/support/commands.js | 25 ------------------------- cypress/cypress/support/index.js | 20 -------------------- 3 files changed, 62 deletions(-) delete mode 100644 cypress/cypress/plugins/index.js delete mode 100644 cypress/cypress/support/commands.js delete mode 100644 cypress/cypress/support/index.js diff --git a/cypress/cypress/plugins/index.js b/cypress/cypress/plugins/index.js deleted file mode 100644 index fd170fba6..000000000 --- a/cypress/cypress/plugins/index.js +++ /dev/null @@ -1,17 +0,0 @@ -// *********************************************************** -// This example plugins/index.js can be used to load plugins -// -// You can change the location of this file or turn off loading -// the plugins file with the 'pluginsFile' configuration option. -// -// You can read more here: -// https://on.cypress.io/plugins-guide -// *********************************************************** - -// This function is called when a project is opened or re-opened (e.g. due to -// the project's config changing) - -module.exports = (on, config) => { - // `on` is used to hook into various events Cypress emits - // `config` is the resolved Cypress config -} diff --git a/cypress/cypress/support/commands.js b/cypress/cypress/support/commands.js deleted file mode 100644 index c1f5a772e..000000000 --- a/cypress/cypress/support/commands.js +++ /dev/null @@ -1,25 +0,0 @@ -// *********************************************** -// This example commands.js shows you how to -// create various custom commands and overwrite -// existing commands. -// -// For more comprehensive examples of custom -// commands please read more here: -// https://on.cypress.io/custom-commands -// *********************************************** -// -// -// -- This is a parent command -- -// Cypress.Commands.add("login", (email, password) => { ... }) -// -// -// -- This is a child command -- -// Cypress.Commands.add("drag", { prevSubject: 'element'}, (subject, options) => { ... }) -// -// -// -- This is a dual command -- -// Cypress.Commands.add("dismiss", { prevSubject: 'optional'}, (subject, options) => { ... }) -// -// -// -- This is will overwrite an existing command -- -// Cypress.Commands.overwrite("visit", (originalFn, url, options) => { ... }) diff --git a/cypress/cypress/support/index.js b/cypress/cypress/support/index.js deleted file mode 100644 index a24e4442d..000000000 --- a/cypress/cypress/support/index.js +++ /dev/null @@ -1,20 +0,0 @@ -// *********************************************************** -// This example support/index.js is processed and -// loaded automatically before your test files. -// -// This is a great place to put global configuration and -// behavior that modifies Cypress. -// -// You can change the location of this file or turn off -// automatically serving support files with the -// 'supportFile' configuration option. -// -// You can read more here: -// https://on.cypress.io/configuration -// *********************************************************** - -// Import commands.js using ES2015 syntax: -import './commands' -require('cypress-plugin-retries') -// Alternatively you can use CommonJS syntax: -// require('./commands') From a1b74bef001ca24de30fa7e4596dbeb2c90ea567 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Tue, 7 May 2019 00:51:18 +0200 Subject: [PATCH 38/82] Configure 1 retry on Travis --- .travis.yml | 2 +- cypress/integration/common/report.js | 2 -- cypress/support/index.js | 5 +++++ 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index cd43b771f..632786285 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,7 +28,7 @@ script: - docker-compose exec webapp yarn run lint - docker-compose exec webapp yarn run test --ci --verbose=false - docker-compose exec -d backend yarn run test:before:seeder - - yarn run cypress:run + - CYPRESS_RETRIES=1 yarn run cypress:run after_success: - wget https://raw.githubusercontent.com/DiscordHooks/travis-ci-discord-webhook/master/send.sh diff --git a/cypress/integration/common/report.js b/cypress/integration/common/report.js index 519c8514b..2c8b848b4 100644 --- a/cypress/integration/common/report.js +++ b/cypress/integration/common/report.js @@ -1,6 +1,4 @@ import { Given, When, Then } from 'cypress-cucumber-preprocessor/steps' -// intermittent failing tests -Cypress.env('RETRIES', 2) /* global cy */ diff --git a/cypress/support/index.js b/cypress/support/index.js index 3519487bf..195b0de7d 100644 --- a/cypress/support/index.js +++ b/cypress/support/index.js @@ -14,8 +14,13 @@ // *********************************************************** // Import commands.js using ES2015 syntax: + import './commands' import './factories' +// intermittent failing tests +import 'cypress-plugin-retries' + // Alternatively you can use CommonJS syntax: // require('./commands') + From af56b7aa8104918d856e90e2284a25d17a145ce0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 6 May 2019 23:41:18 +0000 Subject: [PATCH 39/82] Bump dotenv from 7.0.0 to 8.0.0 Bumps [dotenv](https://github.com/motdotla/dotenv) from 7.0.0 to 8.0.0. - [Release notes](https://github.com/motdotla/dotenv/releases) - [Changelog](https://github.com/motdotla/dotenv/blob/master/CHANGELOG.md) - [Commits](https://github.com/motdotla/dotenv/compare/v7.0.0...v8.0.0) Signed-off-by: dependabot[bot] --- package.json | 2 +- yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index cf865e5a5..3d866c203 100644 --- a/package.json +++ b/package.json @@ -23,7 +23,7 @@ "cross-env": "^5.2.0", "cypress": "^3.2.0", "cypress-cucumber-preprocessor": "^1.11.0", - "dotenv": "^7.0.0", + "dotenv": "^8.0.0", "faker": "^4.1.0", "graphql-request": "^1.8.2", "neo4j-driver": "^1.7.4", diff --git a/yarn.lock b/yarn.lock index d6cf39004..31416a522 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2022,10 +2022,10 @@ domain-browser@^1.2.0: resolved "https://registry.yarnpkg.com/domain-browser/-/domain-browser-1.2.0.tgz#3d31f50191a6749dd1375a7f522e823d42e54eda" integrity sha512-jnjyiM6eRyZl2H+W8Q/zLMA481hzi0eszAaBUzIVnmYVDBbnLxVNnfu1HgEBvCbL+71FrxMl3E6lpKH7Ge3OXA== -dotenv@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-7.0.0.tgz#a2be3cd52736673206e8a85fb5210eea29628e7c" - integrity sha512-M3NhsLbV1i6HuGzBUH8vXrtxOk+tWmzWKDMbAVSUp3Zsjm7ywFeuwrUXhmhQyRK1q5B5GGy7hcXPbj3bnfZg2g== +dotenv@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-8.0.0.tgz#ed310c165b4e8a97bb745b0a9d99c31bda566440" + integrity sha512-30xVGqjLjiUOArT4+M5q9sYdvuR4riM6yK9wMcas9Vbp6zZa+ocC9dp6QoftuhTPhFAiLK/0C5Ni2nou/Bk8lg== duplexer2@^0.1.2, duplexer2@~0.1.0, duplexer2@~0.1.2: version "0.1.4" From 42016178c5ccae7d1ac38aa8c46eef34c20d2ae4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 6 May 2019 23:42:06 +0000 Subject: [PATCH 40/82] Bump node-fetch from 2.4.1 to 2.5.0 in /backend Bumps [node-fetch](https://github.com/bitinn/node-fetch) from 2.4.1 to 2.5.0. - [Release notes](https://github.com/bitinn/node-fetch/releases) - [Changelog](https://github.com/bitinn/node-fetch/blob/master/CHANGELOG.md) - [Commits](https://github.com/bitinn/node-fetch/compare/v2.4.1...v2.5.0) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/backend/package.json b/backend/package.json index 0b6c71198..5dd2bfcad 100644 --- a/backend/package.json +++ b/backend/package.json @@ -62,7 +62,7 @@ "ms": "~2.1.1", "neo4j-driver": "~1.7.4", "neo4j-graphql-js": "~2.4.2", - "node-fetch": "~2.4.1", + "node-fetch": "~2.5.0", "npm-run-all": "~4.1.5", "request": "~2.88.0", "sanitize-html": "~1.20.1", diff --git a/backend/yarn.lock b/backend/yarn.lock index 67b360c5d..78046b163 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -5634,10 +5634,10 @@ node-fetch@2.1.2: resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.1.2.tgz#ab884e8e7e57e38a944753cec706f788d1768bb5" integrity sha1-q4hOjn5X44qUR1POxwb3iNF2i7U= -node-fetch@^2.1.2, node-fetch@^2.2.0, node-fetch@~2.4.1: - version "2.4.1" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.4.1.tgz#b2e38f1117b8acbedbe0524f041fb3177188255d" - integrity sha512-P9UbpFK87NyqBZzUuDBDz4f6Yiys8xm8j7ACDbi6usvFm6KItklQUKjeoqTrYS/S1k6I8oaOC2YLLDr/gg26Mw== +node-fetch@^2.1.2, node-fetch@^2.2.0, node-fetch@~2.5.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.5.0.tgz#8028c49fc1191bba56a07adc6e2a954644a48501" + integrity sha512-YuZKluhWGJwCcUu4RlZstdAxr8bFfOVHakc1mplwHkk8J+tqM1Y5yraYvIUpeX8aY7+crCwiELJq7Vl0o0LWXw== node-forge@~0.6.45: version "0.6.49" From 30a5e394c7f42ac7578c4bbbb86997da85d963cd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 7 May 2019 04:52:37 +0000 Subject: [PATCH 41/82] Bump tiptap from 1.17.0 to 1.18.0 in /webapp Bumps [tiptap](https://github.com/scrumpy/tiptap) from 1.17.0 to 1.18.0. - [Release notes](https://github.com/scrumpy/tiptap/releases) - [Commits](https://github.com/scrumpy/tiptap/compare/tiptap@1.17.0...tiptap@1.18.0) Signed-off-by: dependabot[bot] --- webapp/package.json | 2 +- webapp/yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/webapp/package.json b/webapp/package.json index 4f92f7339..61bf2b124 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -53,7 +53,7 @@ "nuxt-env": "~0.1.0", "stack-utils": "^1.0.2", "string-hash": "^1.1.3", - "tiptap": "^1.17.0", + "tiptap": "^1.18.0", "tiptap-extensions": "^1.17.0", "v-tooltip": "~2.0.2", "vue-count-to": "~1.0.13", diff --git a/webapp/yarn.lock b/webapp/yarn.lock index c113ee306..f4ae858fd 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -10473,10 +10473,10 @@ tippy.js@^4.3.0: dependencies: popper.js "^1.14.7" -tiptap-commands@^1.8.0: - version "1.8.0" - resolved "https://registry.yarnpkg.com/tiptap-commands/-/tiptap-commands-1.8.0.tgz#416942b60005fc23fc44ce7fdf4d2fe428b0d4c7" - integrity sha512-1/pOhQvCGDsoCFkOrAtoC7PBoXVEpRr8bYitPwZSNvxtqBdn+FaIfGJTHxYlxcY6skcHtlbeh9msb/W9lrz8eg== +tiptap-commands@^1.8.0, tiptap-commands@^1.9.0: + version "1.9.0" + resolved "https://registry.yarnpkg.com/tiptap-commands/-/tiptap-commands-1.9.0.tgz#f01d227635b1169c249af20f6705ed5135e7741b" + integrity sha512-bvcWZwlzF6/qadnA/mQXjHq4QljcXnPZpNL6++RK7f7oKshvUsId2XEombt81iAKUpVTELFyq/bzfmDCi5vA4A== dependencies: prosemirror-commands "^1.0.7" prosemirror-inputrules "^1.0.1" @@ -10508,10 +10508,10 @@ tiptap-utils@^1.4.0: prosemirror-tables "^0.7.11" prosemirror-utils "^0.7.6" -tiptap@^1.17.0: - version "1.17.0" - resolved "https://registry.yarnpkg.com/tiptap/-/tiptap-1.17.0.tgz#0dd7c8551378d43efbe1755504ba91d43ccb101d" - integrity sha512-8Qd/lkdgju2d7RdF5Ek6fzMpbPKGIt5YaFkRY0El2GMxt/4QcjX+6HWtcNl05fgIwF8uuPNy0CtSoeUi5KZGsQ== +tiptap@^1.17.0, tiptap@^1.18.0: + version "1.18.0" + resolved "https://registry.yarnpkg.com/tiptap/-/tiptap-1.18.0.tgz#3b3fff322324e6691f31281d8c51b60eeaf5bf9a" + integrity sha512-PVKp9HSz4sO+mSPLwyEGImkKH9oplPWg9zd8xg3b6yeUUbMHhJLObcaceyxs++4548cZcINMPK7oxmZVy+KFZw== dependencies: prosemirror-commands "^1.0.7" prosemirror-dropcursor "^1.1.1" @@ -10521,7 +10521,7 @@ tiptap@^1.17.0: prosemirror-model "^1.7.0" prosemirror-state "^1.2.1" prosemirror-view "^1.8.9" - tiptap-commands "^1.8.0" + tiptap-commands "^1.9.0" tiptap-utils "^1.4.0" tmp@^0.0.33: From db1c22d92e621b418d35daffeae6f1c190ffff95 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 7 May 2019 10:46:24 +0000 Subject: [PATCH 42/82] Bump dotenv from 7.0.0 to 8.0.0 in /backend Bumps [dotenv](https://github.com/motdotla/dotenv) from 7.0.0 to 8.0.0. - [Release notes](https://github.com/motdotla/dotenv/releases) - [Changelog](https://github.com/motdotla/dotenv/blob/master/CHANGELOG.md) - [Commits](https://github.com/motdotla/dotenv/compare/v7.0.0...v8.0.0) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/backend/package.json b/backend/package.json index 5dd2bfcad..b4f951fe7 100644 --- a/backend/package.json +++ b/backend/package.json @@ -45,7 +45,7 @@ "cross-env": "~5.2.0", "date-fns": "2.0.0-alpha.27", "debug": "~4.1.1", - "dotenv": "~7.0.0", + "dotenv": "~8.0.0", "express": "~4.16.4", "faker": "~4.1.0", "graphql": "~14.2.1", diff --git a/backend/yarn.lock b/backend/yarn.lock index 78046b163..ee462347f 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -2800,10 +2800,10 @@ dotenv@^0.4.0: resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-0.4.0.tgz#f6fb351363c2d92207245c737802c9ab5ae1495a" integrity sha1-9vs1E2PC2SIHJFxzeALJq1rhSVo= -dotenv@~7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-7.0.0.tgz#a2be3cd52736673206e8a85fb5210eea29628e7c" - integrity sha512-M3NhsLbV1i6HuGzBUH8vXrtxOk+tWmzWKDMbAVSUp3Zsjm7ywFeuwrUXhmhQyRK1q5B5GGy7hcXPbj3bnfZg2g== +dotenv@~8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-8.0.0.tgz#ed310c165b4e8a97bb745b0a9d99c31bda566440" + integrity sha512-30xVGqjLjiUOArT4+M5q9sYdvuR4riM6yK9wMcas9Vbp6zZa+ocC9dp6QoftuhTPhFAiLK/0C5Ni2nou/Bk8lg== duplexer3@^0.1.4: version "0.1.4" From d538b4e1955b5d6ef5c30d656752d17d14c65ca2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 7 May 2019 10:47:00 +0000 Subject: [PATCH 43/82] Bump tiptap-extensions from 1.17.0 to 1.18.1 in /webapp Bumps [tiptap-extensions](https://github.com/scrumpy/tiptap) from 1.17.0 to 1.18.1. - [Release notes](https://github.com/scrumpy/tiptap/releases) - [Commits](https://github.com/scrumpy/tiptap/compare/tiptap-extensions@1.17.0...tiptap-extensions@1.18.1) Signed-off-by: dependabot[bot] --- webapp/package.json | 2 +- webapp/yarn.lock | 70 ++++++++++++++++++++++++++------------------- 2 files changed, 41 insertions(+), 31 deletions(-) diff --git a/webapp/package.json b/webapp/package.json index 61bf2b124..207a1efa2 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -54,7 +54,7 @@ "stack-utils": "^1.0.2", "string-hash": "^1.1.3", "tiptap": "^1.18.0", - "tiptap-extensions": "^1.17.0", + "tiptap-extensions": "^1.18.1", "v-tooltip": "~2.0.2", "vue-count-to": "~1.0.13", "vue-izitoast": "1.1.2", diff --git a/webapp/yarn.lock b/webapp/yarn.lock index f4ae858fd..5e355458b 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -8893,6 +8893,13 @@ proper-lockfile@^4.1.1: retry "^0.12.0" signal-exit "^3.0.2" +prosemirror-collab@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/prosemirror-collab/-/prosemirror-collab-1.1.1.tgz#c8f5d951abaeac8a80818b6bd960f5a392b35b3f" + integrity sha512-BpXIB3WBD7UvgxuiasKOxlAZ78TTOdW+SQN4bbJan995tVx/wM/OZXtRJebS+tSWWAbRisHaO3ciFo732vuvdA== + dependencies: + prosemirror-state "^1.0.0" + prosemirror-commands@^1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/prosemirror-commands/-/prosemirror-commands-1.0.7.tgz#e5a2ba821e29ea7065c88277fe2c3d7f6b0b9d37" @@ -8961,7 +8968,7 @@ prosemirror-schema-list@^1.0.3: prosemirror-model "^1.0.0" prosemirror-transform "^1.0.0" -prosemirror-state@^1.0.0, prosemirror-state@^1.2.1, prosemirror-state@^1.2.2: +prosemirror-state@^1.0.0, prosemirror-state@^1.2.2: version "1.2.2" resolved "https://registry.yarnpkg.com/prosemirror-state/-/prosemirror-state-1.2.2.tgz#8df26d95fd6fd327c0f9984a760e84d863204154" integrity sha512-j8aC/kf9BJSCQau485I/9pj39XQoce+TqH5xzekT7WWFARTsRYFLJtiXBcCKakv1VSeev+sC3bJP0pLfz7Ft8g== @@ -8980,7 +8987,7 @@ prosemirror-tables@^0.7.11: prosemirror-transform "^1.0.0" prosemirror-view "^1.0.0" -prosemirror-transform@^1.0.0, prosemirror-transform@^1.1.0: +prosemirror-transform@^1.0.0, prosemirror-transform@^1.1.0, prosemirror-transform@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/prosemirror-transform/-/prosemirror-transform-1.1.3.tgz#28cfdf1f9ee514edc40466be7b7db39eed545fdf" integrity sha512-1O6Di5lOL1mp4nuCnQNkHY7l2roIW5y8RH4ZG3hMYmkmDEWzTaFFnxxAAHsE5ipGLBSRcTlP7SsDhYBIdSuLpQ== @@ -8992,10 +8999,10 @@ prosemirror-utils@^0.7.6: resolved "https://registry.yarnpkg.com/prosemirror-utils/-/prosemirror-utils-0.7.6.tgz#c462ddfbf2452e56e4b25d1f02b34caccddb0f33" integrity sha512-vzsCBTiJ56R3nRDpIJnKOJzsZP7KFO8BkXk7zvQgQiXpml2o/djPCRhuyaFc7VTqSHlLPQHVI1feTLAwHp+prQ== -prosemirror-view@^1.0.0, prosemirror-view@^1.1.0, prosemirror-view@^1.8.9: - version "1.8.9" - resolved "https://registry.yarnpkg.com/prosemirror-view/-/prosemirror-view-1.8.9.tgz#9303def925eba0a8ce4589e64b4a011eaccfc1e0" - integrity sha512-K3/z7qDR6rEMH/gKXqu5pmjmtyhtuTWeQyselK6HMp3jbn1UANU4CfdU/awQT+zbRjv4ZJXGb9lxnuNmdUQS3Q== +prosemirror-view@^1.0.0, prosemirror-view@^1.1.0, prosemirror-view@^1.9.1: + version "1.9.1" + resolved "https://registry.yarnpkg.com/prosemirror-view/-/prosemirror-view-1.9.1.tgz#3f987d55586909d4156a76b32918338655e32699" + integrity sha512-/8kQ9/CZaaDoQEqBfgyW2ex/SnuqkMim20oMpLwHYuuxfe2K30kymQYP1pEKmTVK1K97s7uE78YPyOrUU+VeuQ== dependencies: prosemirror-model "^1.1.0" prosemirror-state "^1.0.0" @@ -10473,45 +10480,48 @@ tippy.js@^4.3.0: dependencies: popper.js "^1.14.7" -tiptap-commands@^1.8.0, tiptap-commands@^1.9.0: - version "1.9.0" - resolved "https://registry.yarnpkg.com/tiptap-commands/-/tiptap-commands-1.9.0.tgz#f01d227635b1169c249af20f6705ed5135e7741b" - integrity sha512-bvcWZwlzF6/qadnA/mQXjHq4QljcXnPZpNL6++RK7f7oKshvUsId2XEombt81iAKUpVTELFyq/bzfmDCi5vA4A== +tiptap-commands@^1.9.1: + version "1.9.1" + resolved "https://registry.yarnpkg.com/tiptap-commands/-/tiptap-commands-1.9.1.tgz#be0c3fd6bbe3a984cfc6bef71d443f813a106735" + integrity sha512-/isKG7s518jofj75qvN1lru7ohx6Gtmqc6e9jAGH43Xk60FK0K2zgnaA36pHBHKBQNFK6mXyfkrJCmsf5dnuNQ== dependencies: prosemirror-commands "^1.0.7" prosemirror-inputrules "^1.0.1" prosemirror-schema-list "^1.0.3" prosemirror-state "^1.2.2" - tiptap-utils "^1.4.0" + tiptap-utils "^1.4.1" -tiptap-extensions@^1.17.0: - version "1.17.0" - resolved "https://registry.yarnpkg.com/tiptap-extensions/-/tiptap-extensions-1.17.0.tgz#caa5ea47623f2c13b15b449001a061fbd96eeb32" - integrity sha512-ljlNG5rIpbggSO5FU27NAjfeDN3Kz18GqfNGoEOHHgvC5JDIj6x5QyiPOvCRNpuWN4t4XEMUkq+F8KjI5jceKw== +tiptap-extensions@^1.18.1: + version "1.18.1" + resolved "https://registry.yarnpkg.com/tiptap-extensions/-/tiptap-extensions-1.18.1.tgz#7d63da49190c1b622a9adf66263d90631367bcd9" + integrity sha512-Dx4OwnoYohcYSuOx8P6UoY19x5BFinlkwCEEau8MzNGXVzrtCTw9c8vAIiooHobW6haEvYlb6AKWp0z5xDWsRw== dependencies: lowlight "^1.11.0" + prosemirror-collab "^1.1.1" prosemirror-history "^1.0.4" + prosemirror-model "^1.7.0" prosemirror-state "^1.2.2" prosemirror-tables "^0.7.11" + prosemirror-transform "^1.1.3" prosemirror-utils "^0.7.6" - prosemirror-view "^1.8.9" - tiptap "^1.17.0" - tiptap-commands "^1.8.0" + prosemirror-view "^1.9.1" + tiptap "^1.18.1" + tiptap-commands "^1.9.1" -tiptap-utils@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/tiptap-utils/-/tiptap-utils-1.4.0.tgz#5449bc80afcc54730bd3010b6d5fd8cd6e62160c" - integrity sha512-uPG6LRzFUhkHl3UUYhXj1vA17c43ttZPKwkSkpzbrLBBl661UAAv7Z8grvOFBY9gVjzKeg1uIncRH2al2A3SQg== +tiptap-utils@^1.4.1: + version "1.4.1" + resolved "https://registry.yarnpkg.com/tiptap-utils/-/tiptap-utils-1.4.1.tgz#fbfb964bed2216f8a8cfed9131ffd2239a358faf" + integrity sha512-fBB70PtCPgZ3nSyzwWKU2ZoqW8QzNBSfCgXgCgYlvVOBi8R9H3c4FlCU3aIPictvY7FoQtw6xC2TlD3/RkUc5w== dependencies: prosemirror-model "^1.7.0" prosemirror-state "^1.2.2" prosemirror-tables "^0.7.11" prosemirror-utils "^0.7.6" -tiptap@^1.17.0, tiptap@^1.18.0: - version "1.18.0" - resolved "https://registry.yarnpkg.com/tiptap/-/tiptap-1.18.0.tgz#3b3fff322324e6691f31281d8c51b60eeaf5bf9a" - integrity sha512-PVKp9HSz4sO+mSPLwyEGImkKH9oplPWg9zd8xg3b6yeUUbMHhJLObcaceyxs++4548cZcINMPK7oxmZVy+KFZw== +tiptap@^1.18.0, tiptap@^1.18.1: + version "1.18.1" + resolved "https://registry.yarnpkg.com/tiptap/-/tiptap-1.18.1.tgz#ac6d302a6a766b85a16579ac15e2a4c5d5751fba" + integrity sha512-hgDedZuEKHp1w45jNzg65H2nR9eNVlbsSr4cbzvNMlPUYyH1Aby/IXroxFZrwqKjsxhVZ0KSk3AVGk5GaLi1rg== dependencies: prosemirror-commands "^1.0.7" prosemirror-dropcursor "^1.1.1" @@ -10519,10 +10529,10 @@ tiptap@^1.17.0, tiptap@^1.18.0: prosemirror-inputrules "^1.0.1" prosemirror-keymap "^1.0.1" prosemirror-model "^1.7.0" - prosemirror-state "^1.2.1" - prosemirror-view "^1.8.9" - tiptap-commands "^1.9.0" - tiptap-utils "^1.4.0" + prosemirror-state "^1.2.2" + prosemirror-view "^1.9.1" + tiptap-commands "^1.9.1" + tiptap-utils "^1.4.1" tmp@^0.0.33: version "0.0.33" From 264ba2aaf7ee4b1b7452f5ffee72b1c7505c0f51 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 7 May 2019 10:47:20 +0000 Subject: [PATCH 44/82] Bump babel-jest from 24.7.1 to 24.8.0 in /backend Bumps [babel-jest](https://github.com/facebook/jest/tree/HEAD/packages/babel-jest) from 24.7.1 to 24.8.0. - [Release notes](https://github.com/facebook/jest/releases) - [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md) - [Commits](https://github.com/facebook/jest/commits/v24.8.0/packages/babel-jest) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 131 +++++++++++++++++++++++++++++++++++++------ 2 files changed, 115 insertions(+), 18 deletions(-) diff --git a/backend/package.json b/backend/package.json index 5dd2bfcad..d9729c09b 100644 --- a/backend/package.json +++ b/backend/package.json @@ -81,7 +81,7 @@ "apollo-server-testing": "~2.4.8", "babel-core": "~7.0.0-0", "babel-eslint": "~10.0.1", - "babel-jest": "~24.7.1", + "babel-jest": "~24.8.0", "chai": "~4.2.0", "cucumber": "~5.1.0", "eslint": "~5.16.0", diff --git a/backend/yarn.lock b/backend/yarn.lock index 78046b163..8b1e84d9e 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -813,6 +813,15 @@ jest-message-util "^24.7.1" jest-mock "^24.7.0" +"@jest/fake-timers@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-24.8.0.tgz#2e5b80a4f78f284bcb4bd5714b8e10dd36a8d3d1" + integrity sha512-2M4d5MufVXwi6VzZhJ9f5S/wU4ud2ck0kxPof1Iz3zWx6Y+V2eJrES9jEktB6O3o/oEyk+il/uNu9PvASjWXQw== + dependencies: + "@jest/types" "^24.8.0" + jest-message-util "^24.8.0" + jest-mock "^24.8.0" + "@jest/reporters@^24.7.1": version "24.7.1" resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-24.7.1.tgz#38ac0b096cd691bbbe3051ddc25988d42e37773a" @@ -857,6 +866,15 @@ "@jest/types" "^24.7.0" "@types/istanbul-lib-coverage" "^2.0.0" +"@jest/test-result@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-24.8.0.tgz#7675d0aaf9d2484caa65e048d9b467d160f8e9d3" + integrity sha512-+YdLlxwizlfqkFDh7Mc7ONPQAhA4YylU1s529vVM1rsf67vGZH/2GGm5uO8QzPeVyaVMobCQ7FTxl38QrKRlng== + dependencies: + "@jest/console" "^24.7.1" + "@jest/types" "^24.8.0" + "@types/istanbul-lib-coverage" "^2.0.0" + "@jest/test-sequencer@^24.7.1": version "24.7.1" resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-24.7.1.tgz#9c18e428e1ad945fa74f6233a9d35745ca0e63e0" @@ -867,33 +885,34 @@ jest-runner "^24.7.1" jest-runtime "^24.7.1" -"@jest/transform@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-24.7.1.tgz#872318f125bcfab2de11f53b465ab1aa780789c2" - integrity sha512-EsOUqP9ULuJ66IkZQhI5LufCHlTbi7hrcllRMUEV/tOgqBVQi93+9qEvkX0n8mYpVXQ8VjwmICeRgg58mrtIEw== +"@jest/transform@^24.7.1", "@jest/transform@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-24.8.0.tgz#628fb99dce4f9d254c6fd9341e3eea262e06fef5" + integrity sha512-xBMfFUP7TortCs0O+Xtez2W7Zu1PLH9bvJgtraN1CDST6LBM/eTOZ9SfwS/lvV8yOfcDpFmwf9bq5cYbXvqsvA== dependencies: "@babel/core" "^7.1.0" - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" babel-plugin-istanbul "^5.1.0" chalk "^2.0.1" convert-source-map "^1.4.0" fast-json-stable-stringify "^2.0.0" graceful-fs "^4.1.15" - jest-haste-map "^24.7.1" + jest-haste-map "^24.8.0" jest-regex-util "^24.3.0" - jest-util "^24.7.1" + jest-util "^24.8.0" micromatch "^3.1.10" realpath-native "^1.1.0" slash "^2.0.0" source-map "^0.6.1" write-file-atomic "2.4.1" -"@jest/types@^24.7.0": - version "24.7.0" - resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.7.0.tgz#c4ec8d1828cdf23234d9b4ee31f5482a3f04f48b" - integrity sha512-ipJUa2rFWiKoBqMKP63Myb6h9+iT3FHRTF2M8OR6irxWzItisa8i4dcSg14IbvmXUnBlHBlUQPYUHWyX3UPpYA== +"@jest/types@^24.7.0", "@jest/types@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.8.0.tgz#f31e25948c58f0abd8c845ae26fcea1491dea7ad" + integrity sha512-g17UxVr2YfBtaMUxn9u/4+siG1ptg9IGYAYwvpwn61nBg779RXnjE/m7CxYcIzEt0AbHZZAHSEZNhkE2WxURVg== dependencies: "@types/istanbul-lib-coverage" "^2.0.0" + "@types/istanbul-reports" "^1.1.1" "@types/yargs" "^12.0.9" "@protobufjs/aspromise@^1.1.1", "@protobufjs/aspromise@^1.1.2": @@ -1053,11 +1072,31 @@ resolved "https://registry.yarnpkg.com/@types/graphql/-/graphql-14.0.3.tgz#389e2e5b83ecdb376d9f98fae2094297bc112c1c" integrity sha512-TcFkpEjcQK7w8OcrQcd7iIBPjU0rdyi3ldj6d0iJ4PPSzbWqPBvXj9KSwO14hTOX2dm9RoiH7VuxksJLNYdXUQ== +"@types/istanbul-lib-coverage@*": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.1.tgz#42995b446db9a48a11a07ec083499a860e9138ff" + integrity sha512-hRJD2ahnnpLgsj6KWMYSrmXkM3rm2Dl1qkx6IOFD5FnuNPXJIG5L0dhgKXCYTRMGzU4n0wImQ/xfmRc4POUFlg== + "@types/istanbul-lib-coverage@^2.0.0": version "2.0.0" resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.0.tgz#1eb8c033e98cf4e1a4cedcaf8bcafe8cb7591e85" integrity sha512-eAtOAFZefEnfJiRFQBGw1eYqa5GTLCZ1y86N0XSI/D6EB+E8z6VPV/UL7Gi5UEclFqoQk+6NRqEDsfmDLXn8sg== +"@types/istanbul-lib-report@*": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-report/-/istanbul-lib-report-1.1.1.tgz#e5471e7fa33c61358dd38426189c037a58433b8c" + integrity sha512-3BUTyMzbZa2DtDI2BkERNC6jJw2Mr2Y0oGI7mRxYNBPxppbtEK1F66u3bKwU2g+wxwWI7PAoRpJnOY1grJqzHg== + dependencies: + "@types/istanbul-lib-coverage" "*" + +"@types/istanbul-reports@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-1.1.1.tgz#7a8cbf6a406f36c8add871625b278eaf0b0d255a" + integrity sha512-UpYjBi8xefVChsCoBpKShdxTllC9pwISirfoZsUa2AAdQg/Jd2KQGtSbw+ya7GPo7x/wAPlH6JBhKhAsXUEZNA== + dependencies: + "@types/istanbul-lib-coverage" "*" + "@types/istanbul-lib-report" "*" + "@types/long@^4.0.0": version "4.0.0" resolved "https://registry.yarnpkg.com/@types/long/-/long-4.0.0.tgz#719551d2352d301ac8b81db732acb6bdc28dbdef" @@ -1785,13 +1824,13 @@ babel-eslint@~10.0.1: eslint-scope "3.7.1" eslint-visitor-keys "^1.0.0" -babel-jest@^24.7.1, babel-jest@~24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-24.7.1.tgz#73902c9ff15a7dfbdc9994b0b17fcefd96042178" - integrity sha512-GPnLqfk8Mtt0i4OemjWkChi73A3ALs4w2/QbG64uAj8b5mmwzxc7jbJVRZt8NJkxi6FopVHog9S3xX6UJKb2qg== +babel-jest@^24.7.1, babel-jest@~24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-24.8.0.tgz#5c15ff2b28e20b0f45df43fe6b7f2aae93dba589" + integrity sha512-+5/kaZt4I9efoXzPlZASyK/lN9qdRKmmUav9smVc0ruPQD7IsfucQ87gpOE8mn2jbDuS6M/YOW6n3v9ZoIfgnw== dependencies: - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" "@types/babel__core" "^7.1.0" babel-plugin-istanbul "^5.1.0" babel-preset-jest "^24.6.0" @@ -4685,6 +4724,25 @@ jest-haste-map@^24.7.1: optionalDependencies: fsevents "^1.2.7" +jest-haste-map@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.8.0.tgz#51794182d877b3ddfd6e6d23920e3fe72f305800" + integrity sha512-ZBPRGHdPt1rHajWelXdqygIDpJx8u3xOoLyUBWRW28r3tagrgoepPrzAozW7kW9HrQfhvmiv1tncsxqHJO1onQ== + dependencies: + "@jest/types" "^24.8.0" + anymatch "^2.0.0" + fb-watchman "^2.0.0" + graceful-fs "^4.1.15" + invariant "^2.2.4" + jest-serializer "^24.4.0" + jest-util "^24.8.0" + jest-worker "^24.6.0" + micromatch "^3.1.10" + sane "^4.0.3" + walker "^1.0.7" + optionalDependencies: + fsevents "^1.2.7" + jest-jasmine2@^24.7.1: version "24.7.1" resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-24.7.1.tgz#01398686dabe46553716303993f3be62e5d9d818" @@ -4738,6 +4796,20 @@ jest-message-util@^24.7.1: slash "^2.0.0" stack-utils "^1.0.1" +jest-message-util@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-24.8.0.tgz#0d6891e72a4beacc0292b638685df42e28d6218b" + integrity sha512-p2k71rf/b6ns8btdB0uVdljWo9h0ovpnEe05ZKWceQGfXYr4KkzgKo3PBi8wdnd9OtNh46VpNIJynUn/3MKm1g== + dependencies: + "@babel/code-frame" "^7.0.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" + "@types/stack-utils" "^1.0.1" + chalk "^2.0.1" + micromatch "^3.1.10" + slash "^2.0.0" + stack-utils "^1.0.1" + jest-mock@^24.7.0: version "24.7.0" resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.7.0.tgz#e49ce7262c12d7f5897b0d8af77f6db8e538023b" @@ -4745,6 +4817,13 @@ jest-mock@^24.7.0: dependencies: "@jest/types" "^24.7.0" +jest-mock@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.8.0.tgz#2f9d14d37699e863f1febf4e4d5a33b7fdbbde56" + integrity sha512-6kWugwjGjJw+ZkK4mDa0Df3sDlUTsV47MSrT0nGQ0RBWJbpODDQ8MHDVtGtUYBne3IwZUhtB7elxHspU79WH3A== + dependencies: + "@jest/types" "^24.8.0" + jest-pnp-resolver@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/jest-pnp-resolver/-/jest-pnp-resolver-1.2.1.tgz#ecdae604c077a7fbc70defb6d517c3c1c898923a" @@ -4870,6 +4949,24 @@ jest-util@^24.7.1: slash "^2.0.0" source-map "^0.6.0" +jest-util@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-24.8.0.tgz#41f0e945da11df44cc76d64ffb915d0716f46cd1" + integrity sha512-DYZeE+XyAnbNt0BG1OQqKy/4GVLPtzwGx5tsnDrFcax36rVE3lTA5fbvgmbVPUZf9w77AJ8otqR4VBbfFJkUZA== + dependencies: + "@jest/console" "^24.7.1" + "@jest/fake-timers" "^24.8.0" + "@jest/source-map" "^24.3.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" + callsites "^3.0.0" + chalk "^2.0.1" + graceful-fs "^4.1.15" + is-ci "^2.0.0" + mkdirp "^0.5.1" + slash "^2.0.0" + source-map "^0.6.0" + jest-validate@^24.7.0: version "24.7.0" resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-24.7.0.tgz#70007076f338528ee1b1c8a8258b1b0bb982508d" From 90603007f31ee5dca89a9b930a28c7dd196f890d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 7 May 2019 10:47:25 +0000 Subject: [PATCH 45/82] Bump jest from 24.7.1 to 24.8.0 in /webapp Bumps [jest](https://github.com/facebook/jest) from 24.7.1 to 24.8.0. - [Release notes](https://github.com/facebook/jest/releases) - [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md) - [Commits](https://github.com/facebook/jest/compare/v24.7.1...v24.8.0) Signed-off-by: dependabot[bot] --- webapp/package.json | 2 +- webapp/yarn.lock | 594 +++++++++++++++++--------------------------- 2 files changed, 234 insertions(+), 362 deletions(-) diff --git a/webapp/package.json b/webapp/package.json index 61bf2b124..b4fec8570 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -77,7 +77,7 @@ "eslint-plugin-prettier": "~3.0.1", "eslint-plugin-vue": "~5.2.2", "fuse.js": "^3.4.4", - "jest": "~24.7.1", + "jest": "~24.8.0", "node-sass": "~4.12.0", "nodemon": "~1.19.0", "prettier": "~1.14.3", diff --git a/webapp/yarn.lock b/webapp/yarn.lock index f4ae858fd..e9a4d19b3 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -779,32 +779,32 @@ chalk "^2.0.1" slash "^2.0.0" -"@jest/core@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/core/-/core-24.7.1.tgz#6707f50db238d0c5988860680e2e414df0032024" - integrity sha512-ivlZ8HX/FOASfHcb5DJpSPFps8ydfUYzLZfgFFqjkLijYysnIEOieg72YRhO4ZUB32xu40hsSMmaw+IGYeKONA== +"@jest/core@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/core/-/core-24.8.0.tgz#fbbdcd42a41d0d39cddbc9f520c8bab0c33eed5b" + integrity sha512-R9rhAJwCBQzaRnrRgAdVfnglUuATXdwTRsYqs6NMdVcAl5euG8LtWDe+fVkN27YfKVBW61IojVsXKaOmSnqd/A== dependencies: "@jest/console" "^24.7.1" - "@jest/reporters" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/reporters" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" ansi-escapes "^3.0.0" chalk "^2.0.1" exit "^0.1.2" graceful-fs "^4.1.15" - jest-changed-files "^24.7.0" - jest-config "^24.7.1" - jest-haste-map "^24.7.1" - jest-message-util "^24.7.1" + jest-changed-files "^24.8.0" + jest-config "^24.8.0" + jest-haste-map "^24.8.0" + jest-message-util "^24.8.0" jest-regex-util "^24.3.0" - jest-resolve-dependencies "^24.7.1" - jest-runner "^24.7.1" - jest-runtime "^24.7.1" - jest-snapshot "^24.7.1" - jest-util "^24.7.1" - jest-validate "^24.7.0" - jest-watcher "^24.7.1" + jest-resolve-dependencies "^24.8.0" + jest-runner "^24.8.0" + jest-runtime "^24.8.0" + jest-snapshot "^24.8.0" + jest-util "^24.8.0" + jest-validate "^24.8.0" + jest-watcher "^24.8.0" micromatch "^3.1.10" p-each-series "^1.0.0" pirates "^4.0.1" @@ -812,24 +812,15 @@ rimraf "^2.5.4" strip-ansi "^5.0.0" -"@jest/environment@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-24.7.1.tgz#9b9196bc737561f67ac07817d4c5ece772e33135" - integrity sha512-wmcTTYc4/KqA+U5h1zQd5FXXynfa7VGP2NfF+c6QeGJ7c+2nStgh65RQWNX62SC716dTtqheTRrZl0j+54oGHw== +"@jest/environment@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-24.8.0.tgz#0342261383c776bdd652168f68065ef144af0eac" + integrity sha512-vlGt2HLg7qM+vtBrSkjDxk9K0YtRBi7HfRFaDxoRtyi+DyVChzhF20duvpdAnKVBV6W5tym8jm0U9EfXbDk1tw== dependencies: - "@jest/fake-timers" "^24.7.1" - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" - jest-mock "^24.7.0" - -"@jest/fake-timers@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-24.7.1.tgz#56e5d09bdec09ee81050eaff2794b26c71d19db2" - integrity sha512-4vSQJDKfR2jScOe12L9282uiwuwQv9Lk7mgrCSZHA9evB9efB/qx8i0KJxsAKtp8fgJYBJdYY7ZU6u3F4/pyjA== - dependencies: - "@jest/types" "^24.7.0" - jest-message-util "^24.7.1" - jest-mock "^24.7.0" + "@jest/fake-timers" "^24.8.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" + jest-mock "^24.8.0" "@jest/fake-timers@^24.8.0": version "24.8.0" @@ -840,26 +831,27 @@ jest-message-util "^24.8.0" jest-mock "^24.8.0" -"@jest/reporters@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-24.7.1.tgz#38ac0b096cd691bbbe3051ddc25988d42e37773a" - integrity sha512-bO+WYNwHLNhrjB9EbPL4kX/mCCG4ZhhfWmO3m4FSpbgr7N83MFejayz30kKjgqr7smLyeaRFCBQMbXpUgnhAJw== +"@jest/reporters@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-24.8.0.tgz#075169cd029bddec54b8f2c0fc489fd0b9e05729" + integrity sha512-eZ9TyUYpyIIXfYCrw0UHUWUvE35vx5I92HGMgS93Pv7du+GHIzl+/vh8Qj9MCWFK/4TqyttVBPakWMOfZRIfxw== dependencies: - "@jest/environment" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/environment" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" exit "^0.1.2" glob "^7.1.2" - istanbul-api "^2.1.1" istanbul-lib-coverage "^2.0.2" istanbul-lib-instrument "^3.0.1" + istanbul-lib-report "^2.0.4" istanbul-lib-source-maps "^3.0.1" - jest-haste-map "^24.7.1" - jest-resolve "^24.7.1" - jest-runtime "^24.7.1" - jest-util "^24.7.1" + istanbul-reports "^2.1.1" + jest-haste-map "^24.8.0" + jest-resolve "^24.8.0" + jest-runtime "^24.8.0" + jest-util "^24.8.0" jest-worker "^24.6.0" node-notifier "^5.2.1" slash "^2.0.0" @@ -875,15 +867,6 @@ graceful-fs "^4.1.15" source-map "^0.6.0" -"@jest/test-result@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-24.7.1.tgz#19eacdb29a114300aed24db651e5d975f08b6bbe" - integrity sha512-3U7wITxstdEc2HMfBX7Yx3JZgiNBubwDqQMh+BXmZXHa3G13YWF3p6cK+5g0hGkN3iufg/vGPl3hLxQXD74Npg== - dependencies: - "@jest/console" "^24.7.1" - "@jest/types" "^24.7.0" - "@types/istanbul-lib-coverage" "^2.0.0" - "@jest/test-result@^24.8.0": version "24.8.0" resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-24.8.0.tgz#7675d0aaf9d2484caa65e048d9b467d160f8e9d3" @@ -893,17 +876,17 @@ "@jest/types" "^24.8.0" "@types/istanbul-lib-coverage" "^2.0.0" -"@jest/test-sequencer@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-24.7.1.tgz#9c18e428e1ad945fa74f6233a9d35745ca0e63e0" - integrity sha512-84HQkCpVZI/G1zq53gHJvSmhUer4aMYp9tTaffW28Ih5OxfCg8hGr3nTSbL1OhVDRrFZwvF+/R9gY6JRkDUpUA== +"@jest/test-sequencer@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-24.8.0.tgz#2f993bcf6ef5eb4e65e8233a95a3320248cf994b" + integrity sha512-OzL/2yHyPdCHXEzhoBuq37CE99nkme15eHkAzXRVqthreWZamEMA0WoetwstsQBCXABhczpK03JNbc4L01vvLg== dependencies: - "@jest/test-result" "^24.7.1" - jest-haste-map "^24.7.1" - jest-runner "^24.7.1" - jest-runtime "^24.7.1" + "@jest/test-result" "^24.8.0" + jest-haste-map "^24.8.0" + jest-runner "^24.8.0" + jest-runtime "^24.8.0" -"@jest/transform@^24.7.1", "@jest/transform@^24.8.0": +"@jest/transform@^24.8.0": version "24.8.0" resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-24.8.0.tgz#628fb99dce4f9d254c6fd9341e3eea262e06fef5" integrity sha512-xBMfFUP7TortCs0O+Xtez2W7Zu1PLH9bvJgtraN1CDST6LBM/eTOZ9SfwS/lvV8yOfcDpFmwf9bq5cYbXvqsvA== @@ -924,7 +907,7 @@ source-map "^0.6.1" write-file-atomic "2.4.1" -"@jest/types@^24.7.0", "@jest/types@^24.8.0": +"@jest/types@^24.8.0": version "24.8.0" resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.8.0.tgz#f31e25948c58f0abd8c845ae26fcea1491dea7ad" integrity sha512-g17UxVr2YfBtaMUxn9u/4+siG1ptg9IGYAYwvpwn61nBg779RXnjE/m7CxYcIzEt0AbHZZAHSEZNhkE2WxURVg== @@ -2139,13 +2122,6 @@ apollo-utilities@1.2.1, apollo-utilities@^1.0.1, apollo-utilities@^1.0.27, apoll ts-invariant "^0.2.1" tslib "^1.9.3" -append-transform@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/append-transform/-/append-transform-1.0.0.tgz#046a52ae582a228bd72f58acfbe2967c678759ab" - integrity sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw== - dependencies: - default-require-extensions "^2.0.0" - aproba@^1.0.3, aproba@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" @@ -2281,7 +2257,7 @@ async-retry@^1.2.1: dependencies: retry "0.12.0" -async@^2.1.4, async@^2.3.0, async@^2.5.0, async@^2.6.1: +async@^2.1.4, async@^2.3.0, async@^2.5.0: version "2.6.2" resolved "https://registry.yarnpkg.com/async/-/async-2.6.2.tgz#18330ea7e6e313887f5d2f2a904bac6fe4dd5381" integrity sha512-H1qVYh1MYhEEFLsP97cVKqCGo7KfCyTt6uEWqsTBr9SO84oK9Uwbyd/yCW+6rKJLHksBNUVWZDAjfS+Ccx0Bbg== @@ -2361,7 +2337,7 @@ babel-eslint@~10.0.1: eslint-scope "3.7.1" eslint-visitor-keys "^1.0.0" -babel-jest@^24.7.1, babel-jest@~24.8.0: +babel-jest@^24.8.0, babel-jest@~24.8.0: version "24.8.0" resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-24.8.0.tgz#5c15ff2b28e20b0f45df43fe6b7f2aae93dba589" integrity sha512-+5/kaZt4I9efoXzPlZASyK/lN9qdRKmmUav9smVc0ruPQD7IsfucQ87gpOE8mn2jbDuS6M/YOW6n3v9ZoIfgnw== @@ -3202,11 +3178,6 @@ commondir@^1.0.1: resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= -compare-versions@^3.2.1: - version "3.4.0" - resolved "https://registry.yarnpkg.com/compare-versions/-/compare-versions-3.4.0.tgz#e0747df5c9cb7f054d6d3dc3e1dbc444f9e92b26" - integrity sha512-tK69D7oNXXqUW3ZNo/z7NXTEz22TCF0pTE+YF9cxvaAM9XnkLo1fV621xCLrRR6aevJlKxExkss0vWqUCUpqdg== - component-emitter@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6" @@ -3849,13 +3820,6 @@ deepmerge@^3.2.0: resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-3.2.0.tgz#58ef463a57c08d376547f8869fdc5bcee957f44e" integrity sha512-6+LuZGU7QCNUnAJyX8cIrlzoEgggTM6B7mm+znKOX4t5ltluT9KLjN6g61ECMS0LTsLW7yDpNoxhix5FZcrIow== -default-require-extensions@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-2.0.0.tgz#f5f8fbb18a7d6d50b21f641f649ebb522cfe24f7" - integrity sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc= - dependencies: - strip-bom "^3.0.0" - defaults@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/defaults/-/defaults-1.0.3.tgz#c656051e9817d9ff08ed881477f3fe4019f3ef7d" @@ -4512,16 +4476,16 @@ expand-brackets@^2.1.4: snapdragon "^0.8.1" to-regex "^3.0.1" -expect@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/expect/-/expect-24.7.1.tgz#d91defbab4e627470a152feaf35b3c31aa1c7c14" - integrity sha512-mGfvMTPduksV3xoI0xur56pQsg2vJjNf5+a+bXOjqCkiCBbmCayrBbHS/75y9K430cfqyocPr2ZjiNiRx4SRKw== +expect@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/expect/-/expect-24.8.0.tgz#471f8ec256b7b6129ca2524b2a62f030df38718d" + integrity sha512-/zYvP8iMDrzaaxHVa724eJBCKqSHmO0FA7EDkBiRHxg6OipmMn1fN+C8T9L9K8yr7UONkOifu6+LLH+z76CnaA== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" ansi-styles "^3.2.0" - jest-get-type "^24.3.0" - jest-matcher-utils "^24.7.0" - jest-message-util "^24.7.1" + jest-get-type "^24.8.0" + jest-matcher-utils "^24.8.0" + jest-message-util "^24.8.0" jest-regex-util "^24.3.0" express@^4.16.3, express@^4.16.4, express@~4.16.4: @@ -4704,14 +4668,6 @@ file-loader@^3.0.1: loader-utils "^1.0.2" schema-utils "^1.0.0" -fileset@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/fileset/-/fileset-2.0.3.tgz#8e7548a96d3cc2327ee5e674168723a333bba2a0" - integrity sha1-jnVIqW08wjJ+5eZ0FocjozO7oqA= - dependencies: - glob "^7.0.3" - minimatch "^3.0.3" - filesize@^3.6.1: version "3.6.1" resolved "https://registry.yarnpkg.com/filesize/-/filesize-3.6.1.tgz#090bb3ee01b6f801a8a8be99d31710b3422bb317" @@ -6000,38 +5956,12 @@ isstream@~0.1.2: resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= -istanbul-api@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/istanbul-api/-/istanbul-api-2.1.1.tgz#194b773f6d9cbc99a9258446848b0f988951c4d0" - integrity sha512-kVmYrehiwyeBAk/wE71tW6emzLiHGjYIiDrc8sfyty4F8M02/lrgXSm+R1kXysmF20zArvmZXjlE/mg24TVPJw== - dependencies: - async "^2.6.1" - compare-versions "^3.2.1" - fileset "^2.0.3" - istanbul-lib-coverage "^2.0.3" - istanbul-lib-hook "^2.0.3" - istanbul-lib-instrument "^3.1.0" - istanbul-lib-report "^2.0.4" - istanbul-lib-source-maps "^3.0.2" - istanbul-reports "^2.1.1" - js-yaml "^3.12.0" - make-dir "^1.3.0" - minimatch "^3.0.4" - once "^1.4.0" - istanbul-lib-coverage@^2.0.2, istanbul-lib-coverage@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.3.tgz#0b891e5ad42312c2b9488554f603795f9a2211ba" integrity sha512-dKWuzRGCs4G+67VfW9pBFFz2Jpi4vSp/k7zBcJ888ofV5Mi1g5CUML5GvMvV6u9Cjybftu+E8Cgp+k0dI1E5lw== -istanbul-lib-hook@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/istanbul-lib-hook/-/istanbul-lib-hook-2.0.3.tgz#e0e581e461c611be5d0e5ef31c5f0109759916fb" - integrity sha512-CLmEqwEhuCYtGcpNVJjLV1DQyVnIqavMLFHV/DP+np/g3qvdxu3gsPqYoJMXm15sN84xOlckFB3VNvRbf5yEgA== - dependencies: - append-transform "^1.0.0" - -istanbul-lib-instrument@^3.0.0, istanbul-lib-instrument@^3.0.1, istanbul-lib-instrument@^3.1.0: +istanbul-lib-instrument@^3.0.0, istanbul-lib-instrument@^3.0.1: version "3.1.0" resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-3.1.0.tgz#a2b5484a7d445f1f311e93190813fa56dfb62971" integrity sha512-ooVllVGT38HIk8MxDj/OIHXSYvH+1tq/Vb38s8ixt9GoJadXska4WkGY+0wkmtYCZNYtaARniH/DixUGGLZ0uA== @@ -6053,7 +5983,7 @@ istanbul-lib-report@^2.0.4: make-dir "^1.3.0" supports-color "^6.0.0" -istanbul-lib-source-maps@^3.0.1, istanbul-lib-source-maps@^3.0.2: +istanbul-lib-source-maps@^3.0.1: version "3.0.2" resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.2.tgz#f1e817229a9146e8424a28e5d69ba220fda34156" integrity sha512-JX4v0CiKTGp9fZPmoxpu9YEkPbEqCqBbO3403VabKjH+NRXo72HafD5UgnjTEqHL2SAjaZK1XDuDOkn6I5QVfQ== @@ -6081,66 +6011,66 @@ izitoast@^1.3.0: resolved "https://registry.yarnpkg.com/izitoast/-/izitoast-1.4.0.tgz#1aa4e3408b7159fba743506af66d8be54fd929fb" integrity sha512-Oc1X2wiQtPp39i5VpIjf3GJf5sfCtHKXZ5szx7RareyEeFLUlcEW0FSfBni28+Ul6KNKZRKzhVuWzSP4Xngh0w== -jest-changed-files@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-24.7.0.tgz#39d723a11b16ed7b373ac83adc76a69464b0c4fa" - integrity sha512-33BgewurnwSfJrW7T5/ZAXGE44o7swLslwh8aUckzq2e17/2Os1V0QU506ZNik3hjs8MgnEMKNkcud442NCDTw== +jest-changed-files@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-24.8.0.tgz#7e7eb21cf687587a85e50f3d249d1327e15b157b" + integrity sha512-qgANC1Yrivsq+UrLXsvJefBKVoCsKB0Hv+mBb6NMjjZ90wwxCDmU3hsCXBya30cH+LnPYjwgcU65i6yJ5Nfuug== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" execa "^1.0.0" throat "^4.0.0" -jest-cli@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-24.7.1.tgz#6093a539073b6f4953145abeeb9709cd621044f1" - integrity sha512-32OBoSCVPzcTslGFl6yVCMzB2SqX3IrWwZCY5mZYkb0D2WsogmU3eV2o8z7+gRQa4o4sZPX/k7GU+II7CxM6WQ== +jest-cli@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-24.8.0.tgz#b075ac914492ed114fa338ade7362a301693e989" + integrity sha512-+p6J00jSMPQ116ZLlHJJvdf8wbjNbZdeSX9ptfHX06/MSNaXmKihQzx5vQcw0q2G6JsdVkUIdWbOWtSnaYs3yA== dependencies: - "@jest/core" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/core" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" exit "^0.1.2" import-local "^2.0.0" is-ci "^2.0.0" - jest-config "^24.7.1" - jest-util "^24.7.1" - jest-validate "^24.7.0" + jest-config "^24.8.0" + jest-util "^24.8.0" + jest-validate "^24.8.0" prompts "^2.0.1" realpath-native "^1.1.0" yargs "^12.0.2" -jest-config@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-24.7.1.tgz#6c1dd4db82a89710a3cf66bdba97827c9a1cf052" - integrity sha512-8FlJNLI+X+MU37j7j8RE4DnJkvAghXmBWdArVzypW6WxfGuxiL/CCkzBg0gHtXhD2rxla3IMOSUAHylSKYJ83g== +jest-config@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-24.8.0.tgz#77db3d265a6f726294687cbbccc36f8a76ee0f4f" + integrity sha512-Czl3Nn2uEzVGsOeaewGWoDPD8GStxCpAe0zOYs2x2l0fZAgPbCr3uwUkgNKV3LwE13VXythM946cd5rdGkkBZw== dependencies: "@babel/core" "^7.1.0" - "@jest/test-sequencer" "^24.7.1" - "@jest/types" "^24.7.0" - babel-jest "^24.7.1" + "@jest/test-sequencer" "^24.8.0" + "@jest/types" "^24.8.0" + babel-jest "^24.8.0" chalk "^2.0.1" glob "^7.1.1" - jest-environment-jsdom "^24.7.1" - jest-environment-node "^24.7.1" - jest-get-type "^24.3.0" - jest-jasmine2 "^24.7.1" + jest-environment-jsdom "^24.8.0" + jest-environment-node "^24.8.0" + jest-get-type "^24.8.0" + jest-jasmine2 "^24.8.0" jest-regex-util "^24.3.0" - jest-resolve "^24.7.1" - jest-util "^24.7.1" - jest-validate "^24.7.0" + jest-resolve "^24.8.0" + jest-util "^24.8.0" + jest-validate "^24.8.0" micromatch "^3.1.10" - pretty-format "^24.7.0" + pretty-format "^24.8.0" realpath-native "^1.1.0" -jest-diff@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-24.7.0.tgz#5d862899be46249754806f66e5729c07fcb3580f" - integrity sha512-ULQZ5B1lWpH70O4xsANC4tf4Ko6RrpwhE3PtG6ERjMg1TiYTC2Wp4IntJVGro6a8HG9luYHhhmF4grF0Pltckg== +jest-diff@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-24.8.0.tgz#146435e7d1e3ffdf293d53ff97e193f1d1546172" + integrity sha512-wxetCEl49zUpJ/bvUmIFjd/o52J+yWcoc5ZyPq4/W1LUKGEhRYDIbP1KcF6t+PvqNrGAFk4/JhtxDq/Nnzs66g== dependencies: chalk "^2.0.1" diff-sequences "^24.3.0" - jest-get-type "^24.3.0" - pretty-format "^24.7.0" + jest-get-type "^24.8.0" + pretty-format "^24.8.0" jest-docblock@^24.3.0: version "24.3.0" @@ -6149,63 +6079,44 @@ jest-docblock@^24.3.0: dependencies: detect-newline "^2.1.0" -jest-each@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-24.7.1.tgz#fcc7dda4147c28430ad9fb6dc7211cd17ab54e74" - integrity sha512-4fsS8fEfLa3lfnI1Jw6NxjhyRTgfpuOVTeUZZFyVYqeTa4hPhr2YkToUhouuLTrL2eMGOfpbdMyRx0GQ/VooKA== +jest-each@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-24.8.0.tgz#a05fd2bf94ddc0b1da66c6d13ec2457f35e52775" + integrity sha512-NrwK9gaL5+XgrgoCsd9svsoWdVkK4gnvyhcpzd6m487tXHqIdYeykgq3MKI1u4I+5Zf0tofr70at9dWJDeb+BA== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" - jest-get-type "^24.3.0" - jest-util "^24.7.1" - pretty-format "^24.7.0" + jest-get-type "^24.8.0" + jest-util "^24.8.0" + pretty-format "^24.8.0" -jest-environment-jsdom@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-24.7.1.tgz#a40e004b4458ebeb8a98082df135fd501b9fbbd6" - integrity sha512-Gnhb+RqE2JuQGb3kJsLF8vfqjt3PHKSstq4Xc8ic+ax7QKo4Z0RWGucU3YV+DwKR3T9SYc+3YCUQEJs8r7+Jxg== +jest-environment-jsdom@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-24.8.0.tgz#300f6949a146cabe1c9357ad9e9ecf9f43f38857" + integrity sha512-qbvgLmR7PpwjoFjM/sbuqHJt/NCkviuq9vus9NBn/76hhSidO+Z6Bn9tU8friecegbJL8gzZQEMZBQlFWDCwAQ== dependencies: - "@jest/environment" "^24.7.1" - "@jest/fake-timers" "^24.7.1" - "@jest/types" "^24.7.0" - jest-mock "^24.7.0" - jest-util "^24.7.1" + "@jest/environment" "^24.8.0" + "@jest/fake-timers" "^24.8.0" + "@jest/types" "^24.8.0" + jest-mock "^24.8.0" + jest-util "^24.8.0" jsdom "^11.5.1" -jest-environment-node@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-24.7.1.tgz#fa2c047a31522a48038d26ee4f7c8fd9c1ecfe12" - integrity sha512-GJJQt1p9/C6aj6yNZMvovZuxTUd+BEJprETdvTKSb4kHcw4mFj8777USQV0FJoJ4V3djpOwA5eWyPwfq//PFBA== +jest-environment-node@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-24.8.0.tgz#d3f726ba8bc53087a60e7a84ca08883a4c892231" + integrity sha512-vIGUEScd1cdDgR6sqn2M08sJTRLQp6Dk/eIkCeO4PFHxZMOgy+uYLPMC4ix3PEfM5Au/x3uQ/5Tl0DpXXZsJ/Q== dependencies: - "@jest/environment" "^24.7.1" - "@jest/fake-timers" "^24.7.1" - "@jest/types" "^24.7.0" - jest-mock "^24.7.0" - jest-util "^24.7.1" + "@jest/environment" "^24.8.0" + "@jest/fake-timers" "^24.8.0" + "@jest/types" "^24.8.0" + jest-mock "^24.8.0" + jest-util "^24.8.0" -jest-get-type@^24.3.0: - version "24.3.0" - resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-24.3.0.tgz#582cfd1a4f91b5cdad1d43d2932f816d543c65da" - integrity sha512-HYF6pry72YUlVcvUx3sEpMRwXEWGEPlJ0bSPVnB3b3n++j4phUEoSPcS6GC0pPJ9rpyPSe4cb5muFo6D39cXow== - -jest-haste-map@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.7.1.tgz#772e215cd84080d4bbcb759cfb668ad649a21471" - integrity sha512-g0tWkzjpHD2qa03mTKhlydbmmYiA2KdcJe762SbfFo/7NIMgBWAA0XqQlApPwkWOF7Cxoi/gUqL0i6DIoLpMBw== - dependencies: - "@jest/types" "^24.7.0" - anymatch "^2.0.0" - fb-watchman "^2.0.0" - graceful-fs "^4.1.15" - invariant "^2.2.4" - jest-serializer "^24.4.0" - jest-util "^24.7.1" - jest-worker "^24.6.0" - micromatch "^3.1.10" - sane "^4.0.3" - walker "^1.0.7" - optionalDependencies: - fsevents "^1.2.7" +jest-get-type@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-24.8.0.tgz#a7440de30b651f5a70ea3ed7ff073a32dfe646fc" + integrity sha512-RR4fo8jEmMD9zSz2nLbs2j0zvPpk/KCEz3a62jJWbd2ayNo0cb+KFRxPHVhE4ZmgGJEQp0fosmNz84IfqM8cMQ== jest-haste-map@^24.8.0: version "24.8.0" @@ -6226,58 +6137,44 @@ jest-haste-map@^24.8.0: optionalDependencies: fsevents "^1.2.7" -jest-jasmine2@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-24.7.1.tgz#01398686dabe46553716303993f3be62e5d9d818" - integrity sha512-Y/9AOJDV1XS44wNwCaThq4Pw3gBPiOv/s6NcbOAkVRRUEPu+36L2xoPsqQXsDrxoBerqeyslpn2TpCI8Zr6J2w== +jest-jasmine2@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-24.8.0.tgz#a9c7e14c83dd77d8b15e820549ce8987cc8cd898" + integrity sha512-cEky88npEE5LKd5jPpTdDCLvKkdyklnaRycBXL6GNmpxe41F0WN44+i7lpQKa/hcbXaQ+rc9RMaM4dsebrYong== dependencies: "@babel/traverse" "^7.1.0" - "@jest/environment" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/environment" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" co "^4.6.0" - expect "^24.7.1" + expect "^24.8.0" is-generator-fn "^2.0.0" - jest-each "^24.7.1" - jest-matcher-utils "^24.7.0" - jest-message-util "^24.7.1" - jest-runtime "^24.7.1" - jest-snapshot "^24.7.1" - jest-util "^24.7.1" - pretty-format "^24.7.0" + jest-each "^24.8.0" + jest-matcher-utils "^24.8.0" + jest-message-util "^24.8.0" + jest-runtime "^24.8.0" + jest-snapshot "^24.8.0" + jest-util "^24.8.0" + pretty-format "^24.8.0" throat "^4.0.0" -jest-leak-detector@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-24.7.0.tgz#323ff93ed69be12e898f5b040952f08a94288ff9" - integrity sha512-zV0qHKZGXtmPVVzT99CVEcHE9XDf+8LwiE0Ob7jjezERiGVljmqKFWpV2IkG+rkFIEUHFEkMiICu7wnoPM/RoQ== +jest-leak-detector@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-24.8.0.tgz#c0086384e1f650c2d8348095df769f29b48e6980" + integrity sha512-cG0yRSK8A831LN8lIHxI3AblB40uhv0z+SsQdW3GoMMVcK+sJwrIIyax5tu3eHHNJ8Fu6IMDpnLda2jhn2pD/g== dependencies: - pretty-format "^24.7.0" + pretty-format "^24.8.0" -jest-matcher-utils@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-24.7.0.tgz#bbee1ff37bc8b2e4afcaabc91617c1526af4bcd4" - integrity sha512-158ieSgk3LNXeUhbVJYRXyTPSCqNgVXOp/GT7O94mYd3pk/8+odKTyR1JLtNOQSPzNi8NFYVONtvSWA/e1RDXg== +jest-matcher-utils@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-24.8.0.tgz#2bce42204c9af12bde46f83dc839efe8be832495" + integrity sha512-lex1yASY51FvUuHgm0GOVj7DCYEouWSlIYmCW7APSqB9v8mXmKSn5+sWVF0MhuASG0bnYY106/49JU1FZNl5hw== dependencies: chalk "^2.0.1" - jest-diff "^24.7.0" - jest-get-type "^24.3.0" - pretty-format "^24.7.0" - -jest-message-util@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-24.7.1.tgz#f1dc3a6c195647096a99d0f1dadbc447ae547018" - integrity sha512-dk0gqVtyqezCHbcbk60CdIf+8UHgD+lmRHifeH3JRcnAqh4nEyPytSc9/L1+cQyxC+ceaeP696N4ATe7L+omcg== - dependencies: - "@babel/code-frame" "^7.0.0" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" - "@types/stack-utils" "^1.0.1" - chalk "^2.0.1" - micromatch "^3.1.10" - slash "^2.0.0" - stack-utils "^1.0.1" + jest-diff "^24.8.0" + jest-get-type "^24.8.0" + pretty-format "^24.8.0" jest-message-util@^24.8.0: version "24.8.0" @@ -6293,13 +6190,6 @@ jest-message-util@^24.8.0: slash "^2.0.0" stack-utils "^1.0.1" -jest-mock@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.7.0.tgz#e49ce7262c12d7f5897b0d8af77f6db8e538023b" - integrity sha512-6taW4B4WUcEiT2V9BbOmwyGuwuAFT2G8yghF7nyNW1/2gq5+6aTqSPcS9lS6ArvEkX55vbPAS/Jarx5LSm4Fng== - dependencies: - "@jest/types" "^24.7.0" - jest-mock@^24.8.0: version "24.8.0" resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.8.0.tgz#2f9d14d37699e863f1febf4e4d5a33b7fdbbde56" @@ -6317,75 +6207,75 @@ jest-regex-util@^24.3.0: resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-24.3.0.tgz#d5a65f60be1ae3e310d5214a0307581995227b36" integrity sha512-tXQR1NEOyGlfylyEjg1ImtScwMq8Oh3iJbGTjN7p0J23EuVX1MA8rwU69K4sLbCmwzgCUbVkm0FkSF9TdzOhtg== -jest-resolve-dependencies@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-24.7.1.tgz#cf93bbef26999488a96a2b2012f9fe7375aa378f" - integrity sha512-2Eyh5LJB2liNzfk4eo7bD1ZyBbqEJIyyrFtZG555cSWW9xVHxII2NuOkSl1yUYTAYCAmM2f2aIT5A7HzNmubyg== +jest-resolve-dependencies@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-24.8.0.tgz#19eec3241f2045d3f990dba331d0d7526acff8e0" + integrity sha512-hyK1qfIf/krV+fSNyhyJeq3elVMhK9Eijlwy+j5jqmZ9QsxwKBiP6qukQxaHtK8k6zql/KYWwCTQ+fDGTIJauw== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" jest-regex-util "^24.3.0" - jest-snapshot "^24.7.1" + jest-snapshot "^24.8.0" -jest-resolve@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-24.7.1.tgz#e4150198299298380a75a9fd55043fa3b9b17fde" - integrity sha512-Bgrc+/UUZpGJ4323sQyj85hV9d+ANyPNu6XfRDUcyFNX1QrZpSoM0kE4Mb2vZMAYTJZsBFzYe8X1UaOkOELSbw== +jest-resolve@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-24.8.0.tgz#84b8e5408c1f6a11539793e2b5feb1b6e722439f" + integrity sha512-+hjSzi1PoRvnuOICoYd5V/KpIQmkAsfjFO71458hQ2Whi/yf1GDeBOFj8Gxw4LrApHsVJvn5fmjcPdmoUHaVKw== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" browser-resolve "^1.11.3" chalk "^2.0.1" jest-pnp-resolver "^1.2.1" realpath-native "^1.1.0" -jest-runner@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-24.7.1.tgz#41c8a02a06aa23ea82d8bffd69d7fa98d32f85bf" - integrity sha512-aNFc9liWU/xt+G9pobdKZ4qTeG/wnJrJna3VqunziDNsWT3EBpmxXZRBMKCsNMyfy+A/XHiV+tsMLufdsNdgCw== +jest-runner@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-24.8.0.tgz#4f9ae07b767db27b740d7deffad0cf67ccb4c5bb" + integrity sha512-utFqC5BaA3JmznbissSs95X1ZF+d+4WuOWwpM9+Ak356YtMhHE/GXUondZdcyAAOTBEsRGAgH/0TwLzfI9h7ow== dependencies: "@jest/console" "^24.7.1" - "@jest/environment" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/environment" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" chalk "^2.4.2" exit "^0.1.2" graceful-fs "^4.1.15" - jest-config "^24.7.1" + jest-config "^24.8.0" jest-docblock "^24.3.0" - jest-haste-map "^24.7.1" - jest-jasmine2 "^24.7.1" - jest-leak-detector "^24.7.0" - jest-message-util "^24.7.1" - jest-resolve "^24.7.1" - jest-runtime "^24.7.1" - jest-util "^24.7.1" + jest-haste-map "^24.8.0" + jest-jasmine2 "^24.8.0" + jest-leak-detector "^24.8.0" + jest-message-util "^24.8.0" + jest-resolve "^24.8.0" + jest-runtime "^24.8.0" + jest-util "^24.8.0" jest-worker "^24.6.0" source-map-support "^0.5.6" throat "^4.0.0" -jest-runtime@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-24.7.1.tgz#2ffd70b22dd03a5988c0ab9465c85cdf5d25c597" - integrity sha512-0VAbyBy7tll3R+82IPJpf6QZkokzXPIS71aDeqh+WzPRXRCNz6StQ45otFariPdJ4FmXpDiArdhZrzNAC3sj6A== +jest-runtime@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-24.8.0.tgz#05f94d5b05c21f6dc54e427cd2e4980923350620" + integrity sha512-Mq0aIXhvO/3bX44ccT+czU1/57IgOMyy80oM0XR/nyD5zgBcesF84BPabZi39pJVA6UXw+fY2Q1N+4BiVUBWOA== dependencies: "@jest/console" "^24.7.1" - "@jest/environment" "^24.7.1" + "@jest/environment" "^24.8.0" "@jest/source-map" "^24.3.0" - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" "@types/yargs" "^12.0.2" chalk "^2.0.1" exit "^0.1.2" glob "^7.1.3" graceful-fs "^4.1.15" - jest-config "^24.7.1" - jest-haste-map "^24.7.1" - jest-message-util "^24.7.1" - jest-mock "^24.7.0" + jest-config "^24.8.0" + jest-haste-map "^24.8.0" + jest-message-util "^24.8.0" + jest-mock "^24.8.0" jest-regex-util "^24.3.0" - jest-resolve "^24.7.1" - jest-snapshot "^24.7.1" - jest-util "^24.7.1" - jest-validate "^24.7.0" + jest-resolve "^24.8.0" + jest-snapshot "^24.8.0" + jest-util "^24.8.0" + jest-validate "^24.8.0" realpath-native "^1.1.0" slash "^2.0.0" strip-bom "^3.0.0" @@ -6396,42 +6286,24 @@ jest-serializer@^24.4.0: resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-24.4.0.tgz#f70c5918c8ea9235ccb1276d232e459080588db3" integrity sha512-k//0DtglVstc1fv+GY/VHDIjrtNjdYvYjMlbLUed4kxrE92sIUewOi5Hj3vrpB8CXfkJntRPDRjCrCvUhBdL8Q== -jest-snapshot@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-24.7.1.tgz#bd5a35f74aedff070975e9e9c90024f082099568" - integrity sha512-8Xk5O4p+JsZZn4RCNUS3pxA+ORKpEKepE+a5ejIKrId9CwrVN0NY+vkqEkXqlstA5NMBkNahXkR/4qEBy0t5yA== +jest-snapshot@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-24.8.0.tgz#3bec6a59da2ff7bc7d097a853fb67f9d415cb7c6" + integrity sha512-5ehtWoc8oU9/cAPe6fez6QofVJLBKyqkY2+TlKTOf0VllBB/mqUNdARdcjlZrs9F1Cv+/HKoCS/BknT0+tmfPg== dependencies: "@babel/types" "^7.0.0" - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" - expect "^24.7.1" - jest-diff "^24.7.0" - jest-matcher-utils "^24.7.0" - jest-message-util "^24.7.1" - jest-resolve "^24.7.1" + expect "^24.8.0" + jest-diff "^24.8.0" + jest-matcher-utils "^24.8.0" + jest-message-util "^24.8.0" + jest-resolve "^24.8.0" mkdirp "^0.5.1" natural-compare "^1.4.0" - pretty-format "^24.7.0" + pretty-format "^24.8.0" semver "^5.5.0" -jest-util@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-24.7.1.tgz#b4043df57b32a23be27c75a2763d8faf242038ff" - integrity sha512-/KilOue2n2rZ5AnEBYoxOXkeTu6vi7cjgQ8MXEkih0oeAXT6JkS3fr7/j8+engCjciOU1Nq5loMSKe0A1oeX0A== - dependencies: - "@jest/console" "^24.7.1" - "@jest/fake-timers" "^24.7.1" - "@jest/source-map" "^24.3.0" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" - callsites "^3.0.0" - chalk "^2.0.1" - graceful-fs "^4.1.15" - is-ci "^2.0.0" - mkdirp "^0.5.1" - slash "^2.0.0" - source-map "^0.6.0" - jest-util@^24.8.0: version "24.8.0" resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-24.8.0.tgz#41f0e945da11df44cc76d64ffb915d0716f46cd1" @@ -6450,29 +6322,29 @@ jest-util@^24.8.0: slash "^2.0.0" source-map "^0.6.0" -jest-validate@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-24.7.0.tgz#70007076f338528ee1b1c8a8258b1b0bb982508d" - integrity sha512-cgai/gts9B2chz1rqVdmLhzYxQbgQurh1PEQSvSgPZ8KGa1AqXsqC45W5wKEwzxKrWqypuQrQxnF4+G9VejJJA== +jest-validate@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-24.8.0.tgz#624c41533e6dfe356ffadc6e2423a35c2d3b4849" + integrity sha512-+/N7VOEMW1Vzsrk3UWBDYTExTPwf68tavEPKDnJzrC6UlHtUDU/fuEdXqFoHzv9XnQ+zW6X3qMZhJ3YexfeLDA== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" camelcase "^5.0.0" chalk "^2.0.1" - jest-get-type "^24.3.0" + jest-get-type "^24.8.0" leven "^2.1.0" - pretty-format "^24.7.0" + pretty-format "^24.8.0" -jest-watcher@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-24.7.1.tgz#e161363d7f3f4e1ef3d389b7b3a0aad247b673f5" - integrity sha512-Wd6TepHLRHVKLNPacEsBwlp9raeBIO+01xrN24Dek4ggTS8HHnOzYSFnvp+6MtkkJ3KfMzy220KTi95e2rRkrw== +jest-watcher@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-24.8.0.tgz#58d49915ceddd2de85e238f6213cef1c93715de4" + integrity sha512-SBjwHt5NedQoVu54M5GEx7cl7IGEFFznvd/HNT8ier7cCAx/Qgu9ZMlaTQkvK22G1YOpcWBLQPFSImmxdn3DAw== dependencies: - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" "@types/yargs" "^12.0.9" ansi-escapes "^3.0.0" chalk "^2.0.1" - jest-util "^24.7.1" + jest-util "^24.8.0" string-length "^2.0.0" jest-worker@^24.6.0: @@ -6483,13 +6355,13 @@ jest-worker@^24.6.0: merge-stream "^1.0.1" supports-color "^6.1.0" -jest@~24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest/-/jest-24.7.1.tgz#0d94331cf510c75893ee32f87d7321d5bf8f2501" - integrity sha512-AbvRar5r++izmqo5gdbAjTeA6uNRGoNRuj5vHB0OnDXo2DXWZJVuaObiGgtlvhKb+cWy2oYbQSfxv7Q7GjnAtA== +jest@~24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest/-/jest-24.8.0.tgz#d5dff1984d0d1002196e9b7f12f75af1b2809081" + integrity sha512-o0HM90RKFRNWmAWvlyV8i5jGZ97pFwkeVoGvPW1EtLTgJc2+jcuqcbbqcSZLE/3f2S5pt0y2ZBETuhpWNl1Reg== dependencies: import-local "^2.0.0" - jest-cli "^24.7.1" + jest-cli "^24.8.0" joi@^14.3.0: version "14.3.1" @@ -7204,7 +7076,7 @@ minimalistic-crypto-utils@^1.0.0, minimalistic-crypto-utils@^1.0.1: resolved "https://registry.yarnpkg.com/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" integrity sha1-9sAMHAsIIkblxNmd+4x8CDsrWCo= -minimatch@^3.0.3, minimatch@^3.0.4, minimatch@~3.0.2: +minimatch@^3.0.4, minimatch@~3.0.2: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== @@ -8836,12 +8708,12 @@ pretty-error@^2.0.2: renderkid "^2.0.1" utila "~0.4" -pretty-format@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-24.7.0.tgz#d23106bc2edcd776079c2daa5da02bcb12ed0c10" - integrity sha512-apen5cjf/U4dj7tHetpC7UEFCvtAgnNZnBDkfPv3fokzIqyOJckAG9OlAPC1BlFALnqT/lGB2tl9EJjlK6eCsA== +pretty-format@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-24.8.0.tgz#8dae7044f58db7cb8be245383b565a963e3c27f2" + integrity sha512-P952T7dkrDEplsR+TuY7q3VXDae5Sr7zmQb12JU/NDQa/3CH7/QW0yvqLcGN6jL+zQFKaoJcPc+yJxMTGmosqw== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" ansi-regex "^4.0.0" ansi-styles "^3.2.0" react-is "^16.8.4" From 0572d122fbcf4e0eabd05a82b68844fe2f337893 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 7 May 2019 10:47:31 +0000 Subject: [PATCH 46/82] Bump eslint-plugin-node from 8.0.1 to 9.0.1 in /backend Bumps [eslint-plugin-node](https://github.com/mysticatea/eslint-plugin-node) from 8.0.1 to 9.0.1. - [Release notes](https://github.com/mysticatea/eslint-plugin-node/releases) - [Commits](https://github.com/mysticatea/eslint-plugin-node/compare/v8.0.1...v9.0.1) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 39 ++++++++++++++++++++++----------------- 2 files changed, 23 insertions(+), 18 deletions(-) diff --git a/backend/package.json b/backend/package.json index 5dd2bfcad..70de3724e 100644 --- a/backend/package.json +++ b/backend/package.json @@ -88,7 +88,7 @@ "eslint-config-standard": "~12.0.0", "eslint-plugin-import": "~2.17.2", "eslint-plugin-jest": "~22.5.1", - "eslint-plugin-node": "~8.0.1", + "eslint-plugin-node": "~9.0.1", "eslint-plugin-promise": "~4.1.1", "eslint-plugin-standard": "~4.0.0", "graphql-request": "~1.8.2", diff --git a/backend/yarn.lock b/backend/yarn.lock index 78046b163..f8e161a5c 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -3005,7 +3005,7 @@ eslint-module-utils@^2.4.0: debug "^2.6.8" pkg-dir "^2.0.0" -eslint-plugin-es@^1.3.1: +eslint-plugin-es@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/eslint-plugin-es/-/eslint-plugin-es-1.4.0.tgz#475f65bb20c993fc10e8c8fe77d1d60068072da6" integrity sha512-XfFmgFdIUDgvaRAlaXUkxrRg5JSADoRC8IkKLc/cISeR3yHVMefFHQZpcyXXEUUPHfy5DwviBcrfqlyqEwlQVw== @@ -3035,17 +3035,17 @@ eslint-plugin-jest@~22.5.1: resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-22.5.1.tgz#a31dfe9f9513c6af7c17ece4c65535a1370f060b" integrity sha512-c3WjZR/HBoi4GedJRwo2OGHa8Pzo1EbSVwQ2HFzJ+4t2OoYM7Alx646EH/aaxZ+9eGcPiq0FT0UGkRuFFx2FHg== -eslint-plugin-node@~8.0.1: - version "8.0.1" - resolved "https://registry.yarnpkg.com/eslint-plugin-node/-/eslint-plugin-node-8.0.1.tgz#55ae3560022863d141fa7a11799532340a685964" - integrity sha512-ZjOjbjEi6jd82rIpFSgagv4CHWzG9xsQAVp1ZPlhRnnYxcTgENUVBvhYmkQ7GvT1QFijUSo69RaiOJKhMu6i8w== +eslint-plugin-node@~9.0.1: + version "9.0.1" + resolved "https://registry.yarnpkg.com/eslint-plugin-node/-/eslint-plugin-node-9.0.1.tgz#93e44626fa62bcb6efea528cee9687663dc03b62" + integrity sha512-fljT5Uyy3lkJzuqhxrYanLSsvaILs9I7CmQ31atTtZ0DoIzRbbvInBh4cQ1CrthFHInHYBQxfPmPt6KLHXNXdw== dependencies: - eslint-plugin-es "^1.3.1" + eslint-plugin-es "^1.4.0" eslint-utils "^1.3.1" - ignore "^5.0.2" + ignore "^5.1.1" minimatch "^3.0.4" - resolve "^1.8.1" - semver "^5.5.0" + resolve "^1.10.1" + semver "^6.0.0" eslint-plugin-promise@~4.1.1: version "4.1.1" @@ -4101,10 +4101,10 @@ ignore@^4.0.6: resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== -ignore@^5.0.2: - version "5.0.4" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.0.4.tgz#33168af4a21e99b00c5d41cbadb6a6cb49903a45" - integrity sha512-WLsTMEhsQuXpCiG173+f3aymI43SXa+fB1rSfbzyP4GkPP+ZFVuO0/3sFUGNBtifisPeDcl/uD/Y2NxZ7xFq4g== +ignore@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.1.1.tgz#2fc6b8f518aff48fef65a7f348ed85632448e4a5" + integrity sha512-DWjnQIFLenVrwyRCKZT+7a7/U4Cqgar4WG8V++K3hw+lrW1hc/SIwdiGmtxKCVACmHULTuGeBbHJmbwW7/sAvA== immutable-tuple@^0.4.9: version "0.4.9" @@ -6686,10 +6686,10 @@ resolve@1.1.7: resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= -resolve@^1.10.0, resolve@^1.3.2, resolve@^1.3.3, resolve@^1.5.0, resolve@^1.8.1: - version "1.10.0" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.10.0.tgz#3bdaaeaf45cc07f375656dfd2e54ed0810b101ba" - integrity sha512-3sUr9aq5OfSg2S9pNtPA9hL1FVEAjvfOC4leW0SNf/mpnaakz2a9femSd6LqAww2RaFctwyf1lCqnTHuF1rxDg== +resolve@^1.10.0, resolve@^1.10.1, resolve@^1.3.2, resolve@^1.3.3, resolve@^1.5.0: + version "1.10.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.10.1.tgz#664842ac960795bbe758221cdccda61fb64b5f18" + integrity sha512-KuIe4mf++td/eFb6wkaPbMDnP6kObCaEtIDuHOUED6MNUo4K670KZUHuuvYPZDxNF0WVLw49n06M2m2dXphEzA== dependencies: path-parse "^1.0.6" @@ -6835,6 +6835,11 @@ semver-diff@^2.0.0: resolved "https://registry.yarnpkg.com/semver/-/semver-5.6.0.tgz#7e74256fbaa49c75aa7c7a205cc22799cac80004" integrity sha512-RS9R6R35NYgQn++fkDWaOmqGoj4Ek9gGs+DPxNUZKuwE183xjJroKvyo1IzVFeXvUrvmALy6FWD5xrdJT25gMg== +semver@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.0.0.tgz#05e359ee571e5ad7ed641a6eec1e547ba52dea65" + integrity sha512-0UewU+9rFapKFnlbirLi3byoOuhrSsli/z/ihNnvM24vgF+8sNBiI1LZPBSH9wJKUwaUbw+s3hToDLCXkrghrQ== + send@0.16.2: version "0.16.2" resolved "https://registry.yarnpkg.com/send/-/send-0.16.2.tgz#6ecca1e0f8c156d141597559848df64730a6bbc1" From cce81a5ec0aa6492d0f8fdabf66c52750fffae39 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Tue, 7 May 2019 12:25:10 +0000 Subject: [PATCH 47/82] Bump jest from 24.7.1 to 24.8.0 in /backend Bumps [jest](https://github.com/facebook/jest) from 24.7.1 to 24.8.0. - [Release notes](https://github.com/facebook/jest/releases) - [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md) - [Commits](https://github.com/facebook/jest/compare/v24.7.1...v24.8.0) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 598 +++++++++++++++++-------------------------- 2 files changed, 236 insertions(+), 364 deletions(-) diff --git a/backend/package.json b/backend/package.json index 7542c208b..304e31176 100644 --- a/backend/package.json +++ b/backend/package.json @@ -92,7 +92,7 @@ "eslint-plugin-promise": "~4.1.1", "eslint-plugin-standard": "~4.0.0", "graphql-request": "~1.8.2", - "jest": "~24.7.1", + "jest": "~24.8.0", "nodemon": "~1.19.0", "supertest": "~4.0.2" } diff --git a/backend/yarn.lock b/backend/yarn.lock index 7939098ef..2cdc7acf0 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -761,32 +761,32 @@ chalk "^2.0.1" slash "^2.0.0" -"@jest/core@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/core/-/core-24.7.1.tgz#6707f50db238d0c5988860680e2e414df0032024" - integrity sha512-ivlZ8HX/FOASfHcb5DJpSPFps8ydfUYzLZfgFFqjkLijYysnIEOieg72YRhO4ZUB32xu40hsSMmaw+IGYeKONA== +"@jest/core@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/core/-/core-24.8.0.tgz#fbbdcd42a41d0d39cddbc9f520c8bab0c33eed5b" + integrity sha512-R9rhAJwCBQzaRnrRgAdVfnglUuATXdwTRsYqs6NMdVcAl5euG8LtWDe+fVkN27YfKVBW61IojVsXKaOmSnqd/A== dependencies: "@jest/console" "^24.7.1" - "@jest/reporters" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/reporters" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" ansi-escapes "^3.0.0" chalk "^2.0.1" exit "^0.1.2" graceful-fs "^4.1.15" - jest-changed-files "^24.7.0" - jest-config "^24.7.1" - jest-haste-map "^24.7.1" - jest-message-util "^24.7.1" + jest-changed-files "^24.8.0" + jest-config "^24.8.0" + jest-haste-map "^24.8.0" + jest-message-util "^24.8.0" jest-regex-util "^24.3.0" - jest-resolve-dependencies "^24.7.1" - jest-runner "^24.7.1" - jest-runtime "^24.7.1" - jest-snapshot "^24.7.1" - jest-util "^24.7.1" - jest-validate "^24.7.0" - jest-watcher "^24.7.1" + jest-resolve-dependencies "^24.8.0" + jest-runner "^24.8.0" + jest-runtime "^24.8.0" + jest-snapshot "^24.8.0" + jest-util "^24.8.0" + jest-validate "^24.8.0" + jest-watcher "^24.8.0" micromatch "^3.1.10" p-each-series "^1.0.0" pirates "^4.0.1" @@ -794,24 +794,15 @@ rimraf "^2.5.4" strip-ansi "^5.0.0" -"@jest/environment@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-24.7.1.tgz#9b9196bc737561f67ac07817d4c5ece772e33135" - integrity sha512-wmcTTYc4/KqA+U5h1zQd5FXXynfa7VGP2NfF+c6QeGJ7c+2nStgh65RQWNX62SC716dTtqheTRrZl0j+54oGHw== +"@jest/environment@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-24.8.0.tgz#0342261383c776bdd652168f68065ef144af0eac" + integrity sha512-vlGt2HLg7qM+vtBrSkjDxk9K0YtRBi7HfRFaDxoRtyi+DyVChzhF20duvpdAnKVBV6W5tym8jm0U9EfXbDk1tw== dependencies: - "@jest/fake-timers" "^24.7.1" - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" - jest-mock "^24.7.0" - -"@jest/fake-timers@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-24.7.1.tgz#56e5d09bdec09ee81050eaff2794b26c71d19db2" - integrity sha512-4vSQJDKfR2jScOe12L9282uiwuwQv9Lk7mgrCSZHA9evB9efB/qx8i0KJxsAKtp8fgJYBJdYY7ZU6u3F4/pyjA== - dependencies: - "@jest/types" "^24.7.0" - jest-message-util "^24.7.1" - jest-mock "^24.7.0" + "@jest/fake-timers" "^24.8.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" + jest-mock "^24.8.0" "@jest/fake-timers@^24.8.0": version "24.8.0" @@ -822,26 +813,27 @@ jest-message-util "^24.8.0" jest-mock "^24.8.0" -"@jest/reporters@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-24.7.1.tgz#38ac0b096cd691bbbe3051ddc25988d42e37773a" - integrity sha512-bO+WYNwHLNhrjB9EbPL4kX/mCCG4ZhhfWmO3m4FSpbgr7N83MFejayz30kKjgqr7smLyeaRFCBQMbXpUgnhAJw== +"@jest/reporters@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-24.8.0.tgz#075169cd029bddec54b8f2c0fc489fd0b9e05729" + integrity sha512-eZ9TyUYpyIIXfYCrw0UHUWUvE35vx5I92HGMgS93Pv7du+GHIzl+/vh8Qj9MCWFK/4TqyttVBPakWMOfZRIfxw== dependencies: - "@jest/environment" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/environment" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" exit "^0.1.2" glob "^7.1.2" - istanbul-api "^2.1.1" istanbul-lib-coverage "^2.0.2" istanbul-lib-instrument "^3.0.1" + istanbul-lib-report "^2.0.4" istanbul-lib-source-maps "^3.0.1" - jest-haste-map "^24.7.1" - jest-resolve "^24.7.1" - jest-runtime "^24.7.1" - jest-util "^24.7.1" + istanbul-reports "^2.1.1" + jest-haste-map "^24.8.0" + jest-resolve "^24.8.0" + jest-runtime "^24.8.0" + jest-util "^24.8.0" jest-worker "^24.6.0" node-notifier "^5.2.1" slash "^2.0.0" @@ -857,15 +849,6 @@ graceful-fs "^4.1.15" source-map "^0.6.0" -"@jest/test-result@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-24.7.1.tgz#19eacdb29a114300aed24db651e5d975f08b6bbe" - integrity sha512-3U7wITxstdEc2HMfBX7Yx3JZgiNBubwDqQMh+BXmZXHa3G13YWF3p6cK+5g0hGkN3iufg/vGPl3hLxQXD74Npg== - dependencies: - "@jest/console" "^24.7.1" - "@jest/types" "^24.7.0" - "@types/istanbul-lib-coverage" "^2.0.0" - "@jest/test-result@^24.8.0": version "24.8.0" resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-24.8.0.tgz#7675d0aaf9d2484caa65e048d9b467d160f8e9d3" @@ -875,17 +858,17 @@ "@jest/types" "^24.8.0" "@types/istanbul-lib-coverage" "^2.0.0" -"@jest/test-sequencer@^24.7.1": - version "24.7.1" - resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-24.7.1.tgz#9c18e428e1ad945fa74f6233a9d35745ca0e63e0" - integrity sha512-84HQkCpVZI/G1zq53gHJvSmhUer4aMYp9tTaffW28Ih5OxfCg8hGr3nTSbL1OhVDRrFZwvF+/R9gY6JRkDUpUA== +"@jest/test-sequencer@^24.8.0": + version "24.8.0" + resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-24.8.0.tgz#2f993bcf6ef5eb4e65e8233a95a3320248cf994b" + integrity sha512-OzL/2yHyPdCHXEzhoBuq37CE99nkme15eHkAzXRVqthreWZamEMA0WoetwstsQBCXABhczpK03JNbc4L01vvLg== dependencies: - "@jest/test-result" "^24.7.1" - jest-haste-map "^24.7.1" - jest-runner "^24.7.1" - jest-runtime "^24.7.1" + "@jest/test-result" "^24.8.0" + jest-haste-map "^24.8.0" + jest-runner "^24.8.0" + jest-runtime "^24.8.0" -"@jest/transform@^24.7.1", "@jest/transform@^24.8.0": +"@jest/transform@^24.8.0": version "24.8.0" resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-24.8.0.tgz#628fb99dce4f9d254c6fd9341e3eea262e06fef5" integrity sha512-xBMfFUP7TortCs0O+Xtez2W7Zu1PLH9bvJgtraN1CDST6LBM/eTOZ9SfwS/lvV8yOfcDpFmwf9bq5cYbXvqsvA== @@ -906,7 +889,7 @@ source-map "^0.6.1" write-file-atomic "2.4.1" -"@jest/types@^24.7.0", "@jest/types@^24.8.0": +"@jest/types@^24.8.0": version "24.8.0" resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.8.0.tgz#f31e25948c58f0abd8c845ae26fcea1491dea7ad" integrity sha512-g17UxVr2YfBtaMUxn9u/4+siG1ptg9IGYAYwvpwn61nBg779RXnjE/m7CxYcIzEt0AbHZZAHSEZNhkE2WxURVg== @@ -1591,13 +1574,6 @@ apollo-utilities@1.2.1, apollo-utilities@^1.0.1, apollo-utilities@^1.2.1: ts-invariant "^0.2.1" tslib "^1.9.3" -append-transform@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/append-transform/-/append-transform-1.0.0.tgz#046a52ae582a228bd72f58acfbe2967c678759ab" - integrity sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw== - dependencies: - default-require-extensions "^2.0.0" - aproba@^1.0.3: version "1.2.0" resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" @@ -1756,7 +1732,7 @@ async@^1.5.2: resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" integrity sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo= -async@^2.5.0, async@^2.6.1: +async@^2.5.0: version "2.6.1" resolved "https://registry.yarnpkg.com/async/-/async-2.6.1.tgz#b245a23ca71930044ec53fa46aa00a3e87c6a610" integrity sha512-fNEiL2+AZt6AlAw/29Cr0UDe4sRAHCpEHh54WMz+Bb7QfNcFw4h3loofyJpLeQs4Yx7yuqu/2dLgM5hKOs6HlQ== @@ -1824,7 +1800,7 @@ babel-eslint@~10.0.1: eslint-scope "3.7.1" eslint-visitor-keys "^1.0.0" -babel-jest@^24.7.1, babel-jest@~24.8.0: +babel-jest@^24.8.0, babel-jest@~24.8.0: version "24.8.0" resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-24.8.0.tgz#5c15ff2b28e20b0f45df43fe6b7f2aae93dba589" integrity sha512-+5/kaZt4I9efoXzPlZASyK/lN9qdRKmmUav9smVc0ruPQD7IsfucQ87gpOE8mn2jbDuS6M/YOW6n3v9ZoIfgnw== @@ -2340,11 +2316,6 @@ commondir@^1.0.1: resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= -compare-versions@^3.2.1: - version "3.4.0" - resolved "https://registry.yarnpkg.com/compare-versions/-/compare-versions-3.4.0.tgz#e0747df5c9cb7f054d6d3dc3e1dbc444f9e92b26" - integrity sha512-tK69D7oNXXqUW3ZNo/z7NXTEz22TCF0pTE+YF9cxvaAM9XnkLo1fV621xCLrRR6aevJlKxExkss0vWqUCUpqdg== - component-emitter@^1.2.0, component-emitter@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6" @@ -2665,13 +2636,6 @@ deep-is@~0.1.3: resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= -default-require-extensions@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-2.0.0.tgz#f5f8fbb18a7d6d50b21f641f649ebb522cfe24f7" - integrity sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc= - dependencies: - strip-bom "^3.0.0" - define-properties@^1.1.2: version "1.1.3" resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" @@ -3276,16 +3240,16 @@ expect-ct@0.2.0: resolved "https://registry.yarnpkg.com/expect-ct/-/expect-ct-0.2.0.tgz#3a54741b6ed34cc7a93305c605f63cd268a54a62" integrity sha512-6SK3MG/Bbhm8MsgyJAylg+ucIOU71/FzyFalcfu5nY19dH8y/z0tBJU0wrNBXD4B27EoQtqPF/9wqH0iYAd04g== -expect@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/expect/-/expect-24.7.1.tgz#d91defbab4e627470a152feaf35b3c31aa1c7c14" - integrity sha512-mGfvMTPduksV3xoI0xur56pQsg2vJjNf5+a+bXOjqCkiCBbmCayrBbHS/75y9K430cfqyocPr2ZjiNiRx4SRKw== +expect@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/expect/-/expect-24.8.0.tgz#471f8ec256b7b6129ca2524b2a62f030df38718d" + integrity sha512-/zYvP8iMDrzaaxHVa724eJBCKqSHmO0FA7EDkBiRHxg6OipmMn1fN+C8T9L9K8yr7UONkOifu6+LLH+z76CnaA== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" ansi-styles "^3.2.0" - jest-get-type "^24.3.0" - jest-matcher-utils "^24.7.0" - jest-message-util "^24.7.1" + jest-get-type "^24.8.0" + jest-matcher-utils "^24.8.0" + jest-message-util "^24.8.0" jest-regex-util "^24.3.0" express@^4.0.0, express@^4.16.3, express@~4.16.4: @@ -3428,14 +3392,6 @@ file-entry-cache@^5.0.1: dependencies: flat-cache "^2.0.1" -fileset@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/fileset/-/fileset-2.0.3.tgz#8e7548a96d3cc2327ee5e674168723a333bba2a0" - integrity sha1-jnVIqW08wjJ+5eZ0FocjozO7oqA= - dependencies: - glob "^7.0.3" - minimatch "^3.0.3" - fill-range@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-4.0.0.tgz#d544811d428f98eb06a63dc402d2403c328c38f7" @@ -3648,7 +3604,7 @@ glob-parent@^3.1.0: is-glob "^3.1.0" path-dirname "^1.0.0" -glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: +glob@^7.0.0, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: version "7.1.3" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.3.tgz#3960832d3f1574108342dafd3a67b332c0969df1" integrity sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ== @@ -4522,38 +4478,12 @@ isstream@~0.1.2: resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= -istanbul-api@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/istanbul-api/-/istanbul-api-2.1.1.tgz#194b773f6d9cbc99a9258446848b0f988951c4d0" - integrity sha512-kVmYrehiwyeBAk/wE71tW6emzLiHGjYIiDrc8sfyty4F8M02/lrgXSm+R1kXysmF20zArvmZXjlE/mg24TVPJw== - dependencies: - async "^2.6.1" - compare-versions "^3.2.1" - fileset "^2.0.3" - istanbul-lib-coverage "^2.0.3" - istanbul-lib-hook "^2.0.3" - istanbul-lib-instrument "^3.1.0" - istanbul-lib-report "^2.0.4" - istanbul-lib-source-maps "^3.0.2" - istanbul-reports "^2.1.1" - js-yaml "^3.12.0" - make-dir "^1.3.0" - minimatch "^3.0.4" - once "^1.4.0" - istanbul-lib-coverage@^2.0.2, istanbul-lib-coverage@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.3.tgz#0b891e5ad42312c2b9488554f603795f9a2211ba" integrity sha512-dKWuzRGCs4G+67VfW9pBFFz2Jpi4vSp/k7zBcJ888ofV5Mi1g5CUML5GvMvV6u9Cjybftu+E8Cgp+k0dI1E5lw== -istanbul-lib-hook@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/istanbul-lib-hook/-/istanbul-lib-hook-2.0.3.tgz#e0e581e461c611be5d0e5ef31c5f0109759916fb" - integrity sha512-CLmEqwEhuCYtGcpNVJjLV1DQyVnIqavMLFHV/DP+np/g3qvdxu3gsPqYoJMXm15sN84xOlckFB3VNvRbf5yEgA== - dependencies: - append-transform "^1.0.0" - -istanbul-lib-instrument@^3.0.0, istanbul-lib-instrument@^3.0.1, istanbul-lib-instrument@^3.1.0: +istanbul-lib-instrument@^3.0.0, istanbul-lib-instrument@^3.0.1: version "3.1.0" resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-3.1.0.tgz#a2b5484a7d445f1f311e93190813fa56dfb62971" integrity sha512-ooVllVGT38HIk8MxDj/OIHXSYvH+1tq/Vb38s8ixt9GoJadXska4WkGY+0wkmtYCZNYtaARniH/DixUGGLZ0uA== @@ -4575,7 +4505,7 @@ istanbul-lib-report@^2.0.4: make-dir "^1.3.0" supports-color "^6.0.0" -istanbul-lib-source-maps@^3.0.1, istanbul-lib-source-maps@^3.0.2: +istanbul-lib-source-maps@^3.0.1: version "3.0.2" resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.2.tgz#f1e817229a9146e8424a28e5d69ba220fda34156" integrity sha512-JX4v0CiKTGp9fZPmoxpu9YEkPbEqCqBbO3403VabKjH+NRXo72HafD5UgnjTEqHL2SAjaZK1XDuDOkn6I5QVfQ== @@ -4598,66 +4528,66 @@ iterall@^1.1.3, iterall@^1.2.1, iterall@^1.2.2: resolved "https://registry.yarnpkg.com/iterall/-/iterall-1.2.2.tgz#92d70deb8028e0c39ff3164fdbf4d8b088130cd7" integrity sha512-yynBb1g+RFUPY64fTrFv7nsjRrENBQJaX2UL+2Szc9REFrSNm1rpSXHGzhmAy7a9uv3vlvgBlXnf9RqmPH1/DA== -jest-changed-files@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-24.7.0.tgz#39d723a11b16ed7b373ac83adc76a69464b0c4fa" - integrity sha512-33BgewurnwSfJrW7T5/ZAXGE44o7swLslwh8aUckzq2e17/2Os1V0QU506ZNik3hjs8MgnEMKNkcud442NCDTw== +jest-changed-files@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-24.8.0.tgz#7e7eb21cf687587a85e50f3d249d1327e15b157b" + integrity sha512-qgANC1Yrivsq+UrLXsvJefBKVoCsKB0Hv+mBb6NMjjZ90wwxCDmU3hsCXBya30cH+LnPYjwgcU65i6yJ5Nfuug== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" execa "^1.0.0" throat "^4.0.0" -jest-cli@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-24.7.1.tgz#6093a539073b6f4953145abeeb9709cd621044f1" - integrity sha512-32OBoSCVPzcTslGFl6yVCMzB2SqX3IrWwZCY5mZYkb0D2WsogmU3eV2o8z7+gRQa4o4sZPX/k7GU+II7CxM6WQ== +jest-cli@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-24.8.0.tgz#b075ac914492ed114fa338ade7362a301693e989" + integrity sha512-+p6J00jSMPQ116ZLlHJJvdf8wbjNbZdeSX9ptfHX06/MSNaXmKihQzx5vQcw0q2G6JsdVkUIdWbOWtSnaYs3yA== dependencies: - "@jest/core" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/core" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" exit "^0.1.2" import-local "^2.0.0" is-ci "^2.0.0" - jest-config "^24.7.1" - jest-util "^24.7.1" - jest-validate "^24.7.0" + jest-config "^24.8.0" + jest-util "^24.8.0" + jest-validate "^24.8.0" prompts "^2.0.1" realpath-native "^1.1.0" yargs "^12.0.2" -jest-config@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-24.7.1.tgz#6c1dd4db82a89710a3cf66bdba97827c9a1cf052" - integrity sha512-8FlJNLI+X+MU37j7j8RE4DnJkvAghXmBWdArVzypW6WxfGuxiL/CCkzBg0gHtXhD2rxla3IMOSUAHylSKYJ83g== +jest-config@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-24.8.0.tgz#77db3d265a6f726294687cbbccc36f8a76ee0f4f" + integrity sha512-Czl3Nn2uEzVGsOeaewGWoDPD8GStxCpAe0zOYs2x2l0fZAgPbCr3uwUkgNKV3LwE13VXythM946cd5rdGkkBZw== dependencies: "@babel/core" "^7.1.0" - "@jest/test-sequencer" "^24.7.1" - "@jest/types" "^24.7.0" - babel-jest "^24.7.1" + "@jest/test-sequencer" "^24.8.0" + "@jest/types" "^24.8.0" + babel-jest "^24.8.0" chalk "^2.0.1" glob "^7.1.1" - jest-environment-jsdom "^24.7.1" - jest-environment-node "^24.7.1" - jest-get-type "^24.3.0" - jest-jasmine2 "^24.7.1" + jest-environment-jsdom "^24.8.0" + jest-environment-node "^24.8.0" + jest-get-type "^24.8.0" + jest-jasmine2 "^24.8.0" jest-regex-util "^24.3.0" - jest-resolve "^24.7.1" - jest-util "^24.7.1" - jest-validate "^24.7.0" + jest-resolve "^24.8.0" + jest-util "^24.8.0" + jest-validate "^24.8.0" micromatch "^3.1.10" - pretty-format "^24.7.0" + pretty-format "^24.8.0" realpath-native "^1.1.0" -jest-diff@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-24.7.0.tgz#5d862899be46249754806f66e5729c07fcb3580f" - integrity sha512-ULQZ5B1lWpH70O4xsANC4tf4Ko6RrpwhE3PtG6ERjMg1TiYTC2Wp4IntJVGro6a8HG9luYHhhmF4grF0Pltckg== +jest-diff@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-24.8.0.tgz#146435e7d1e3ffdf293d53ff97e193f1d1546172" + integrity sha512-wxetCEl49zUpJ/bvUmIFjd/o52J+yWcoc5ZyPq4/W1LUKGEhRYDIbP1KcF6t+PvqNrGAFk4/JhtxDq/Nnzs66g== dependencies: chalk "^2.0.1" diff-sequences "^24.3.0" - jest-get-type "^24.3.0" - pretty-format "^24.7.0" + jest-get-type "^24.8.0" + pretty-format "^24.8.0" jest-docblock@^24.3.0: version "24.3.0" @@ -4666,63 +4596,44 @@ jest-docblock@^24.3.0: dependencies: detect-newline "^2.1.0" -jest-each@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-24.7.1.tgz#fcc7dda4147c28430ad9fb6dc7211cd17ab54e74" - integrity sha512-4fsS8fEfLa3lfnI1Jw6NxjhyRTgfpuOVTeUZZFyVYqeTa4hPhr2YkToUhouuLTrL2eMGOfpbdMyRx0GQ/VooKA== +jest-each@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-24.8.0.tgz#a05fd2bf94ddc0b1da66c6d13ec2457f35e52775" + integrity sha512-NrwK9gaL5+XgrgoCsd9svsoWdVkK4gnvyhcpzd6m487tXHqIdYeykgq3MKI1u4I+5Zf0tofr70at9dWJDeb+BA== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" - jest-get-type "^24.3.0" - jest-util "^24.7.1" - pretty-format "^24.7.0" + jest-get-type "^24.8.0" + jest-util "^24.8.0" + pretty-format "^24.8.0" -jest-environment-jsdom@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-24.7.1.tgz#a40e004b4458ebeb8a98082df135fd501b9fbbd6" - integrity sha512-Gnhb+RqE2JuQGb3kJsLF8vfqjt3PHKSstq4Xc8ic+ax7QKo4Z0RWGucU3YV+DwKR3T9SYc+3YCUQEJs8r7+Jxg== +jest-environment-jsdom@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-24.8.0.tgz#300f6949a146cabe1c9357ad9e9ecf9f43f38857" + integrity sha512-qbvgLmR7PpwjoFjM/sbuqHJt/NCkviuq9vus9NBn/76hhSidO+Z6Bn9tU8friecegbJL8gzZQEMZBQlFWDCwAQ== dependencies: - "@jest/environment" "^24.7.1" - "@jest/fake-timers" "^24.7.1" - "@jest/types" "^24.7.0" - jest-mock "^24.7.0" - jest-util "^24.7.1" + "@jest/environment" "^24.8.0" + "@jest/fake-timers" "^24.8.0" + "@jest/types" "^24.8.0" + jest-mock "^24.8.0" + jest-util "^24.8.0" jsdom "^11.5.1" -jest-environment-node@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-24.7.1.tgz#fa2c047a31522a48038d26ee4f7c8fd9c1ecfe12" - integrity sha512-GJJQt1p9/C6aj6yNZMvovZuxTUd+BEJprETdvTKSb4kHcw4mFj8777USQV0FJoJ4V3djpOwA5eWyPwfq//PFBA== +jest-environment-node@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-24.8.0.tgz#d3f726ba8bc53087a60e7a84ca08883a4c892231" + integrity sha512-vIGUEScd1cdDgR6sqn2M08sJTRLQp6Dk/eIkCeO4PFHxZMOgy+uYLPMC4ix3PEfM5Au/x3uQ/5Tl0DpXXZsJ/Q== dependencies: - "@jest/environment" "^24.7.1" - "@jest/fake-timers" "^24.7.1" - "@jest/types" "^24.7.0" - jest-mock "^24.7.0" - jest-util "^24.7.1" + "@jest/environment" "^24.8.0" + "@jest/fake-timers" "^24.8.0" + "@jest/types" "^24.8.0" + jest-mock "^24.8.0" + jest-util "^24.8.0" -jest-get-type@^24.3.0: - version "24.3.0" - resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-24.3.0.tgz#582cfd1a4f91b5cdad1d43d2932f816d543c65da" - integrity sha512-HYF6pry72YUlVcvUx3sEpMRwXEWGEPlJ0bSPVnB3b3n++j4phUEoSPcS6GC0pPJ9rpyPSe4cb5muFo6D39cXow== - -jest-haste-map@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.7.1.tgz#772e215cd84080d4bbcb759cfb668ad649a21471" - integrity sha512-g0tWkzjpHD2qa03mTKhlydbmmYiA2KdcJe762SbfFo/7NIMgBWAA0XqQlApPwkWOF7Cxoi/gUqL0i6DIoLpMBw== - dependencies: - "@jest/types" "^24.7.0" - anymatch "^2.0.0" - fb-watchman "^2.0.0" - graceful-fs "^4.1.15" - invariant "^2.2.4" - jest-serializer "^24.4.0" - jest-util "^24.7.1" - jest-worker "^24.6.0" - micromatch "^3.1.10" - sane "^4.0.3" - walker "^1.0.7" - optionalDependencies: - fsevents "^1.2.7" +jest-get-type@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-24.8.0.tgz#a7440de30b651f5a70ea3ed7ff073a32dfe646fc" + integrity sha512-RR4fo8jEmMD9zSz2nLbs2j0zvPpk/KCEz3a62jJWbd2ayNo0cb+KFRxPHVhE4ZmgGJEQp0fosmNz84IfqM8cMQ== jest-haste-map@^24.8.0: version "24.8.0" @@ -4743,58 +4654,44 @@ jest-haste-map@^24.8.0: optionalDependencies: fsevents "^1.2.7" -jest-jasmine2@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-24.7.1.tgz#01398686dabe46553716303993f3be62e5d9d818" - integrity sha512-Y/9AOJDV1XS44wNwCaThq4Pw3gBPiOv/s6NcbOAkVRRUEPu+36L2xoPsqQXsDrxoBerqeyslpn2TpCI8Zr6J2w== +jest-jasmine2@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-24.8.0.tgz#a9c7e14c83dd77d8b15e820549ce8987cc8cd898" + integrity sha512-cEky88npEE5LKd5jPpTdDCLvKkdyklnaRycBXL6GNmpxe41F0WN44+i7lpQKa/hcbXaQ+rc9RMaM4dsebrYong== dependencies: "@babel/traverse" "^7.1.0" - "@jest/environment" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/environment" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" co "^4.6.0" - expect "^24.7.1" + expect "^24.8.0" is-generator-fn "^2.0.0" - jest-each "^24.7.1" - jest-matcher-utils "^24.7.0" - jest-message-util "^24.7.1" - jest-runtime "^24.7.1" - jest-snapshot "^24.7.1" - jest-util "^24.7.1" - pretty-format "^24.7.0" + jest-each "^24.8.0" + jest-matcher-utils "^24.8.0" + jest-message-util "^24.8.0" + jest-runtime "^24.8.0" + jest-snapshot "^24.8.0" + jest-util "^24.8.0" + pretty-format "^24.8.0" throat "^4.0.0" -jest-leak-detector@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-24.7.0.tgz#323ff93ed69be12e898f5b040952f08a94288ff9" - integrity sha512-zV0qHKZGXtmPVVzT99CVEcHE9XDf+8LwiE0Ob7jjezERiGVljmqKFWpV2IkG+rkFIEUHFEkMiICu7wnoPM/RoQ== +jest-leak-detector@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-24.8.0.tgz#c0086384e1f650c2d8348095df769f29b48e6980" + integrity sha512-cG0yRSK8A831LN8lIHxI3AblB40uhv0z+SsQdW3GoMMVcK+sJwrIIyax5tu3eHHNJ8Fu6IMDpnLda2jhn2pD/g== dependencies: - pretty-format "^24.7.0" + pretty-format "^24.8.0" -jest-matcher-utils@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-24.7.0.tgz#bbee1ff37bc8b2e4afcaabc91617c1526af4bcd4" - integrity sha512-158ieSgk3LNXeUhbVJYRXyTPSCqNgVXOp/GT7O94mYd3pk/8+odKTyR1JLtNOQSPzNi8NFYVONtvSWA/e1RDXg== +jest-matcher-utils@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-24.8.0.tgz#2bce42204c9af12bde46f83dc839efe8be832495" + integrity sha512-lex1yASY51FvUuHgm0GOVj7DCYEouWSlIYmCW7APSqB9v8mXmKSn5+sWVF0MhuASG0bnYY106/49JU1FZNl5hw== dependencies: chalk "^2.0.1" - jest-diff "^24.7.0" - jest-get-type "^24.3.0" - pretty-format "^24.7.0" - -jest-message-util@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-24.7.1.tgz#f1dc3a6c195647096a99d0f1dadbc447ae547018" - integrity sha512-dk0gqVtyqezCHbcbk60CdIf+8UHgD+lmRHifeH3JRcnAqh4nEyPytSc9/L1+cQyxC+ceaeP696N4ATe7L+omcg== - dependencies: - "@babel/code-frame" "^7.0.0" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" - "@types/stack-utils" "^1.0.1" - chalk "^2.0.1" - micromatch "^3.1.10" - slash "^2.0.0" - stack-utils "^1.0.1" + jest-diff "^24.8.0" + jest-get-type "^24.8.0" + pretty-format "^24.8.0" jest-message-util@^24.8.0: version "24.8.0" @@ -4810,13 +4707,6 @@ jest-message-util@^24.8.0: slash "^2.0.0" stack-utils "^1.0.1" -jest-mock@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.7.0.tgz#e49ce7262c12d7f5897b0d8af77f6db8e538023b" - integrity sha512-6taW4B4WUcEiT2V9BbOmwyGuwuAFT2G8yghF7nyNW1/2gq5+6aTqSPcS9lS6ArvEkX55vbPAS/Jarx5LSm4Fng== - dependencies: - "@jest/types" "^24.7.0" - jest-mock@^24.8.0: version "24.8.0" resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.8.0.tgz#2f9d14d37699e863f1febf4e4d5a33b7fdbbde56" @@ -4834,75 +4724,75 @@ jest-regex-util@^24.3.0: resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-24.3.0.tgz#d5a65f60be1ae3e310d5214a0307581995227b36" integrity sha512-tXQR1NEOyGlfylyEjg1ImtScwMq8Oh3iJbGTjN7p0J23EuVX1MA8rwU69K4sLbCmwzgCUbVkm0FkSF9TdzOhtg== -jest-resolve-dependencies@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-24.7.1.tgz#cf93bbef26999488a96a2b2012f9fe7375aa378f" - integrity sha512-2Eyh5LJB2liNzfk4eo7bD1ZyBbqEJIyyrFtZG555cSWW9xVHxII2NuOkSl1yUYTAYCAmM2f2aIT5A7HzNmubyg== +jest-resolve-dependencies@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-24.8.0.tgz#19eec3241f2045d3f990dba331d0d7526acff8e0" + integrity sha512-hyK1qfIf/krV+fSNyhyJeq3elVMhK9Eijlwy+j5jqmZ9QsxwKBiP6qukQxaHtK8k6zql/KYWwCTQ+fDGTIJauw== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" jest-regex-util "^24.3.0" - jest-snapshot "^24.7.1" + jest-snapshot "^24.8.0" -jest-resolve@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-24.7.1.tgz#e4150198299298380a75a9fd55043fa3b9b17fde" - integrity sha512-Bgrc+/UUZpGJ4323sQyj85hV9d+ANyPNu6XfRDUcyFNX1QrZpSoM0kE4Mb2vZMAYTJZsBFzYe8X1UaOkOELSbw== +jest-resolve@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-24.8.0.tgz#84b8e5408c1f6a11539793e2b5feb1b6e722439f" + integrity sha512-+hjSzi1PoRvnuOICoYd5V/KpIQmkAsfjFO71458hQ2Whi/yf1GDeBOFj8Gxw4LrApHsVJvn5fmjcPdmoUHaVKw== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" browser-resolve "^1.11.3" chalk "^2.0.1" jest-pnp-resolver "^1.2.1" realpath-native "^1.1.0" -jest-runner@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-24.7.1.tgz#41c8a02a06aa23ea82d8bffd69d7fa98d32f85bf" - integrity sha512-aNFc9liWU/xt+G9pobdKZ4qTeG/wnJrJna3VqunziDNsWT3EBpmxXZRBMKCsNMyfy+A/XHiV+tsMLufdsNdgCw== +jest-runner@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-24.8.0.tgz#4f9ae07b767db27b740d7deffad0cf67ccb4c5bb" + integrity sha512-utFqC5BaA3JmznbissSs95X1ZF+d+4WuOWwpM9+Ak356YtMhHE/GXUondZdcyAAOTBEsRGAgH/0TwLzfI9h7ow== dependencies: "@jest/console" "^24.7.1" - "@jest/environment" "^24.7.1" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/environment" "^24.8.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" chalk "^2.4.2" exit "^0.1.2" graceful-fs "^4.1.15" - jest-config "^24.7.1" + jest-config "^24.8.0" jest-docblock "^24.3.0" - jest-haste-map "^24.7.1" - jest-jasmine2 "^24.7.1" - jest-leak-detector "^24.7.0" - jest-message-util "^24.7.1" - jest-resolve "^24.7.1" - jest-runtime "^24.7.1" - jest-util "^24.7.1" + jest-haste-map "^24.8.0" + jest-jasmine2 "^24.8.0" + jest-leak-detector "^24.8.0" + jest-message-util "^24.8.0" + jest-resolve "^24.8.0" + jest-runtime "^24.8.0" + jest-util "^24.8.0" jest-worker "^24.6.0" source-map-support "^0.5.6" throat "^4.0.0" -jest-runtime@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-24.7.1.tgz#2ffd70b22dd03a5988c0ab9465c85cdf5d25c597" - integrity sha512-0VAbyBy7tll3R+82IPJpf6QZkokzXPIS71aDeqh+WzPRXRCNz6StQ45otFariPdJ4FmXpDiArdhZrzNAC3sj6A== +jest-runtime@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-24.8.0.tgz#05f94d5b05c21f6dc54e427cd2e4980923350620" + integrity sha512-Mq0aIXhvO/3bX44ccT+czU1/57IgOMyy80oM0XR/nyD5zgBcesF84BPabZi39pJVA6UXw+fY2Q1N+4BiVUBWOA== dependencies: "@jest/console" "^24.7.1" - "@jest/environment" "^24.7.1" + "@jest/environment" "^24.8.0" "@jest/source-map" "^24.3.0" - "@jest/transform" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/transform" "^24.8.0" + "@jest/types" "^24.8.0" "@types/yargs" "^12.0.2" chalk "^2.0.1" exit "^0.1.2" glob "^7.1.3" graceful-fs "^4.1.15" - jest-config "^24.7.1" - jest-haste-map "^24.7.1" - jest-message-util "^24.7.1" - jest-mock "^24.7.0" + jest-config "^24.8.0" + jest-haste-map "^24.8.0" + jest-message-util "^24.8.0" + jest-mock "^24.8.0" jest-regex-util "^24.3.0" - jest-resolve "^24.7.1" - jest-snapshot "^24.7.1" - jest-util "^24.7.1" - jest-validate "^24.7.0" + jest-resolve "^24.8.0" + jest-snapshot "^24.8.0" + jest-util "^24.8.0" + jest-validate "^24.8.0" realpath-native "^1.1.0" slash "^2.0.0" strip-bom "^3.0.0" @@ -4913,42 +4803,24 @@ jest-serializer@^24.4.0: resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-24.4.0.tgz#f70c5918c8ea9235ccb1276d232e459080588db3" integrity sha512-k//0DtglVstc1fv+GY/VHDIjrtNjdYvYjMlbLUed4kxrE92sIUewOi5Hj3vrpB8CXfkJntRPDRjCrCvUhBdL8Q== -jest-snapshot@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-24.7.1.tgz#bd5a35f74aedff070975e9e9c90024f082099568" - integrity sha512-8Xk5O4p+JsZZn4RCNUS3pxA+ORKpEKepE+a5ejIKrId9CwrVN0NY+vkqEkXqlstA5NMBkNahXkR/4qEBy0t5yA== +jest-snapshot@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-24.8.0.tgz#3bec6a59da2ff7bc7d097a853fb67f9d415cb7c6" + integrity sha512-5ehtWoc8oU9/cAPe6fez6QofVJLBKyqkY2+TlKTOf0VllBB/mqUNdARdcjlZrs9F1Cv+/HKoCS/BknT0+tmfPg== dependencies: "@babel/types" "^7.0.0" - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" chalk "^2.0.1" - expect "^24.7.1" - jest-diff "^24.7.0" - jest-matcher-utils "^24.7.0" - jest-message-util "^24.7.1" - jest-resolve "^24.7.1" + expect "^24.8.0" + jest-diff "^24.8.0" + jest-matcher-utils "^24.8.0" + jest-message-util "^24.8.0" + jest-resolve "^24.8.0" mkdirp "^0.5.1" natural-compare "^1.4.0" - pretty-format "^24.7.0" + pretty-format "^24.8.0" semver "^5.5.0" -jest-util@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-24.7.1.tgz#b4043df57b32a23be27c75a2763d8faf242038ff" - integrity sha512-/KilOue2n2rZ5AnEBYoxOXkeTu6vi7cjgQ8MXEkih0oeAXT6JkS3fr7/j8+engCjciOU1Nq5loMSKe0A1oeX0A== - dependencies: - "@jest/console" "^24.7.1" - "@jest/fake-timers" "^24.7.1" - "@jest/source-map" "^24.3.0" - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" - callsites "^3.0.0" - chalk "^2.0.1" - graceful-fs "^4.1.15" - is-ci "^2.0.0" - mkdirp "^0.5.1" - slash "^2.0.0" - source-map "^0.6.0" - jest-util@^24.8.0: version "24.8.0" resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-24.8.0.tgz#41f0e945da11df44cc76d64ffb915d0716f46cd1" @@ -4967,29 +4839,29 @@ jest-util@^24.8.0: slash "^2.0.0" source-map "^0.6.0" -jest-validate@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-24.7.0.tgz#70007076f338528ee1b1c8a8258b1b0bb982508d" - integrity sha512-cgai/gts9B2chz1rqVdmLhzYxQbgQurh1PEQSvSgPZ8KGa1AqXsqC45W5wKEwzxKrWqypuQrQxnF4+G9VejJJA== +jest-validate@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-24.8.0.tgz#624c41533e6dfe356ffadc6e2423a35c2d3b4849" + integrity sha512-+/N7VOEMW1Vzsrk3UWBDYTExTPwf68tavEPKDnJzrC6UlHtUDU/fuEdXqFoHzv9XnQ+zW6X3qMZhJ3YexfeLDA== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" camelcase "^5.0.0" chalk "^2.0.1" - jest-get-type "^24.3.0" + jest-get-type "^24.8.0" leven "^2.1.0" - pretty-format "^24.7.0" + pretty-format "^24.8.0" -jest-watcher@^24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-24.7.1.tgz#e161363d7f3f4e1ef3d389b7b3a0aad247b673f5" - integrity sha512-Wd6TepHLRHVKLNPacEsBwlp9raeBIO+01xrN24Dek4ggTS8HHnOzYSFnvp+6MtkkJ3KfMzy220KTi95e2rRkrw== +jest-watcher@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-24.8.0.tgz#58d49915ceddd2de85e238f6213cef1c93715de4" + integrity sha512-SBjwHt5NedQoVu54M5GEx7cl7IGEFFznvd/HNT8ier7cCAx/Qgu9ZMlaTQkvK22G1YOpcWBLQPFSImmxdn3DAw== dependencies: - "@jest/test-result" "^24.7.1" - "@jest/types" "^24.7.0" + "@jest/test-result" "^24.8.0" + "@jest/types" "^24.8.0" "@types/yargs" "^12.0.9" ansi-escapes "^3.0.0" chalk "^2.0.1" - jest-util "^24.7.1" + jest-util "^24.8.0" string-length "^2.0.0" jest-worker@^24.6.0: @@ -5000,13 +4872,13 @@ jest-worker@^24.6.0: merge-stream "^1.0.1" supports-color "^6.1.0" -jest@~24.7.1: - version "24.7.1" - resolved "https://registry.yarnpkg.com/jest/-/jest-24.7.1.tgz#0d94331cf510c75893ee32f87d7321d5bf8f2501" - integrity sha512-AbvRar5r++izmqo5gdbAjTeA6uNRGoNRuj5vHB0OnDXo2DXWZJVuaObiGgtlvhKb+cWy2oYbQSfxv7Q7GjnAtA== +jest@~24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/jest/-/jest-24.8.0.tgz#d5dff1984d0d1002196e9b7f12f75af1b2809081" + integrity sha512-o0HM90RKFRNWmAWvlyV8i5jGZ97pFwkeVoGvPW1EtLTgJc2+jcuqcbbqcSZLE/3f2S5pt0y2ZBETuhpWNl1Reg== dependencies: import-local "^2.0.0" - jest-cli "^24.7.1" + jest-cli "^24.8.0" jmespath@0.15.0: version "0.15.0" @@ -5037,7 +4909,7 @@ js-levenshtein@^1.1.3: resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== -js-yaml@^3.12.0, js-yaml@^3.13.0: +js-yaml@^3.13.0: version "3.13.0" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.0.tgz#38ee7178ac0eea2c97ff6d96fff4b18c7d8cf98e" integrity sha512-pZZoSxcCYco+DIKBTimr67J6Hy+EYGZDY/HCWC+iAEA9h1ByhMXAIVUXMcMFpOCxQ/xjXmPI2MkDL5HRm5eFrQ== @@ -5553,7 +5425,7 @@ minimalistic-assert@^1.0.1: resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== -minimatch@^3.0.3, minimatch@^3.0.4: +minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== @@ -6314,12 +6186,12 @@ prepend-http@^1.0.1: resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc" integrity sha1-1PRWKwzjaW5BrFLQ4ALlemNdxtw= -pretty-format@^24.7.0: - version "24.7.0" - resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-24.7.0.tgz#d23106bc2edcd776079c2daa5da02bcb12ed0c10" - integrity sha512-apen5cjf/U4dj7tHetpC7UEFCvtAgnNZnBDkfPv3fokzIqyOJckAG9OlAPC1BlFALnqT/lGB2tl9EJjlK6eCsA== +pretty-format@^24.8.0: + version "24.8.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-24.8.0.tgz#8dae7044f58db7cb8be245383b565a963e3c27f2" + integrity sha512-P952T7dkrDEplsR+TuY7q3VXDae5Sr7zmQb12JU/NDQa/3CH7/QW0yvqLcGN6jL+zQFKaoJcPc+yJxMTGmosqw== dependencies: - "@jest/types" "^24.7.0" + "@jest/types" "^24.8.0" ansi-regex "^4.0.0" ansi-styles "^3.2.0" react-is "^16.8.4" From b5d91cffef244956951882ef42770238d7c09260 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Tue, 7 May 2019 19:14:57 +0200 Subject: [PATCH 48/82] Implement @appinteractive's suggestions This: https://github.com/Human-Connection/Human-Connection/pull/529#discussion_r280065855 --- .../maintenance-worker/migration/mongo/import.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deployment/legacy-migration/maintenance-worker/migration/mongo/import.sh b/deployment/legacy-migration/maintenance-worker/migration/mongo/import.sh index 8958dd2a8..d68a8c2a8 100755 --- a/deployment/legacy-migration/maintenance-worker/migration/mongo/import.sh +++ b/deployment/legacy-migration/maintenance-worker/migration/mongo/import.sh @@ -19,7 +19,7 @@ for collection in "categories" "badges" "users" "contributions" "comments" "foll do mongoexport --db ${MONGODB_DATABASE} --host localhost -d ${MONGODB_DATABASE} --port 27018 --username ${MONGODB_USERNAME} --password ${MONGODB_PASSWORD} --authenticationDatabase ${MONGODB_AUTH_DB} --collection $collection --collection $collection --out "/tmp/mongo-export/$collection.json" mkdir -p /tmp/mongo-export/splits/$collection/ - split -l 500 /tmp/mongo-export/$collection.json /tmp/mongo-export/splits/$collection/ + split -l 1000 -a 3 /tmp/mongo-export/$collection.json /tmp/mongo-export/splits/$collection/ done ssh -S my-ctrl-socket -O check -l ${SSH_USERNAME} ${SSH_HOST} From 7c139bed1a297c8b587d77be2c5ba26ffba4b055 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Fri, 3 May 2019 17:05:37 +0200 Subject: [PATCH 49/82] Remove obsolete binary to create RSA keys We can supply files on kubernetes through secrets --- .../binaries/create_private_ssh_key_from_env | 6 ------ .../maintenance-worker/binaries/import_legacy_uploads | 1 - .../legacy-migration/maintenance-worker/docker-compose.yml | 3 +-- 3 files changed, 1 insertion(+), 9 deletions(-) delete mode 100755 deployment/legacy-migration/maintenance-worker/binaries/create_private_ssh_key_from_env diff --git a/deployment/legacy-migration/maintenance-worker/binaries/create_private_ssh_key_from_env b/deployment/legacy-migration/maintenance-worker/binaries/create_private_ssh_key_from_env deleted file mode 100755 index f44671978..000000000 --- a/deployment/legacy-migration/maintenance-worker/binaries/create_private_ssh_key_from_env +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env bash -set -e - -mkdir -p ~/.ssh -echo $SSH_PRIVATE_KEY | base64 -d > ~/.ssh/id_rsa -chmod 600 ~/.ssh/id_rsa diff --git a/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_uploads b/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_uploads index 24ae0fca5..d24936e3b 100755 --- a/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_uploads +++ b/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_uploads @@ -9,5 +9,4 @@ do fi done -[ -z "$SSH_PRIVATE_KEY" ] || create_private_ssh_key_from_env rsync --archive --update --verbose ${SSH_USERNAME}@${SSH_HOST}:${UPLOADS_DIRECTORY}/* /uploads/ diff --git a/deployment/legacy-migration/maintenance-worker/docker-compose.yml b/deployment/legacy-migration/maintenance-worker/docker-compose.yml index a45a5163a..03b545982 100644 --- a/deployment/legacy-migration/maintenance-worker/docker-compose.yml +++ b/deployment/legacy-migration/maintenance-worker/docker-compose.yml @@ -9,6 +9,7 @@ services: - uploads:/uploads - neo4j-data:/data - ./migration/:/migration + - ./ssh/:/root/.ssh networks: - hc-network environment: @@ -19,12 +20,10 @@ services: - MOCK=false - MAPBOX_TOKEN=pk.eyJ1IjoiaHVtYW4tY29ubmVjdGlvbiIsImEiOiJjajl0cnBubGoweTVlM3VwZ2lzNTNud3ZtIn0.KZ8KK9l70omjXbEkkbHGsQ - PRIVATE_KEY_PASSPHRASE=a7dsf78sadg87ad87sfagsadg78 - - NEO4J_URI=bolt://localhost:7687 - NEO4J_apoc_import_file_enabled=true - NEO4J_AUTH=none - "SSH_USERNAME=${SSH_USERNAME}" - "SSH_HOST=${SSH_HOST}" - - "SSH_PRIVATE_KEY=${SSH_PRIVATE_KEY}" - "MONGODB_USERNAME=${MONGODB_USERNAME}" - "MONGODB_PASSWORD=${MONGODB_PASSWORD}" - "MONGODB_AUTH_DB=${MONGODB_AUTH_DB}" From 5771efc9205cd638568bc73b35c35e5c552efb5e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Fri, 3 May 2019 17:09:45 +0200 Subject: [PATCH 50/82] Add binary `idle` to keep container spinning --- deployment/legacy-migration/maintenance-worker/binaries/idle | 2 ++ .../legacy-migration/maintenance-worker/docker-compose.yml | 1 + 2 files changed, 3 insertions(+) create mode 100755 deployment/legacy-migration/maintenance-worker/binaries/idle diff --git a/deployment/legacy-migration/maintenance-worker/binaries/idle b/deployment/legacy-migration/maintenance-worker/binaries/idle new file mode 100755 index 000000000..f5b1b2454 --- /dev/null +++ b/deployment/legacy-migration/maintenance-worker/binaries/idle @@ -0,0 +1,2 @@ +#!/usr/bin/env bash +tail -f /dev/null diff --git a/deployment/legacy-migration/maintenance-worker/docker-compose.yml b/deployment/legacy-migration/maintenance-worker/docker-compose.yml index 03b545982..a2e4ebc9e 100644 --- a/deployment/legacy-migration/maintenance-worker/docker-compose.yml +++ b/deployment/legacy-migration/maintenance-worker/docker-compose.yml @@ -2,6 +2,7 @@ version: "3.4" services: maintenance: + command: "idle" # remove this line to start neo4j automatically image: humanconnection/maintenance-worker:latest build: context: . From 13906c29aa738206a8b0836007fa178902ec2a94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Tue, 7 May 2019 19:20:58 +0200 Subject: [PATCH 51/82] Setup unique constraints on ids This will * speed up data import from production * make sure we never have the same ids on certain labels --- neo4j/migrate.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/neo4j/migrate.sh b/neo4j/migrate.sh index 1ec5212ad..f52539555 100755 --- a/neo4j/migrate.sh +++ b/neo4j/migrate.sh @@ -4,13 +4,22 @@ # the initial default user. Before we can create constraints, we have to change # the default password. This is a security feature of neo4j. if echo ":exit" | cypher-shell --password neo4j 2> /dev/null ; then - echo "CALL dbms.security.changePassword('${NEO4J_PASSWORD}');" | cypher-shell --password neo4j + neo4j-admin set-initial-password $NEO4J_PASSWORD fi set -e echo ' CALL db.index.fulltext.createNodeIndex("full_text_search",["Post"],["title", "content"]); +CREATE CONSTRAINT ON (p:Post) ASSERT p.id IS UNIQUE; +CREATE CONSTRAINT ON (c:Comment) ASSERT c.id IS UNIQUE; +CREATE CONSTRAINT ON (c:Category) ASSERT c.id IS UNIQUE; +CREATE CONSTRAINT ON (u:User) ASSERT u.id IS UNIQUE; +CREATE CONSTRAINT ON (o:Organization) ASSERT o.id IS UNIQUE; +CREATE CONSTRAINT ON (t:Tag) ASSERT t.id IS UNIQUE; +CREATE CONSTRAINT ON (c:Category) ASSERT c.id IS UNIQUE; + + CREATE CONSTRAINT ON (p:Post) ASSERT p.slug IS UNIQUE; CREATE CONSTRAINT ON (c:Category) ASSERT c.slug IS UNIQUE; CREATE CONSTRAINT ON (u:User) ASSERT u.slug IS UNIQUE; From 099a5c9cf48d139407253abc2082bdef79b3b05b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Tue, 7 May 2019 19:24:59 +0200 Subject: [PATCH 52/82] Remove obsolete docker-compose files Since we moved to a monorepo, we have it in the top level folder. --- backend/docker-compose.prod.yml | 9 --------- webapp/docker-compose.override.yml | 16 ---------------- webapp/docker-compose.travis.yml | 10 ---------- webapp/docker-compose.yml | 23 ----------------------- 4 files changed, 58 deletions(-) delete mode 100644 backend/docker-compose.prod.yml delete mode 100644 webapp/docker-compose.override.yml delete mode 100644 webapp/docker-compose.travis.yml delete mode 100644 webapp/docker-compose.yml diff --git a/backend/docker-compose.prod.yml b/backend/docker-compose.prod.yml deleted file mode 100644 index c4f5dc4f5..000000000 --- a/backend/docker-compose.prod.yml +++ /dev/null @@ -1,9 +0,0 @@ -version: "3.7" - -services: - neo4j: - environment: - - NEO4J_PASSWORD=letmein - backend: - environment: - - NEO4J_PASSWORD=letmein diff --git a/webapp/docker-compose.override.yml b/webapp/docker-compose.override.yml deleted file mode 100644 index 6edc22f25..000000000 --- a/webapp/docker-compose.override.yml +++ /dev/null @@ -1,16 +0,0 @@ -version: '3.7' - -services: - webapp: - build: - context: . - target: build-and-test - volumes: - - .:/nitro-web - - node_modules:/nitro-web/node_modules - - nuxt:/nitro-web/.nuxt - command: yarn run dev - -volumes: - node_modules: - nuxt: diff --git a/webapp/docker-compose.travis.yml b/webapp/docker-compose.travis.yml deleted file mode 100644 index 0f02ea27d..000000000 --- a/webapp/docker-compose.travis.yml +++ /dev/null @@ -1,10 +0,0 @@ -version: "3.7" - -services: - webapp: - build: - context: . - target: build-and-test - environment: - - GRAPHQL_URI=http://backend:4123 - - NODE_ENV=test diff --git a/webapp/docker-compose.yml b/webapp/docker-compose.yml deleted file mode 100644 index f20fdf9f9..000000000 --- a/webapp/docker-compose.yml +++ /dev/null @@ -1,23 +0,0 @@ -version: '3.7' - -services: - webapp: - image: humanconnection/nitro-web:latest - build: - context: . - target: production - ports: - - 3000:3000 - networks: - - hc-network - environment: - - HOST=0.0.0.0 - - GRAPHQL_URI=http://backend:4000 - - MAPBOX_TOKEN="pk.eyJ1IjoiaHVtYW4tY29ubmVjdGlvbiIsImEiOiJjajl0cnBubGoweTVlM3VwZ2lzNTNud3ZtIn0.bZ8KK9l70omjXbEkkbHGsQ" - -networks: - hc-network: - name: hc-network - -volumes: - node_modules: From bcc2c4dbbb260a81ae2a7958d9ce9d9f38bff9c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Tue, 7 May 2019 19:32:35 +0200 Subject: [PATCH 53/82] Configure scripts and docker-compose.yml After endless try/error I found the way to share volumes between multiple docker-compose.ymls: You have to place those files in the same folder. Also the import scripts must be adapted. --- .../binaries/import_legacy_db | 2 +- .../migration/neo4j/import.sh | 3 ++- ...pose.yml => docker-compose.maintenance.yml | 20 ++++++++++--------- docker-compose.override.yml | 2 ++ neo4j/migrate.sh | 10 ++++++++-- 5 files changed, 24 insertions(+), 13 deletions(-) rename deployment/legacy-migration/maintenance-worker/docker-compose.yml => docker-compose.maintenance.yml (74%) diff --git a/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_db b/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_db index 214da53d8..233798527 100755 --- a/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_db +++ b/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_db @@ -1,6 +1,6 @@ #!/usr/bin/env bash set -e -for var in "SSH_USERNAME" "SSH_HOST" "MONGODB_USERNAME" "MONGODB_PASSWORD" "MONGODB_DATABASE" "MONGODB_AUTH_DB" "NEO4J_URI" +for var in "SSH_USERNAME" "SSH_HOST" "MONGODB_USERNAME" "MONGODB_PASSWORD" "MONGODB_DATABASE" "MONGODB_AUTH_DB" do if [[ -z "${!var}" ]]; then echo "${var} is undefined" diff --git a/deployment/legacy-migration/maintenance-worker/migration/neo4j/import.sh b/deployment/legacy-migration/maintenance-worker/migration/neo4j/import.sh index ed033c1b9..b7de74782 100755 --- a/deployment/legacy-migration/maintenance-worker/migration/neo4j/import.sh +++ b/deployment/legacy-migration/maintenance-worker/migration/neo4j/import.sh @@ -1,10 +1,11 @@ #!/usr/bin/env bash set -e +SECONDS=0 SCRIPT_DIRECTORY="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" + echo "MATCH (n) DETACH DELETE n;" | cypher-shell -SECONDS=0 for collection in "badges" "categories" "users" "follows" "contributions" "shouts" "comments" do for chunk in /tmp/mongo-export/splits/$collection/* diff --git a/deployment/legacy-migration/maintenance-worker/docker-compose.yml b/docker-compose.maintenance.yml similarity index 74% rename from deployment/legacy-migration/maintenance-worker/docker-compose.yml rename to docker-compose.maintenance.yml index a2e4ebc9e..113b4492c 100644 --- a/deployment/legacy-migration/maintenance-worker/docker-compose.yml +++ b/docker-compose.maintenance.yml @@ -2,18 +2,19 @@ version: "3.4" services: maintenance: - command: "idle" # remove this line to start neo4j automatically image: humanconnection/maintenance-worker:latest build: - context: . + context: deployment/legacy-migration/maintenance-worker volumes: - uploads:/uploads - neo4j-data:/data - - ./migration/:/migration - - ./ssh/:/root/.ssh + - ./deployment/legacy-migration/maintenance-worker/migration/:/migration + - ./deployment/legacy-migration/maintenance-worker/ssh/:/root/.ssh networks: - hc-network environment: + - NEO4J_dbms_security_auth__enabled=false + - NEO4J_dbms_memory_heap_max__size=2G - GRAPHQL_PORT=4000 - GRAPHQL_URI=http://localhost:4000 - CLIENT_URI=http://localhost:3000 @@ -22,7 +23,6 @@ services: - MAPBOX_TOKEN=pk.eyJ1IjoiaHVtYW4tY29ubmVjdGlvbiIsImEiOiJjajl0cnBubGoweTVlM3VwZ2lzNTNud3ZtIn0.KZ8KK9l70omjXbEkkbHGsQ - PRIVATE_KEY_PASSPHRASE=a7dsf78sadg87ad87sfagsadg78 - NEO4J_apoc_import_file_enabled=true - - NEO4J_AUTH=none - "SSH_USERNAME=${SSH_USERNAME}" - "SSH_HOST=${SSH_HOST}" - "MONGODB_USERNAME=${MONGODB_USERNAME}" @@ -34,9 +34,11 @@ services: - 7687:7687 - 7474:7474 -volumes: - uploads: - neo4j-data: - networks: hc-network: + +volumes: + webapp_node_modules: + backend_node_modules: + neo4j-data: + uploads: diff --git a/docker-compose.override.yml b/docker-compose.override.yml index 26dc68619..a71418229 100644 --- a/docker-compose.override.yml +++ b/docker-compose.override.yml @@ -18,6 +18,7 @@ services: volumes: - ./backend:/nitro-backend - backend_node_modules:/nitro-backend/node_modules + - uploads:/nitro-backend/public/uploads command: yarn run dev neo4j: environment: @@ -32,3 +33,4 @@ volumes: webapp_node_modules: backend_node_modules: neo4j-data: + uploads: diff --git a/neo4j/migrate.sh b/neo4j/migrate.sh index f52539555..6f3361b8a 100755 --- a/neo4j/migrate.sh +++ b/neo4j/migrate.sh @@ -4,7 +4,11 @@ # the initial default user. Before we can create constraints, we have to change # the default password. This is a security feature of neo4j. if echo ":exit" | cypher-shell --password neo4j 2> /dev/null ; then - neo4j-admin set-initial-password $NEO4J_PASSWORD + if [[ -z "${NEO4J_PASSWORD}" ]]; then + echo "NEO4J_PASSWORD environment variable is undefined. I cannot set the initial password." + else + echo "CALL dbms.security.changePassword('${NEO4J_PASSWORD}');" | cypher-shell --password neo4j + fi fi set -e @@ -17,7 +21,6 @@ CREATE CONSTRAINT ON (c:Category) ASSERT c.id IS UNIQUE; CREATE CONSTRAINT ON (u:User) ASSERT u.id IS UNIQUE; CREATE CONSTRAINT ON (o:Organization) ASSERT o.id IS UNIQUE; CREATE CONSTRAINT ON (t:Tag) ASSERT t.id IS UNIQUE; -CREATE CONSTRAINT ON (c:Category) ASSERT c.id IS UNIQUE; CREATE CONSTRAINT ON (p:Post) ASSERT p.slug IS UNIQUE; @@ -25,3 +28,6 @@ CREATE CONSTRAINT ON (c:Category) ASSERT c.slug IS UNIQUE; CREATE CONSTRAINT ON (u:User) ASSERT u.slug IS UNIQUE; CREATE CONSTRAINT ON (o:Organization) ASSERT o.slug IS UNIQUE; ' | cypher-shell + +echo "Successfully created all indices and unique constraints:" +echo 'CALL db.indexes();' | cypher-shell From dfef37b3f6c3516f2d17c2c8929c8a09252d4fa7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Wed, 8 May 2019 00:46:07 +0200 Subject: [PATCH 54/82] Prevent `argument list too long` error --- .../maintenance-worker/binaries/import_legacy_uploads | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_uploads b/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_uploads index d24936e3b..11fd81623 100755 --- a/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_uploads +++ b/deployment/legacy-migration/maintenance-worker/binaries/import_legacy_uploads @@ -9,4 +9,4 @@ do fi done -rsync --archive --update --verbose ${SSH_USERNAME}@${SSH_HOST}:${UPLOADS_DIRECTORY}/* /uploads/ +rsync --archive --update --verbose ${SSH_USERNAME}@${SSH_HOST}:${UPLOADS_DIRECTORY}/ /uploads/ From a35c77fbab082342ed44aedb31a86542982fd0e0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Wed, 8 May 2019 04:51:14 +0000 Subject: [PATCH 55/82] Bump graphql from 14.2.1 to 14.3.0 in /webapp Bumps [graphql](https://github.com/graphql/graphql-js) from 14.2.1 to 14.3.0. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v14.2.1...v14.3.0) Signed-off-by: dependabot[bot] --- webapp/package.json | 2 +- webapp/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/webapp/package.json b/webapp/package.json index cbcb8dd1b..e70d2b038 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -46,7 +46,7 @@ "cross-env": "~5.2.0", "date-fns": "2.0.0-alpha.27", "express": "~4.16.4", - "graphql": "~14.2.1", + "graphql": "~14.3.0", "jsonwebtoken": "~8.5.1", "linkify-it": "~2.1.0", "nuxt": "~2.6.3", diff --git a/webapp/yarn.lock b/webapp/yarn.lock index d1aa462e7..f4db3be3e 100644 --- a/webapp/yarn.lock +++ b/webapp/yarn.lock @@ -5098,10 +5098,10 @@ graphql-upload@^8.0.2: http-errors "^1.7.1" object-path "^0.11.4" -graphql@^14.0.2, graphql@~14.2.1: - version "14.2.1" - resolved "https://registry.yarnpkg.com/graphql/-/graphql-14.2.1.tgz#779529bf9a01e7207b977a54c20670b48ca6e95c" - integrity sha512-2PL1UbvKeSjy/lUeJqHk+eR9CvuErXoCNwJI4jm3oNFEeY+9ELqHNKO1ZuSxAkasPkpWbmT/iMRMFxd3cEL3tQ== +graphql@^14.0.2, graphql@~14.3.0: + version "14.3.0" + resolved "https://registry.yarnpkg.com/graphql/-/graphql-14.3.0.tgz#34dd36faa489ff642bcd25df6c3b4f988a1a2f3e" + integrity sha512-MdfI4v7kSNC3NhB7cF8KNijDsifuWO2XOtzpyququqaclO8wVuChYv+KogexDwgP5sp7nFI9Z6N4QHgoLkfjrg== dependencies: iterall "^1.2.2" From cf9799fb18d562c5c48356306b69cce758beb595 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Wed, 8 May 2019 04:54:22 +0000 Subject: [PATCH 56/82] Bump apollo-server from 2.4.8 to 2.5.0 in /backend Bumps [apollo-server](https://github.com/apollographql/apollo-server) from 2.4.8 to 2.5.0. - [Release notes](https://github.com/apollographql/apollo-server/releases) - [Changelog](https://github.com/apollographql/apollo-server/blob/master/CHANGELOG.md) - [Commits](https://github.com/apollographql/apollo-server/compare/apollo-server@2.4.8...apollo-server@2.5.0) Signed-off-by: dependabot[bot] --- backend/package.json | 2 +- backend/yarn.lock | 147 +++++++++++++++++++++++++++++++++++++++---- 2 files changed, 137 insertions(+), 12 deletions(-) diff --git a/backend/package.json b/backend/package.json index 304e31176..b8202569f 100644 --- a/backend/package.json +++ b/backend/package.json @@ -38,7 +38,7 @@ "apollo-client": "~2.5.1", "apollo-link-context": "~1.0.14", "apollo-link-http": "~1.5.14", - "apollo-server": "~2.4.8", + "apollo-server": "~2.5.0", "bcryptjs": "~2.4.3", "cheerio": "~1.0.0-rc.3", "cors": "~2.8.5", diff --git a/backend/yarn.lock b/backend/yarn.lock index 2cdc7acf0..fd05bf36b 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -9,6 +9,13 @@ dependencies: apollo-env "0.3.3" +"@apollographql/apollo-tools@^0.3.6-alpha.1": + version "0.3.6-alpha.1" + resolved "https://registry.yarnpkg.com/@apollographql/apollo-tools/-/apollo-tools-0.3.6-alpha.1.tgz#5199b36c65c2fddc4f8bc8bb97642f74e9fb00c5" + integrity sha512-fq74In3Vw9OmtKHze0L5/Ns/pdTZOqUeFVC6Um9NRgziVehXz/qswsh2r3+dsn82uqoa/AlvckHtd6aPPPYj9g== + dependencies: + apollo-env "0.4.1-alpha.1" + "@apollographql/graphql-playground-html@^1.6.6": version "1.6.6" resolved "https://registry.yarnpkg.com/@apollographql/graphql-playground-html/-/graphql-playground-html-1.6.6.tgz#022209e28a2b547dcde15b219f0c50f47aa5beb3" @@ -1289,6 +1296,14 @@ apollo-cache-control@0.5.2: apollo-server-env "2.2.0" graphql-extensions "0.5.4" +apollo-cache-control@0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/apollo-cache-control/-/apollo-cache-control-0.6.0.tgz#df22db28f850ea90a5722f5e92654d30c96e7f91" + integrity sha512-66aCF6MHe0/FdD3knphwTv6CCIdb1ZxrMsiRpxP474qqyYVe2jAwBu6aJBn4emffZHZ7i6gp9dY6cPHThjnbKA== + dependencies: + apollo-server-env "2.3.0" + graphql-extensions "0.6.0" + apollo-cache-control@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/apollo-cache-control/-/apollo-cache-control-0.1.1.tgz#173d14ceb3eb9e7cb53de7eb8b61bee6159d4171" @@ -1338,6 +1353,14 @@ apollo-datasource@0.3.1: apollo-server-caching "0.3.1" apollo-server-env "2.2.0" +apollo-datasource@0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/apollo-datasource/-/apollo-datasource-0.4.0.tgz#f042641fd2593fa5f4f002fc30d1fb1a20284df8" + integrity sha512-6QkgnLYwQrW0qv+yXIf617DojJbGmza2XJXUlgnzrGGhxzfAynzEjaLyYkc8rYS1m82vjrl9EOmLHTcnVkvZAQ== + dependencies: + apollo-server-caching "0.4.0" + apollo-server-env "2.3.0" + apollo-engine-reporting-protobuf@0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/apollo-engine-reporting-protobuf/-/apollo-engine-reporting-protobuf-0.2.1.tgz#8547efcb4078a501ddf606cbfe01a2e8c3ba1afd" @@ -1345,6 +1368,13 @@ apollo-engine-reporting-protobuf@0.2.1: dependencies: protobufjs "^6.8.6" +apollo-engine-reporting-protobuf@0.3.0: + version "0.3.0" + resolved "https://registry.yarnpkg.com/apollo-engine-reporting-protobuf/-/apollo-engine-reporting-protobuf-0.3.0.tgz#2c764c054ff9968387cf16115546e0d5b04ee9f1" + integrity sha512-PYowpx/E+TJT/8nKpp3JmJuKh3x1SZcxDF6Cquj0soV205TUpFFCZQMi91i5ACiEp2AkYvM/GDBIrw+rfIwzTg== + dependencies: + protobufjs "^6.8.6" + apollo-engine-reporting@1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/apollo-engine-reporting/-/apollo-engine-reporting-1.0.7.tgz#d326b51b12b1f71a40885b8189dbcd162171c953" @@ -1357,6 +1387,18 @@ apollo-engine-reporting@1.0.7: async-retry "^1.2.1" graphql-extensions "0.5.7" +apollo-engine-reporting@1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/apollo-engine-reporting/-/apollo-engine-reporting-1.1.0.tgz#10def3d3bf3f11ddb24765c19d9c81e30cb9d55c" + integrity sha512-Dj0BwgcluHL0QVUaquhAoYoLX9Z4DRP/n2REcIwO8d2iy52r+1wN5QqZLx97dEFh7CjhNjTWeysJzc8XMWKa1Q== + dependencies: + apollo-engine-reporting-protobuf "0.3.0" + apollo-graphql "^0.2.1-alpha.1" + apollo-server-core "2.5.0" + apollo-server-env "2.3.0" + async-retry "^1.2.1" + graphql-extensions "0.6.0" + apollo-env@0.3.3: version "0.3.3" resolved "https://registry.yarnpkg.com/apollo-env/-/apollo-env-0.3.3.tgz#e758ece2fbc4f81abc6f07442680ed9e314ecf6c" @@ -1365,6 +1407,15 @@ apollo-env@0.3.3: core-js "3.0.0-beta.13" node-fetch "^2.2.0" +apollo-env@0.4.1-alpha.1: + version "0.4.1-alpha.1" + resolved "https://registry.yarnpkg.com/apollo-env/-/apollo-env-0.4.1-alpha.1.tgz#10d3ea508b8f3ba03939ef4e6ec4b2b5db77e8f1" + integrity sha512-4qWiaUKWh92jvKxxRsiZSjmW9YH9GWSG1W6X+S1BcC1uqtPiHsem7ExG9MMTt+UrzHsbpQLctj12xk8lI4lgCg== + dependencies: + core-js "3.0.0-beta.13" + node-fetch "^2.2.0" + sha.js "^2.4.11" + apollo-errors@^1.9.0: version "1.9.0" resolved "https://registry.yarnpkg.com/apollo-errors/-/apollo-errors-1.9.0.tgz#f1ed0ca0a6be5cd2f24e2eaa7b0860a10146ff51" @@ -1380,6 +1431,14 @@ apollo-graphql@^0.1.0: dependencies: lodash.sortby "^4.7.0" +apollo-graphql@^0.2.1-alpha.1: + version "0.2.1-alpha.1" + resolved "https://registry.yarnpkg.com/apollo-graphql/-/apollo-graphql-0.2.1-alpha.1.tgz#a0cc0bd65e03c7e887c96c9f53421f3c6dd7b599" + integrity sha512-kObCSpYRHEf4IozJV+TZAXEL2Yni2DpzQckohJNYXg5/KRAF20jJ7lHxuJz+kMQrc7QO4wYGSa29HuFZH2AtQA== + dependencies: + apollo-env "0.4.1-alpha.1" + lodash.sortby "^4.7.0" + apollo-link-context@~1.0.14: version "1.0.17" resolved "https://registry.yarnpkg.com/apollo-link-context/-/apollo-link-context-1.0.17.tgz#439272cfb43ec1891506dd175ed907845b7de36c" @@ -1430,6 +1489,13 @@ apollo-server-caching@0.3.1: dependencies: lru-cache "^5.0.0" +apollo-server-caching@0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/apollo-server-caching/-/apollo-server-caching-0.4.0.tgz#e82917590d723c0adc1fa52900e79e93ad65e4d9" + integrity sha512-GTOZdbLhrSOKYNWMYgaqX5cVNSMT0bGUTZKV8/tYlyYmsB6ey7l6iId3Q7UpHS6F6OR2lstz5XaKZ+T3fDfPzQ== + dependencies: + lru-cache "^5.0.0" + apollo-server-core@2.4.8: version "2.4.8" resolved "https://registry.yarnpkg.com/apollo-server-core/-/apollo-server-core-2.4.8.tgz#47e503a345e314222725597c889773e018d8c67a" @@ -1456,6 +1522,32 @@ apollo-server-core@2.4.8: subscriptions-transport-ws "^0.9.11" ws "^6.0.0" +apollo-server-core@2.5.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/apollo-server-core/-/apollo-server-core-2.5.0.tgz#89fc28ba1018ebf9240bc3cc0c103fe705309023" + integrity sha512-7hyQ/Rt0hC38bUfxMQmLNHDBIGEBykFWo9EO0W+3o/cno/SqBKd1KKichrABVv+v+SCvZAUutX6gYS5l3G+ULQ== + dependencies: + "@apollographql/apollo-tools" "^0.3.6-alpha.1" + "@apollographql/graphql-playground-html" "^1.6.6" + "@types/ws" "^6.0.0" + apollo-cache-control "0.6.0" + apollo-datasource "0.4.0" + apollo-engine-reporting "1.1.0" + apollo-server-caching "0.4.0" + apollo-server-env "2.3.0" + apollo-server-errors "2.3.0" + apollo-server-plugin-base "0.4.0" + apollo-tracing "0.6.0" + fast-json-stable-stringify "^2.0.0" + graphql-extensions "0.6.0" + graphql-subscriptions "^1.0.0" + graphql-tag "^2.9.2" + graphql-tools "^4.0.0" + graphql-upload "^8.0.2" + sha.js "^2.4.11" + subscriptions-transport-ws "^0.9.11" + ws "^6.0.0" + apollo-server-core@^1.3.6, apollo-server-core@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/apollo-server-core/-/apollo-server-core-1.4.0.tgz#4faff7f110bfdd6c3f47008302ae24140f94c592" @@ -1473,15 +1565,28 @@ apollo-server-env@2.2.0: node-fetch "^2.1.2" util.promisify "^1.0.0" +apollo-server-env@2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/apollo-server-env/-/apollo-server-env-2.3.0.tgz#f0bf4484a6cc331a8c13763ded56e91beb16ba17" + integrity sha512-WIwlkCM/gir0CkoYWPMTCH8uGCCKB/aM074U1bKayvkFOBVO2VgG5x2kgsfkyF05IMQq2/GOTsKhNY7RnUEhTA== + dependencies: + node-fetch "^2.1.2" + util.promisify "^1.0.0" + apollo-server-errors@2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/apollo-server-errors/-/apollo-server-errors-2.2.1.tgz#f68a3f845929768057da7e1c6d30517db5872205" integrity sha512-wY/YE3iJVMYC+WYIf8QODBjIP4jhI+oc7kiYo9mrz7LdYPKAgxr/he+NteGcqn/0Ea9K5/ZFTGJDbEstSMeP8g== -apollo-server-express@2.4.8: - version "2.4.8" - resolved "https://registry.yarnpkg.com/apollo-server-express/-/apollo-server-express-2.4.8.tgz#ec9eb61a87324555d49097e9fade3c7d142eb6cb" - integrity sha512-i60l32mfVe33jnKDPNYgUKUKu4Al0xEm2HLOSMgtJ9Wbpe/MbOx5X8M5F27fnHYdM+G5XfAErsakAyRGnQJ48Q== +apollo-server-errors@2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/apollo-server-errors/-/apollo-server-errors-2.3.0.tgz#700622b66a16dffcad3b017e4796749814edc061" + integrity sha512-rUvzwMo2ZQgzzPh2kcJyfbRSfVKRMhfIlhY7BzUfM4x6ZT0aijlgsf714Ll3Mbf5Fxii32kD0A/DmKsTecpccw== + +apollo-server-express@2.5.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/apollo-server-express/-/apollo-server-express-2.5.0.tgz#ff6cbd3fcb8933f6316c5a5edd4db12d9a56fa65" + integrity sha512-2gd3VWIqji2jyDYMTTqKzVU4/znjEjugtLUmPgVl5SoBvJSMTsO7VgJv+roBubZGDK8jXXUEXr2a33RtIeHe4g== dependencies: "@apollographql/graphql-playground-html" "^1.6.6" "@types/accepts" "^1.3.5" @@ -1489,7 +1594,7 @@ apollo-server-express@2.4.8: "@types/cors" "^2.8.4" "@types/express" "4.16.1" accepts "^1.3.5" - apollo-server-core "2.4.8" + apollo-server-core "2.5.0" body-parser "^1.18.3" cors "^2.8.4" graphql-subscriptions "^1.0.0" @@ -1522,6 +1627,11 @@ apollo-server-plugin-base@0.3.7: resolved "https://registry.yarnpkg.com/apollo-server-plugin-base/-/apollo-server-plugin-base-0.3.7.tgz#bfa4932fc9481bb36221545578d311db464af5a6" integrity sha512-hW1jaLKf9qNOxMTwRq2CSqz3eqXsZuEiCc8/mmEtOciiVBq1GMtxFf19oIYM9HQuPvQU2RWpns1VrYN59L3vbg== +apollo-server-plugin-base@0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/apollo-server-plugin-base/-/apollo-server-plugin-base-0.4.0.tgz#38a3c37767043873dd1b07143d4e70eecbb09562" + integrity sha512-iD7ARNtwnvHGd1EMPK0CuodM8d8hgDvFwTfIDzJY04QIQ6/KrBFaWhnCXJsy+HMb47GovwBbq67IK6eb2WJgBg== + apollo-server-testing@~2.4.8: version "2.4.8" resolved "https://registry.yarnpkg.com/apollo-server-testing/-/apollo-server-testing-2.4.8.tgz#eb929a431e059723c298919688355434d53e3ea8" @@ -1529,13 +1639,13 @@ apollo-server-testing@~2.4.8: dependencies: apollo-server-core "2.4.8" -apollo-server@~2.4.8: - version "2.4.8" - resolved "https://registry.yarnpkg.com/apollo-server/-/apollo-server-2.4.8.tgz#b18ec24e6356dd2a191a6fa0f1429b07ef7c89e3" - integrity sha512-IU6RekO2dqrDdC+5hU6aeVvGg/2t/f01inBMjDhAn1a7hoITUXEh8Sa57TgmYEZ5uAtDuWW7cdiZN2j0cMI3/w== +apollo-server@~2.5.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/apollo-server/-/apollo-server-2.5.0.tgz#a88a550dbc5ff0c6713142d1cab3b61b4a36e483" + integrity sha512-85A3iAnXVP5QiXc0xvAJRyGsoxov06+8AzttKqehR4Q50UC1Is62xY5WZk58oW7fm+awpqh+sXB2F2E6tObSmg== dependencies: - apollo-server-core "2.4.8" - apollo-server-express "2.4.8" + apollo-server-core "2.5.0" + apollo-server-express "2.5.0" express "^4.0.0" graphql-subscriptions "^1.0.0" graphql-tools "^4.0.0" @@ -1548,6 +1658,14 @@ apollo-tracing@0.5.2: apollo-server-env "2.2.0" graphql-extensions "0.5.4" +apollo-tracing@0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/apollo-tracing/-/apollo-tracing-0.6.0.tgz#afc2b9cbea173dc4c315a5d98053797469518083" + integrity sha512-OpYPHVBgcQ/HT2WLXJQWwhilzR1rrl01tZeMU2N7yinsp/oyKngF5aUSMtuvX1k/T3abilQo+w10oAQlBCGdPA== + dependencies: + apollo-server-env "2.3.0" + graphql-extensions "0.6.0" + apollo-tracing@^0.1.0: version "0.1.4" resolved "https://registry.yarnpkg.com/apollo-tracing/-/apollo-tracing-0.1.4.tgz#5b8ae1b01526b160ee6e552a7f131923a9aedcc7" @@ -3693,6 +3811,13 @@ graphql-extensions@0.5.7: dependencies: "@apollographql/apollo-tools" "^0.3.3" +graphql-extensions@0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/graphql-extensions/-/graphql-extensions-0.6.0.tgz#3ee3aa57fe213f90aec5cd31275f6d04767c6a23" + integrity sha512-SshzmbD68fHXRv2q3St29olMOxHDLQ5e9TOh+Tz2BYxinrfhjFaPNcEefiK/vF295wW827Y58bdO11Xmhf8J+Q== + dependencies: + "@apollographql/apollo-tools" "^0.3.6-alpha.1" + graphql-extensions@^0.0.x, graphql-extensions@~0.0.9: version "0.0.10" resolved "https://registry.yarnpkg.com/graphql-extensions/-/graphql-extensions-0.0.10.tgz#34bdb2546d43f6a5bc89ab23c295ec0466c6843d" From 88dc38de8ff7abf2a27067afaff05a963259dc38 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 13:50:49 +0200 Subject: [PATCH 57/82] added .codecov.yaml --- .codecov.yml | 163 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 163 insertions(+) create mode 100644 .codecov.yml diff --git a/.codecov.yml b/.codecov.yml new file mode 100644 index 000000000..e5086996a --- /dev/null +++ b/.codecov.yml @@ -0,0 +1,163 @@ +codecov: + #token: uuid # Your private repository token + #url: "http" # for Codecov Enterprise customers + #slug: "owner/repo" # for Codecov Enterprise customers + branch: master # override the default branch + #bot: username # set user whom will be the consumer of oauth requests + #ci: # Custom CI domains if Codecov does not identify them automatically + # - ci.domain.com + # - !provider # ignore these providers when checking if CI passed + # # ex. You may test on Travis, Circle, and AppVeyor, but only need + # # to check if Travis passes. Therefore add: !circle and !appveyor + notify: + after_n_builds: null # number of expected builds to recieve before sending notifications + # after: check ci status unless disabled via require_ci_to_pass + require_ci_to_pass: yes # yes: will delay sending notifications until all ci is finished + # no: will send notifications without checking ci status and wait till "after_n_builds" are uploaded + countdown: null # number of seconds to wait before first ci build check + delay: null # number of seconds to wait between ci build checks + +coverage: + precision: 2 # 2 = xx.xx%, 0 = xx% + round: nearest # down|up|nearest - default down + # range: 50...60 # default 70...90. red...green + + #notify: + # irc: + # default: + # server: "chat.freenode.net"|encrypted + # branches: null # all branches by default + # threshold: 1% + # message: "Coverage {{changed}} for {{owner}}/{{repo}}" # customize the message + # flags: null + # paths: null + # + # slack: + # default: + # url: "http"|encrypted + # threshold: 1% + # branches: null # all branches by default + # message: "Coverage {{changed}} for {{owner}}/{{repo}}" # customize the message + # attachments: "sunburst, diff" + # only_pulls: false + # flags: null + # paths: null + # + # email: + # default: + # to: + # - example@domain.com + # - &author + # threshold: 1% + # only_pulls: false + # layout: header, diff, trends + # flags: null + # paths: null + # + # hipchat: + # default: + # url: "http"|encrypted + # room: name|id + # threshold: 1% + # token: encrypted + # branches: null # all branches by default + # notify: false # if the hipchat message is silent or loud (default false) + # message: "Coverage {{changed}} for {{owner}}/{{repo}}" # customize the message + # flags: null + # paths: null + # + # gitter: + # url: "http"|encrypted + # threshold: 1% + # branches: null # all branches by default + # message: "Coverage {{changed}} for {{owner}}/{{repo}}" # customize the message + # + # webhooks: + # _name_: + # url: "http"|encrypted + # threshold: 1% + # branches: null # all branches by default + + status: + project: + default: false # disable the default status that measures entire project + backend: # declare a new status context "backend" + against: parent + target: auto + threshold: null + #threshold: 1% + base: auto + if_no_uploads: error + if_not_found: success + if_ci_failed: error + only_pulls: false + #branches: + # - master + #flags: + # - integration + paths: + - backend/ # only include coverage in "backend/" folder + webapp: # declare a new status context "frontend" + against: parent + target: auto + threshold: null + #threshold: 1% + base: auto + if_no_uploads: error + if_not_found: success + if_ci_failed: error + only_pulls: false + #branches: + # - master + #flags: + # - integration + paths: + - webapp/ # only include coverage in "webapp/" folder + + #patch: + # default: + # against: parent + # target: 80% + # branches: null + # if_no_uploads: success + # if_not_found: success + # if_ci_failed: error + # only_pulls: false + # flags: + # - integration + # paths: + # - folder + + #changes: + # default: + # against: parent + # branches: null + # if_no_uploads: error + # if_not_found: success + # if_ci_failed: error + # only_pulls: false + # flags: + # - integration + # paths: + # - folder + + #flags: + # integration: + # branches: + # - master + # ignore: + # - app/ui + + #ignore: # files and folders for processing + # - tests/* + + #fixes: + # - "old_path::new_path" + +comment: + layout: header, diff, trends, uncovered + branches: * + behavior: default # default = posts once then update, posts new if delete + # once = post once then updates + # new = delete old, post new + # spammy = post new \ No newline at end of file From e2d2236c1a4777a6a81b82ed270ddba5ea7fd072 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 14:08:20 +0200 Subject: [PATCH 58/82] add volumes to docker-compose.travis.yml, modified .travis.yml for codecov upload --- .travis.yml | 7 +++++++ docker-compose.travis.yml | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/.travis.yml b/.travis.yml index 632786285..4d9a4c733 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,6 +10,8 @@ addons: before_install: - yarn global add wait-on + # Install Codecov + - yarn global add codecov - yarn install - cp cypress.env.template.json cypress.env.json @@ -18,6 +20,7 @@ install: - wait-on http://localhost:7474 && docker-compose exec neo4j migrate script: + # Backend - docker-compose exec backend yarn run lint - docker-compose exec backend yarn run test:jest --ci --verbose=false - docker-compose exec backend yarn run db:reset @@ -25,10 +28,14 @@ script: - docker-compose exec backend yarn run test:cucumber - docker-compose exec backend yarn run db:reset - docker-compose exec backend yarn run db:seed + # Frontend - docker-compose exec webapp yarn run lint - docker-compose exec webapp yarn run test --ci --verbose=false - docker-compose exec -d backend yarn run test:before:seeder + # Fullstack - CYPRESS_RETRIES=1 yarn run cypress:run + # Coverage + - codecov after_success: - wget https://raw.githubusercontent.com/DiscordHooks/travis-ci-discord-webhook/master/send.sh diff --git a/docker-compose.travis.yml b/docker-compose.travis.yml index 8af3226e7..a677d7b46 100644 --- a/docker-compose.travis.yml +++ b/docker-compose.travis.yml @@ -11,6 +11,8 @@ services: build: context: webapp target: build-and-test + volumes: + - coverage:webapp/coverage environment: - GRAPHQL_URI=http://backend:4000 backend: @@ -18,6 +20,8 @@ services: build: context: backend target: builder + volumes: + - coverage:backend/coverage ports: - 4001:4001 - 4123:4123 From 7d215739bb8df2072410b99d46d76b17c855b058 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 14:14:21 +0200 Subject: [PATCH 59/82] corrected docker volumes paths --- docker-compose.travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.travis.yml b/docker-compose.travis.yml index a677d7b46..81828daa1 100644 --- a/docker-compose.travis.yml +++ b/docker-compose.travis.yml @@ -12,7 +12,7 @@ services: context: webapp target: build-and-test volumes: - - coverage:webapp/coverage + - ./coverage:./webapp/coverage environment: - GRAPHQL_URI=http://backend:4000 backend: @@ -21,7 +21,7 @@ services: context: backend target: builder volumes: - - coverage:backend/coverage + - ./coverage:./backend/coverage ports: - 4001:4001 - 4123:4123 From ff303fccd3e644f6ddead9558a32bf7fe031f3f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Wed, 8 May 2019 14:14:34 +0200 Subject: [PATCH 60/82] Fixed linting errors --- webapp/pages/settings/my-social-media.vue | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/webapp/pages/settings/my-social-media.vue b/webapp/pages/settings/my-social-media.vue index d0d805730..462e9af96 100644 --- a/webapp/pages/settings/my-social-media.vue +++ b/webapp/pages/settings/my-social-media.vue @@ -31,7 +31,7 @@ name="delete" @click="handleDeleteSocialMedia(link)" > - + @@ -116,7 +116,7 @@ export default { }) .then(() => { this.$toast.success(this.$t('settings.social-media.successAdd')), - (this.value = '') + (this.value = '') }) .catch(error => { this.$toast.error(error.message) @@ -137,7 +137,9 @@ export default { id: link.id }, update: (store, { data }) => { - const socialMedia = this.currentUser.socialMedia.filter(element => element.id !== link.id ) + const socialMedia = this.currentUser.socialMedia.filter( + element => element.id !== link.id + ) this.setCurrentUser({ ...this.currentUser, socialMedia From 3545f1240e960092c20e9c1c5e7646faa3e8892d Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 14:30:21 +0200 Subject: [PATCH 61/82] another try with relative paths --- docker-compose.travis.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docker-compose.travis.yml b/docker-compose.travis.yml index 81828daa1..7553bb939 100644 --- a/docker-compose.travis.yml +++ b/docker-compose.travis.yml @@ -12,7 +12,8 @@ services: context: webapp target: build-and-test volumes: - - ./coverage:./webapp/coverage + #/nitro-web + - ./webapp/coverage:./coverage environment: - GRAPHQL_URI=http://backend:4000 backend: @@ -21,7 +22,7 @@ services: context: backend target: builder volumes: - - ./coverage:./backend/coverage + - ./backend/coverage:./coverage ports: - 4001:4001 - 4123:4123 From ddb33da045e4f9f8f4d9d3e4a0524ada3d8abe8d Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 14:42:25 +0200 Subject: [PATCH 62/82] absolute paths --- docker-compose.travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose.travis.yml b/docker-compose.travis.yml index 7553bb939..bc627a67a 100644 --- a/docker-compose.travis.yml +++ b/docker-compose.travis.yml @@ -13,7 +13,7 @@ services: target: build-and-test volumes: #/nitro-web - - ./webapp/coverage:./coverage + - ./webapp/coverage:/nitro-web/coverage environment: - GRAPHQL_URI=http://backend:4000 backend: @@ -22,7 +22,7 @@ services: context: backend target: builder volumes: - - ./backend/coverage:./coverage + - ./backend/coverage:/nitro-backend/coverage ports: - 4001:4001 - 4123:4123 From 6aa4426c420a24ca2d585aecd9f6cf4b019f77d2 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 15:46:19 +0200 Subject: [PATCH 63/82] adjusted .codecov.yml a bit - hopefully we get better results --- .codecov.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.codecov.yml b/.codecov.yml index e5086996a..1c8366328 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -2,7 +2,7 @@ codecov: #token: uuid # Your private repository token #url: "http" # for Codecov Enterprise customers #slug: "owner/repo" # for Codecov Enterprise customers - branch: master # override the default branch + #branch: master # override the default branch #bot: username # set user whom will be the consumer of oauth requests #ci: # Custom CI domains if Codecov does not identify them automatically # - ci.domain.com @@ -10,12 +10,12 @@ codecov: # # ex. You may test on Travis, Circle, and AppVeyor, but only need # # to check if Travis passes. Therefore add: !circle and !appveyor notify: - after_n_builds: null # number of expected builds to recieve before sending notifications - # after: check ci status unless disabled via require_ci_to_pass + #after_n_builds: null # number of expected builds to recieve before sending notifications + # # after: check ci status unless disabled via require_ci_to_pass require_ci_to_pass: yes # yes: will delay sending notifications until all ci is finished # no: will send notifications without checking ci status and wait till "after_n_builds" are uploaded - countdown: null # number of seconds to wait before first ci build check - delay: null # number of seconds to wait between ci build checks + #countdown: null # number of seconds to wait before first ci build check + #delay: null # number of seconds to wait between ci build checks coverage: precision: 2 # 2 = xx.xx%, 0 = xx% From dc2f3642713c6751a727996a2244601e779a6e33 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 15:54:18 +0200 Subject: [PATCH 64/82] always post new coverage data, this way it will be always at the bottom --- .codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.codecov.yml b/.codecov.yml index 1c8366328..17e7cc2ce 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -157,7 +157,7 @@ coverage: comment: layout: header, diff, trends, uncovered branches: * - behavior: default # default = posts once then update, posts new if delete + behavior: new # default = posts once then update, posts new if delete # once = post once then updates # new = delete old, post new # spammy = post new \ No newline at end of file From c4a4d3d1f02ec42a629b5a2558e68f4ce2961fdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Wed, 8 May 2019 16:04:09 +0200 Subject: [PATCH 65/82] Wrote an additional frontend unit test MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Skipped writing of a modal dialog before deletion, because many code parts are on the way in the delete post PR. So makes no sense to write them twice. I make a new issue … --- cypress/integration/common/settings.js | 5 ---- .../user_profile/SocialMedia.feature | 1 - webapp/pages/settings/my-social-media.spec.js | 30 ++++++++++++++++++- 3 files changed, 29 insertions(+), 7 deletions(-) diff --git a/cypress/integration/common/settings.js b/cypress/integration/common/settings.js index fa2962dfb..b6621ec87 100644 --- a/cypress/integration/common/settings.js +++ b/cypress/integration/common/settings.js @@ -116,11 +116,6 @@ When('I delete a social media link', () => { .click() }) -// Then('Shows delete modal', () => { -// cy.get("a[name='delete']") -// .click() -// }) - Then('it gets deleted successfully', () => { cy.get('.iziToast-message') .should('contain', 'Deleted social media') diff --git a/cypress/integration/user_profile/SocialMedia.feature b/cypress/integration/user_profile/SocialMedia.feature index 4466b9537..d21167c6b 100644 --- a/cypress/integration/user_profile/SocialMedia.feature +++ b/cypress/integration/user_profile/SocialMedia.feature @@ -27,4 +27,3 @@ Feature: List Social Media Accounts Given I have added a social media link When I delete a social media link Then it gets deleted successfully - # And the new social media link shows up on the page diff --git a/webapp/pages/settings/my-social-media.spec.js b/webapp/pages/settings/my-social-media.spec.js index 673c1cd70..559ba87d2 100644 --- a/webapp/pages/settings/my-social-media.spec.js +++ b/webapp/pages/settings/my-social-media.spec.js @@ -72,10 +72,38 @@ describe('my-social-media.vue', () => { expect(socialMediaLink).toBe(socialMediaUrl) }) - it('displays a trash sympol after a social media', () => { + beforeEach(() => { + mocks = { + $t: jest.fn(), + $apollo: { + mutate: jest + .fn() + .mockRejectedValue({ message: 'Ouch!' }) + .mockResolvedValueOnce({ + data: { DeleteSocialMeda: { id: 's1', url: socialMediaUrl } } + }) + }, + $toast: { + error: jest.fn(), + success: jest.fn() + } + } + getters = { + 'auth/user': () => { + return { + socialMedia: [{ id: 's1', url: socialMediaUrl }] + } + } + } + }) + + it('displays a trash sympol after a social media and allows the user to delete it', () => { wrapper = Wrapper() const deleteSelector = wrapper.find({ name: 'delete' }) expect(deleteSelector).toEqual({ selector: 'Component' }) + const icon = wrapper.find({ name: 'trash' }) + icon.trigger('click') + expect(mocks.$apollo.mutate).toHaveBeenCalledTimes(1) }) }) From b92bdc8d294aa6cf33b71751faf5ba321e7c0fcc Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 16:21:45 +0200 Subject: [PATCH 66/82] more comment options --- .codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.codecov.yml b/.codecov.yml index 17e7cc2ce..827970de1 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -155,7 +155,7 @@ coverage: # - "old_path::new_path" comment: - layout: header, diff, trends, uncovered + layout: header, diff, trends, uncovered, reach, files, tree, changes, sunburst branches: * behavior: new # default = posts once then update, posts new if delete # once = post once then updates From f63ed9d8baac9fb064d2ee17409fa14a009921df Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 16:27:31 +0200 Subject: [PATCH 67/82] even more options --- .codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.codecov.yml b/.codecov.yml index 827970de1..acb9a1406 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -155,7 +155,7 @@ coverage: # - "old_path::new_path" comment: - layout: header, diff, trends, uncovered, reach, files, tree, changes, sunburst + layout: header, diff, trends, uncovered, reach, files, tree, changes, sunburst, flags branches: * behavior: new # default = posts once then update, posts new if delete # once = post once then updates From c9f90058ed36f442a0e95989c61fdb1a86727a3a Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 17:25:05 +0200 Subject: [PATCH 68/82] just a commit to start another test PR --- .codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.codecov.yml b/.codecov.yml index acb9a1406..79ce649fc 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -155,7 +155,7 @@ coverage: # - "old_path::new_path" comment: - layout: header, diff, trends, uncovered, reach, files, tree, changes, sunburst, flags + layout: header, diff, trends, uncovered, reach, files, tree, changes, sunburst, flags # branches: * behavior: new # default = posts once then update, posts new if delete # once = post once then updates From d9575d6b482edc7333c241589fa0009864e50679 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 17:52:28 +0200 Subject: [PATCH 69/82] fixed .codecov.yml --- .codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.codecov.yml b/.codecov.yml index 79ce649fc..1125131af 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -155,7 +155,7 @@ coverage: # - "old_path::new_path" comment: - layout: header, diff, trends, uncovered, reach, files, tree, changes, sunburst, flags # + layout: files, diff, reach, flags branches: * behavior: new # default = posts once then update, posts new if delete # once = post once then updates From ec72bdd9bd0c27b9e96a620c4e4b0e2189bdd578 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 17:59:29 +0200 Subject: [PATCH 70/82] included all known and valid options --- .codecov.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.codecov.yml b/.codecov.yml index 1125131af..71d68f750 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -155,9 +155,9 @@ coverage: # - "old_path::new_path" comment: - layout: files, diff, reach, flags + layout: header, diff, uncovered, reach, files, tree, changes, sunburst, flags branches: * behavior: new # default = posts once then update, posts new if delete - # once = post once then updates - # new = delete old, post new - # spammy = post new \ No newline at end of file + # once = post once then updates + # new = delete old, post new + # spammy = post new \ No newline at end of file From af9469908e90859d9cbc2653288085b3aad38ff4 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 18:52:01 +0200 Subject: [PATCH 71/82] removed patch status?! --- .codecov.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.codecov.yml b/.codecov.yml index 71d68f750..254150776 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -114,8 +114,8 @@ coverage: paths: - webapp/ # only include coverage in "webapp/" folder - #patch: - # default: + patch: + default: false # against: parent # target: 80% # branches: null From 12ec2b8683d905f213176aa73aca21752403ff37 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 19:13:09 +0200 Subject: [PATCH 72/82] fixed codecov report layout, disabled tests in front- & backend for testing - should fail --- .codecov.yml | 12 +++++++++--- ...leware.spec.js => fixImageUrlsMiddleware.speX.js} | 0 .../Category/{index.spec.js => index.speX.js} | 0 3 files changed, 9 insertions(+), 3 deletions(-) rename backend/src/middleware/{fixImageUrlsMiddleware.spec.js => fixImageUrlsMiddleware.speX.js} (100%) rename webapp/components/Category/{index.spec.js => index.speX.js} (100%) diff --git a/.codecov.yml b/.codecov.yml index 254150776..2767ed675 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -155,9 +155,15 @@ coverage: # - "old_path::new_path" comment: - layout: header, diff, uncovered, reach, files, tree, changes, sunburst, flags - branches: * + # layout options are quite limited in v4.x - there have been way more options in v1.0 + layout: reach, diff, flags, files # mostly old options: header, diff, uncovered, reach, files, tree, changes, sunburst, flags behavior: new # default = posts once then update, posts new if delete # once = post once then updates # new = delete old, post new - # spammy = post new \ No newline at end of file + # spammy = post new + require_changes: false # if true: only post the comment if coverage changes + require_base: no # [yes :: must have a base report to post] + require_head: no # [yes :: must have a head report to post] + branches: null # branch names that can post comment + flags: null + paths: null \ No newline at end of file diff --git a/backend/src/middleware/fixImageUrlsMiddleware.spec.js b/backend/src/middleware/fixImageUrlsMiddleware.speX.js similarity index 100% rename from backend/src/middleware/fixImageUrlsMiddleware.spec.js rename to backend/src/middleware/fixImageUrlsMiddleware.speX.js diff --git a/webapp/components/Category/index.spec.js b/webapp/components/Category/index.speX.js similarity index 100% rename from webapp/components/Category/index.spec.js rename to webapp/components/Category/index.speX.js From 4092a8873b4c20fb1fec48e34b2e0d6f0319913f Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 19:38:01 +0200 Subject: [PATCH 73/82] overall coverage seems not to be reported..., removed parts of tests not the whole thing --- ...leware.speX.js => fixImageUrlsMiddleware.spec.js} | 0 backend/src/middleware/permissionsMiddleware.spec.js | 8 ++++---- .../Category/{index.speX.js => index.spes.js} | 0 webapp/components/Comment.spec.js | 12 ++++++------ 4 files changed, 10 insertions(+), 10 deletions(-) rename backend/src/middleware/{fixImageUrlsMiddleware.speX.js => fixImageUrlsMiddleware.spec.js} (100%) rename webapp/components/Category/{index.speX.js => index.spes.js} (100%) diff --git a/backend/src/middleware/fixImageUrlsMiddleware.speX.js b/backend/src/middleware/fixImageUrlsMiddleware.spec.js similarity index 100% rename from backend/src/middleware/fixImageUrlsMiddleware.speX.js rename to backend/src/middleware/fixImageUrlsMiddleware.spec.js diff --git a/backend/src/middleware/permissionsMiddleware.spec.js b/backend/src/middleware/permissionsMiddleware.spec.js index 89904a7bf..11401c7e0 100644 --- a/backend/src/middleware/permissionsMiddleware.spec.js +++ b/backend/src/middleware/permissionsMiddleware.spec.js @@ -34,7 +34,7 @@ describe('authorization', () => { return graphQLClient.request('{User(name: "Owner") { email } }') } - describe('not logged in', () => { + /* describe('not logged in', () => { it('rejects', async () => { await expect(action()).rejects.toThrow('Not Authorised!') }) @@ -46,9 +46,9 @@ describe('authorization', () => { expect(error.response.data).toEqual({ User: [ { email: null } ] }) } }) - }) + }) */ - describe('as owner', () => { + /* describe('as owner', () => { beforeEach(() => { loginCredentials = { email: 'owner@example.org', @@ -59,7 +59,7 @@ describe('authorization', () => { it('exposes the owner\'s email address', async () => { await expect(action()).resolves.toEqual({ User: [ { email: 'owner@example.org' } ] }) }) - }) + }) */ describe('authenticated as another user', () => { beforeEach(async () => { diff --git a/webapp/components/Category/index.speX.js b/webapp/components/Category/index.spes.js similarity index 100% rename from webapp/components/Category/index.speX.js rename to webapp/components/Category/index.spes.js diff --git a/webapp/components/Comment.spec.js b/webapp/components/Comment.spec.js index 83a738956..3226802bf 100644 --- a/webapp/components/Comment.spec.js +++ b/webapp/components/Comment.spec.js @@ -47,32 +47,32 @@ describe('Comment.vue', () => { } }) - it('renders content', () => { + /*it('renders content', () => { const wrapper = Wrapper() expect(wrapper.text()).toMatch('Hello I am a comment content') - }) + })*/ describe('which is disabled', () => { beforeEach(() => { propsData.comment.disabled = true }) - it('renders no comment data', () => { + /*it('renders no comment data', () => { const wrapper = Wrapper() expect(wrapper.text()).not.toMatch('comment content') - }) + })*/ it('has no "disabled-content" css class', () => { const wrapper = Wrapper() expect(wrapper.classes()).not.toContain('disabled-content') }) - it('translates a placeholder', () => { + /*it('translates a placeholder', () => { const wrapper = Wrapper() const calls = mocks.$t.mock.calls const expected = [['comment.content.unavailable-placeholder']] expect(calls).toEqual(expect.arrayContaining(expected)) - }) + })*/ describe('for a moderator', () => { beforeEach(() => { From ec9b3607d8ea8fa003fd06fbbb4e3ffce2d1951b Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 19:52:04 +0200 Subject: [PATCH 74/82] compute coverage over all code --- backend/package.json | 12 ++++++++++-- webapp/package.json | 19 ++++++++++++++----- 2 files changed, 24 insertions(+), 7 deletions(-) diff --git a/backend/package.json b/backend/package.json index 304e31176..9c9ccba54 100644 --- a/backend/package.json +++ b/backend/package.json @@ -27,7 +27,15 @@ "jest": { "verbose": true, "collectCoverage": true, - "coverageReporters": ["text", "lcov"], + "collectCoverageFrom": [ + "**/*.{js}", + "!**/node_modules/**", + "!**/test/**" + ], + "coverageReporters": [ + "text", + "lcov" + ], "testMatch": [ "**/src/**/?(*.)+(spec|test).js?(x)" ] @@ -96,4 +104,4 @@ "nodemon": "~1.19.0", "supertest": "~4.0.2" } -} +} \ No newline at end of file diff --git a/webapp/package.json b/webapp/package.json index cbcb8dd1b..23f541cf6 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -18,11 +18,17 @@ "jest": { "verbose": true, "collectCoverage": true, - "coverageReporters": ["text", "lcov"], + "collectCoverageFrom": [ + "**/*.{js,vue}", + "!**/node_modules/**", + "!**/.nuxt/**" + ], + "coverageReporters": [ + "text", + "lcov" + ], "moduleFileExtensions": [ "js", - "json", - "vue" ], "transform": { ".*\\.(vue)$": "vue-jest", @@ -31,7 +37,10 @@ "moduleNameMapper": { "^@/(.*)$": "/src/$1", "^~/(.*)$": "/$1" - } + }, + "testMatch": [ + "**/src/**/?(*.)+(spec|test).js?(x)" + ] }, "dependencies": { "@human-connection/styleguide": "0.5.15", @@ -86,4 +95,4 @@ "vue-jest": "~3.0.4", "vue-svg-loader": "~0.12.0" } -} +} \ No newline at end of file From 3ca04a5c1e830815698ad772b208f6e1bb667513 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 20:02:52 +0200 Subject: [PATCH 75/82] typo --- webapp/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webapp/package.json b/webapp/package.json index 23f541cf6..900adfc72 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -28,7 +28,7 @@ "lcov" ], "moduleFileExtensions": [ - "js", + "js" ], "transform": { ".*\\.(vue)$": "vue-jest", From 900dfb9693185ef509dc6e791fc662fdddd76699 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 20:04:55 +0200 Subject: [PATCH 76/82] renabled tests - it seems like the reports do not work very well --- backend/src/middleware/permissionsMiddleware.spec.js | 8 ++++---- webapp/components/Comment.spec.js | 12 ++++++------ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/backend/src/middleware/permissionsMiddleware.spec.js b/backend/src/middleware/permissionsMiddleware.spec.js index 11401c7e0..89904a7bf 100644 --- a/backend/src/middleware/permissionsMiddleware.spec.js +++ b/backend/src/middleware/permissionsMiddleware.spec.js @@ -34,7 +34,7 @@ describe('authorization', () => { return graphQLClient.request('{User(name: "Owner") { email } }') } - /* describe('not logged in', () => { + describe('not logged in', () => { it('rejects', async () => { await expect(action()).rejects.toThrow('Not Authorised!') }) @@ -46,9 +46,9 @@ describe('authorization', () => { expect(error.response.data).toEqual({ User: [ { email: null } ] }) } }) - }) */ + }) - /* describe('as owner', () => { + describe('as owner', () => { beforeEach(() => { loginCredentials = { email: 'owner@example.org', @@ -59,7 +59,7 @@ describe('authorization', () => { it('exposes the owner\'s email address', async () => { await expect(action()).resolves.toEqual({ User: [ { email: 'owner@example.org' } ] }) }) - }) */ + }) describe('authenticated as another user', () => { beforeEach(async () => { diff --git a/webapp/components/Comment.spec.js b/webapp/components/Comment.spec.js index 3226802bf..83a738956 100644 --- a/webapp/components/Comment.spec.js +++ b/webapp/components/Comment.spec.js @@ -47,32 +47,32 @@ describe('Comment.vue', () => { } }) - /*it('renders content', () => { + it('renders content', () => { const wrapper = Wrapper() expect(wrapper.text()).toMatch('Hello I am a comment content') - })*/ + }) describe('which is disabled', () => { beforeEach(() => { propsData.comment.disabled = true }) - /*it('renders no comment data', () => { + it('renders no comment data', () => { const wrapper = Wrapper() expect(wrapper.text()).not.toMatch('comment content') - })*/ + }) it('has no "disabled-content" css class', () => { const wrapper = Wrapper() expect(wrapper.classes()).not.toContain('disabled-content') }) - /*it('translates a placeholder', () => { + it('translates a placeholder', () => { const wrapper = Wrapper() const calls = mocks.$t.mock.calls const expected = [['comment.content.unavailable-placeholder']] expect(calls).toEqual(expect.arrayContaining(expected)) - })*/ + }) describe('for a moderator', () => { beforeEach(() => { From 28c44f27811a14df18167e4671999ba7fccf63dc Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 20:16:18 +0200 Subject: [PATCH 77/82] corrected testMatch pattern, fixed backend coverage collection (?) --- backend/package.json | 4 ++-- webapp/package.json | 5 +---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/backend/package.json b/backend/package.json index 9c9ccba54..a995c5dd6 100644 --- a/backend/package.json +++ b/backend/package.json @@ -28,7 +28,7 @@ "verbose": true, "collectCoverage": true, "collectCoverageFrom": [ - "**/*.{js}", + "**/*.js", "!**/node_modules/**", "!**/test/**" ], @@ -37,7 +37,7 @@ "lcov" ], "testMatch": [ - "**/src/**/?(*.)+(spec|test).js?(x)" + "**/src/**/?(*.).spec.js" ] }, "dependencies": { diff --git a/webapp/package.json b/webapp/package.json index 900adfc72..a41f13e11 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -27,9 +27,6 @@ "text", "lcov" ], - "moduleFileExtensions": [ - "js" - ], "transform": { ".*\\.(vue)$": "vue-jest", "^.+\\.js$": "/node_modules/babel-jest" @@ -39,7 +36,7 @@ "^~/(.*)$": "/$1" }, "testMatch": [ - "**/src/**/?(*.)+(spec|test).js?(x)" + "**/?(*.).spec.js" ] }, "dependencies": { From 9d7a9fd3ded4d33f419f2ec45b7c12fc07007086 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 20:40:03 +0200 Subject: [PATCH 78/82] bavel plugin for dynamic imports, frontend test & coverage collection working fine --- webapp/.babelrc | 5 ++++- webapp/package.json | 10 ++++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/webapp/.babelrc b/webapp/.babelrc index fbd5b7451..b23873e12 100644 --- a/webapp/.babelrc +++ b/webapp/.babelrc @@ -1,4 +1,7 @@ { + "plugins": [ + "@babel/plugin-syntax-dynamic-import" + ], "presets": [ [ "@babel/preset-env", @@ -21,4 +24,4 @@ ] } } -} +} \ No newline at end of file diff --git a/webapp/package.json b/webapp/package.json index a41f13e11..1cf5ec8c8 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -31,12 +31,17 @@ ".*\\.(vue)$": "vue-jest", "^.+\\.js$": "/node_modules/babel-jest" }, + "moduleFileExtensions": [ + "js", + "json", + "vue" + ], "moduleNameMapper": { "^@/(.*)$": "/src/$1", "^~/(.*)$": "/$1" }, "testMatch": [ - "**/?(*.).spec.js" + "**/?(*.)+(spec|test).js?(x)" ] }, "dependencies": { @@ -69,6 +74,7 @@ }, "devDependencies": { "@babel/core": "~7.4.4", + "@babel/plugin-syntax-dynamic-import": "^7.2.0", "@babel/preset-env": "~7.4.4", "@vue/cli-shared-utils": "~3.7.0", "@vue/eslint-config-prettier": "~4.0.1", @@ -92,4 +98,4 @@ "vue-jest": "~3.0.4", "vue-svg-loader": "~0.12.0" } -} \ No newline at end of file +} From 466a9584eabc6b0e8a0931ea6d4b5a253fe9644c Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 20:43:13 +0200 Subject: [PATCH 79/82] backend test pattern --- backend/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/package.json b/backend/package.json index a995c5dd6..9a4d40c3d 100644 --- a/backend/package.json +++ b/backend/package.json @@ -37,7 +37,7 @@ "lcov" ], "testMatch": [ - "**/src/**/?(*.).spec.js" + "**/src/**/?(*.)+(spec|test).js?(x)" ] }, "dependencies": { From 63b7ded4b60aa7bf5c204b1ac6c0937ef410a554 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 22:42:33 +0200 Subject: [PATCH 80/82] ignore test modules in coverage estimation --- backend/package.json | 3 ++- webapp/package.json | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/backend/package.json b/backend/package.json index 9a4d40c3d..95f5999b4 100644 --- a/backend/package.json +++ b/backend/package.json @@ -30,7 +30,8 @@ "collectCoverageFrom": [ "**/*.js", "!**/node_modules/**", - "!**/test/**" + "!**/test/**", + "!**/src/**/?(*.)+(spec|test).js?(x)" ], "coverageReporters": [ "text", diff --git a/webapp/package.json b/webapp/package.json index 1cf5ec8c8..adb72778c 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -21,7 +21,8 @@ "collectCoverageFrom": [ "**/*.{js,vue}", "!**/node_modules/**", - "!**/.nuxt/**" + "!**/.nuxt/**", + "!**/?(*.)+(spec|test).js?(x)" ], "coverageReporters": [ "text", @@ -98,4 +99,4 @@ "vue-jest": "~3.0.4", "vue-svg-loader": "~0.12.0" } -} +} \ No newline at end of file From 9c9522af8b88cd3b78642458787cc2f94b35c27d Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 22:53:11 +0200 Subject: [PATCH 81/82] typo --- webapp/components/Category/{index.spes.js => index.spec.js} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename webapp/components/Category/{index.spes.js => index.spec.js} (100%) diff --git a/webapp/components/Category/index.spes.js b/webapp/components/Category/index.spec.js similarity index 100% rename from webapp/components/Category/index.spes.js rename to webapp/components/Category/index.spec.js From 00d5c4fde59b58863d15672c1a58703632bec722 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 8 May 2019 22:58:00 +0200 Subject: [PATCH 82/82] ignore dist folder --- backend/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/package.json b/backend/package.json index 95f5999b4..d57597403 100644 --- a/backend/package.json +++ b/backend/package.json @@ -31,6 +31,7 @@ "**/*.js", "!**/node_modules/**", "!**/test/**", + "!**/dist/**", "!**/src/**/?(*.)+(spec|test).js?(x)" ], "coverageReporters": [