This commit is contained in:
Wolfgang Huß 2019-02-26 16:47:57 +01:00
commit 78b25ba05e
12 changed files with 292 additions and 310 deletions

View File

@ -0,0 +1,18 @@
version: "3.7"
services:
neo4j:
environment:
- NEO4J_AUTH=none
ports:
- 7687:7687
- 7474:7474
backend:
ports:
- 4001:4001
- 4123:4123
image: humanconnection/nitro-backend:builder
build:
context: .
target: builder
command: yarn run test:cypress

View File

@ -77,7 +77,7 @@
"babel-eslint": "~10.0.1", "babel-eslint": "~10.0.1",
"babel-jest": "~24.1.0", "babel-jest": "~24.1.0",
"chai": "~4.2.0", "chai": "~4.2.0",
"eslint": "~5.13.0", "eslint": "~5.14.1",
"eslint-config-standard": "~12.0.0", "eslint-config-standard": "~12.0.0",
"eslint-plugin-import": "~2.16.0", "eslint-plugin-import": "~2.16.0",
"eslint-plugin-jest": "~22.3.0", "eslint-plugin-jest": "~22.3.0",

View File

@ -6,7 +6,7 @@ import { host, login } from './jest/helpers'
const factory = Factory() const factory = Factory()
beforeEach(async () => { beforeEach(async () => {
await factory.create('user', { await factory.create('User', {
email: 'test@example.org', email: 'test@example.org',
password: '1234' password: '1234'
}) })
@ -122,11 +122,11 @@ describe('CreatePost', () => {
describe('report', () => { describe('report', () => {
beforeEach(async () => { beforeEach(async () => {
await factory.create('user', { await factory.create('User', {
email: 'test@example.org', email: 'test@example.org',
password: '1234' password: '1234'
}) })
await factory.create('user', { await factory.create('User', {
id: 'u2', id: 'u2',
name: 'abusive-user', name: 'abusive-user',
role: 'user', role: 'user',

View File

@ -7,12 +7,12 @@ const factory = Factory()
describe('authorization', () => { describe('authorization', () => {
describe('given two existing users', () => { describe('given two existing users', () => {
beforeEach(async () => { beforeEach(async () => {
await factory.create('user', { await factory.create('User', {
email: 'owner@example.org', email: 'owner@example.org',
name: 'Owner', name: 'Owner',
password: 'iamtheowner' password: 'iamtheowner'
}) })
await factory.create('user', { await factory.create('User', {
email: 'someone@example.org', email: 'someone@example.org',
name: 'Someone else', name: 'Someone else',
password: 'else' password: 'else'

View File

@ -7,8 +7,8 @@ let headers
const factory = Factory() const factory = Factory()
beforeEach(async () => { beforeEach(async () => {
await factory.create('user', { email: 'user@example.org', password: '1234' }) await factory.create('User', { email: 'user@example.org', password: '1234' })
await factory.create('user', { email: 'someone@example.org', password: '1234' }) await factory.create('User', { email: 'someone@example.org', password: '1234' })
headers = await login({ email: 'user@example.org', password: '1234' }) headers = await login({ email: 'user@example.org', password: '1234' })
authenticatedClient = new GraphQLClient(host, { headers }) authenticatedClient = new GraphQLClient(host, { headers })
}) })
@ -35,7 +35,7 @@ describe('slugify', () => {
email: 'someone@example.org', email: 'someone@example.org',
password: '1234' password: '1234'
}) })
await asSomeoneElse.create('post', { await asSomeoneElse.create('Post', {
title: 'Pre-existing post', title: 'Pre-existing post',
slug: 'pre-existing-post' slug: 'pre-existing-post'
}) })

View File

@ -23,15 +23,3 @@ export default function (params) {
} }
` `
} }
export function relate (type, params) {
const { from, to } = params
return `
mutation {
${from}_${type}_${to}: AddComment${type}(
from: { id: "${from}" },
to: { id: "${to}" }
) { from { id } }
}
`
}

View File

@ -1,6 +1,15 @@
import { GraphQLClient, request } from 'graphql-request' import { GraphQLClient, request } from 'graphql-request'
import { getDriver } from '../../bootstrap/neo4j' import { getDriver } from '../../bootstrap/neo4j'
import createBadge from './badges.js'
import createUser from './users.js'
import createOrganization from './organizations.js'
import createPost from './posts.js'
import createComment from './comments.js'
import createCategory from './categories.js'
import createTag from './tags.js'
import createReport from './reports.js'
export const seedServerHost = 'http://127.0.0.1:4001' export const seedServerHost = 'http://127.0.0.1:4001'
const authenticatedHeaders = async ({ email, password }, host) => { const authenticatedHeaders = async ({ email, password }, host) => {
@ -15,35 +24,15 @@ const authenticatedHeaders = async ({ email, password }, host) => {
authorization: `Bearer ${response.login.token}` authorization: `Bearer ${response.login.token}`
} }
} }
const factories = { const factories = {
'badge': require('./badges.js').default, 'Badge': createBadge,
'user': require('./users.js').default, 'User': createUser,
'organization': require('./organizations.js').default, 'Organization': createOrganization,
'post': require('./posts.js').default, 'Post': createPost,
'comment': require('./comments.js').default, 'Comment': createComment,
'category': require('./categories.js').default, 'Category': createCategory,
'tag': require('./tags.js').default, 'Tag': createTag,
'report': require('./reports.js').default 'Report': createReport
}
const relationFactories = {
'user': require('./users.js').relate,
'organization': require('./organizations.js').relate,
'post': require('./posts.js').relate,
'comment': require('./comments.js').relate
}
export const create = (model, parameters, options) => {
const graphQLClient = new GraphQLClient(seedServerHost, options)
const mutation = factories[model](parameters)
return graphQLClient.request(mutation)
}
export const relate = (model, type, parameters, options) => {
const graphQLClient = new GraphQLClient(seedServerHost, options)
const mutation = relationFactories[model](type, parameters)
return graphQLClient.request(mutation)
} }
export const cleanDatabase = async (options = {}) => { export const cleanDatabase = async (options = {}) => {
@ -73,6 +62,7 @@ export default function Factory (options = {}) {
neo4jDriver, neo4jDriver,
seedServerHost, seedServerHost,
graphQLClient, graphQLClient,
factories,
lastResponse: null, lastResponse: null,
async authenticateAs ({ email, password }) { async authenticateAs ({ email, password }) {
const headers = await authenticatedHeaders({ email, password }, seedServerHost) const headers = await authenticatedHeaders({ email, password }, seedServerHost)
@ -81,12 +71,20 @@ export default function Factory (options = {}) {
return this return this
}, },
async create (node, properties) { async create (node, properties) {
const mutation = factories[node](properties) const mutation = this.factories[node](properties)
this.lastResponse = await this.graphQLClient.request(mutation) this.lastResponse = await this.graphQLClient.request(mutation)
return this return this
}, },
async relate (node, relationship, properties) { async relate (node, relationship, properties) {
const mutation = relationFactories[node](relationship, properties) const { from, to } = properties
const mutation = `
mutation {
Add${node}${relationship}(
from: { id: "${from}" },
to: { id: "${to}" }
) { from { id } }
}
`
this.lastResponse = await this.graphQLClient.request(mutation) this.lastResponse = await this.graphQLClient.request(mutation)
return this return this
}, },

View File

@ -22,15 +22,3 @@ export default function create (params) {
} }
` `
} }
export function relate (type, params) {
const { from, to } = params
return `
mutation {
${from}_${type}_${to}: AddOrganization${type}(
from: { id: "${from}" },
to: { id: "${to}" }
) { from { id } }
}
`
}

View File

@ -32,15 +32,3 @@ export default function (params) {
} }
` `
} }
export function relate (type, params) {
const { from, to } = params
return `
mutation {
${from}_${type}_${to}: AddPost${type}(
from: { id: "${from}" },
to: { id: "${to}" }
) { from { id } }
}
`
}

View File

@ -33,15 +33,3 @@ export default function create (params) {
} }
` `
} }
export function relate (type, params) {
const { from, to } = params
return `
mutation {
${from}_${type}_${to}: AddUser${type}(
from: { id: "${from}" },
to: { id: "${to}" }
) { from { id } }
}
`
}

View File

@ -1,72 +1,73 @@
import Factory, { create, relate } from './factories' import Factory from './factories'
/* eslint-disable no-multi-spaces */ /* eslint-disable no-multi-spaces */
(async function () { (async function () {
try { try {
const f = Factory()
await Promise.all([ await Promise.all([
create('badge', { id: 'b1', key: 'indiegogo_en_racoon', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_racoon.svg' }), f.create('Badge', { id: 'b1', key: 'indiegogo_en_racoon', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_racoon.svg' }),
create('badge', { id: 'b2', key: 'indiegogo_en_rabbit', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_rabbit.svg' }), f.create('Badge', { id: 'b2', key: 'indiegogo_en_rabbit', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_rabbit.svg' }),
create('badge', { id: 'b3', key: 'indiegogo_en_wolf', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_wolf.svg' }), f.create('Badge', { id: 'b3', key: 'indiegogo_en_wolf', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_wolf.svg' }),
create('badge', { id: 'b4', key: 'indiegogo_en_bear', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_bear.svg' }), f.create('Badge', { id: 'b4', key: 'indiegogo_en_bear', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_bear.svg' }),
create('badge', { id: 'b5', key: 'indiegogo_en_turtle', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_turtle.svg' }), f.create('Badge', { id: 'b5', key: 'indiegogo_en_turtle', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_turtle.svg' }),
create('badge', { id: 'b6', key: 'indiegogo_en_rhino', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_rhino.svg' }) f.create('Badge', { id: 'b6', key: 'indiegogo_en_rhino', type: 'crowdfunding', status: 'permanent', icon: '/img/badges/indiegogo_en_rhino.svg' })
]) ])
await Promise.all([ await Promise.all([
create('user', { id: 'u1', name: 'Peter Lustig', role: 'admin', email: 'admin@example.org' }), f.create('User', { id: 'u1', name: 'Peter Lustig', role: 'admin', email: 'admin@example.org' }),
create('user', { id: 'u2', name: 'Bob der Baumeister', role: 'moderator', email: 'moderator@example.org' }), f.create('User', { id: 'u2', name: 'Bob der Baumeister', role: 'moderator', email: 'moderator@example.org' }),
create('user', { id: 'u3', name: 'Jenny Rostock', role: 'user', email: 'user@example.org' }), f.create('User', { id: 'u3', name: 'Jenny Rostock', role: 'user', email: 'user@example.org' }),
create('user', { id: 'u4', name: 'Tick', role: 'user', email: 'tick@example.org' }), f.create('User', { id: 'u4', name: 'Tick', role: 'user', email: 'tick@example.org' }),
create('user', { id: 'u5', name: 'Trick', role: 'user', email: 'trick@example.org' }), f.create('User', { id: 'u5', name: 'Trick', role: 'user', email: 'trick@example.org' }),
create('user', { id: 'u6', name: 'Track', role: 'user', email: 'track@example.org' }), f.create('User', { id: 'u6', name: 'Track', role: 'user', email: 'track@example.org' }),
create('user', { id: 'u7', name: 'Dagobert', role: 'user', email: 'dagobert@example.org' }) f.create('User', { id: 'u7', name: 'Dagobert', role: 'user', email: 'dagobert@example.org' })
]) ])
await Promise.all([ await Promise.all([
relate('user', 'Badges', { from: 'b6', to: 'u1' }), f.relate('User', 'Badges', { from: 'b6', to: 'u1' }),
relate('user', 'Badges', { from: 'b5', to: 'u2' }), f.relate('User', 'Badges', { from: 'b5', to: 'u2' }),
relate('user', 'Badges', { from: 'b4', to: 'u3' }), f.relate('User', 'Badges', { from: 'b4', to: 'u3' }),
relate('user', 'Badges', { from: 'b3', to: 'u4' }), f.relate('User', 'Badges', { from: 'b3', to: 'u4' }),
relate('user', 'Badges', { from: 'b2', to: 'u5' }), f.relate('User', 'Badges', { from: 'b2', to: 'u5' }),
relate('user', 'Badges', { from: 'b1', to: 'u6' }), f.relate('User', 'Badges', { from: 'b1', to: 'u6' }),
relate('user', 'Following', { from: 'u1', to: 'u2' }), f.relate('User', 'Following', { from: 'u1', to: 'u2' }),
relate('user', 'Following', { from: 'u2', to: 'u3' }), f.relate('User', 'Following', { from: 'u2', to: 'u3' }),
relate('user', 'Following', { from: 'u3', to: 'u4' }), f.relate('User', 'Following', { from: 'u3', to: 'u4' }),
relate('user', 'Following', { from: 'u4', to: 'u5' }), f.relate('User', 'Following', { from: 'u4', to: 'u5' }),
relate('user', 'Following', { from: 'u5', to: 'u6' }), f.relate('User', 'Following', { from: 'u5', to: 'u6' }),
relate('user', 'Following', { from: 'u6', to: 'u7' }), f.relate('User', 'Following', { from: 'u6', to: 'u7' }),
relate('user', 'Friends', { from: 'u1', to: 'u2' }), f.relate('User', 'Friends', { from: 'u1', to: 'u2' }),
relate('user', 'Friends', { from: 'u1', to: 'u3' }), f.relate('User', 'Friends', { from: 'u1', to: 'u3' }),
relate('user', 'Friends', { from: 'u2', to: 'u3' }), f.relate('User', 'Friends', { from: 'u2', to: 'u3' }),
relate('user', 'Blacklisted', { from: 'u7', to: 'u4' }), f.relate('User', 'Blacklisted', { from: 'u7', to: 'u4' }),
relate('user', 'Blacklisted', { from: 'u7', to: 'u5' }), f.relate('User', 'Blacklisted', { from: 'u7', to: 'u5' }),
relate('user', 'Blacklisted', { from: 'u7', to: 'u6' }) f.relate('User', 'Blacklisted', { from: 'u7', to: 'u6' })
]) ])
await Promise.all([ await Promise.all([
create('category', { id: 'cat1', name: 'Just For Fun', slug: 'justforfun', icon: 'smile' }), f.create('Category', { id: 'cat1', name: 'Just For Fun', slug: 'justforfun', icon: 'smile' }),
create('category', { id: 'cat2', name: 'Happyness & Values', slug: 'happyness-values', icon: 'heart-o' }), f.create('Category', { id: 'cat2', name: 'Happyness & Values', slug: 'happyness-values', icon: 'heart-o' }),
create('category', { id: 'cat3', name: 'Health & Wellbeing', slug: 'health-wellbeing', icon: 'medkit' }), f.create('Category', { id: 'cat3', name: 'Health & Wellbeing', slug: 'health-wellbeing', icon: 'medkit' }),
create('category', { id: 'cat4', name: 'Environment & Nature', slug: 'environment-nature', icon: 'tree' }), f.create('Category', { id: 'cat4', name: 'Environment & Nature', slug: 'environment-nature', icon: 'tree' }),
create('category', { id: 'cat5', name: 'Animal Protection', slug: 'animalprotection', icon: 'paw' }), f.create('Category', { id: 'cat5', name: 'Animal Protection', slug: 'animalprotection', icon: 'paw' }),
create('category', { id: 'cat6', name: 'Humanrights Justice', slug: 'humanrights-justice', icon: 'balance-scale' }), f.create('Category', { id: 'cat6', name: 'Humanrights Justice', slug: 'humanrights-justice', icon: 'balance-scale' }),
create('category', { id: 'cat7', name: 'Education & Sciences', slug: 'education-sciences', icon: 'graduation-cap' }), f.create('Category', { id: 'cat7', name: 'Education & Sciences', slug: 'education-sciences', icon: 'graduation-cap' }),
create('category', { id: 'cat8', name: 'Cooperation & Development', slug: 'cooperation-development', icon: 'users' }), f.create('Category', { id: 'cat8', name: 'Cooperation & Development', slug: 'cooperation-development', icon: 'users' }),
create('category', { id: 'cat9', name: 'Democracy & Politics', slug: 'democracy-politics', icon: 'university' }), f.create('Category', { id: 'cat9', name: 'Democracy & Politics', slug: 'democracy-politics', icon: 'university' }),
create('category', { id: 'cat10', name: 'Economy & Finances', slug: 'economy-finances', icon: 'money' }), f.create('Category', { id: 'cat10', name: 'Economy & Finances', slug: 'economy-finances', icon: 'money' }),
create('category', { id: 'cat11', name: 'Energy & Technology', slug: 'energy-technology', icon: 'flash' }), f.create('Category', { id: 'cat11', name: 'Energy & Technology', slug: 'energy-technology', icon: 'flash' }),
create('category', { id: 'cat12', name: 'IT, Internet & Data Privacy', slug: 'it-internet-dataprivacy', icon: 'mouse-pointer' }), f.create('Category', { id: 'cat12', name: 'IT, Internet & Data Privacy', slug: 'it-internet-dataprivacy', icon: 'mouse-pointer' }),
create('category', { id: 'cat13', name: 'Art, Curlure & Sport', slug: 'art-culture-sport', icon: 'paint-brush' }), f.create('Category', { id: 'cat13', name: 'Art, Curlure & Sport', slug: 'art-culture-sport', icon: 'paint-brush' }),
create('category', { id: 'cat14', name: 'Freedom of Speech', slug: 'freedomofspeech', icon: 'bullhorn' }), f.create('Category', { id: 'cat14', name: 'Freedom of Speech', slug: 'freedomofspeech', icon: 'bullhorn' }),
create('category', { id: 'cat15', name: 'Consumption & Sustainability', slug: 'consumption-sustainability', icon: 'shopping-cart' }), f.create('Category', { id: 'cat15', name: 'Consumption & Sustainability', slug: 'consumption-sustainability', icon: 'shopping-cart' }),
create('category', { id: 'cat16', name: 'Global Peace & Nonviolence', slug: 'globalpeace-nonviolence', icon: 'angellist' }) f.create('Category', { id: 'cat16', name: 'Global Peace & Nonviolence', slug: 'globalpeace-nonviolence', icon: 'angellist' })
]) ])
await Promise.all([ await Promise.all([
create('tag', { id: 't1', name: 'Umwelt' }), f.create('Tag', { id: 't1', name: 'Umwelt' }),
create('tag', { id: 't2', name: 'Naturschutz' }), f.create('Tag', { id: 't2', name: 'Naturschutz' }),
create('tag', { id: 't3', name: 'Demokratie' }), f.create('Tag', { id: 't3', name: 'Demokratie' }),
create('tag', { id: 't4', name: 'Freiheit' }) f.create('Tag', { id: 't4', name: 'Freiheit' })
]) ])
const [ asAdmin, asModerator, asUser, asTick, asTrick, asTrack ] = await Promise.all([ const [ asAdmin, asModerator, asUser, asTick, asTrick, asTrack ] = await Promise.all([
@ -79,113 +80,113 @@ import Factory, { create, relate } from './factories'
]) ])
await Promise.all([ await Promise.all([
asAdmin.create('post', { id: 'p0' }), asAdmin.create('Post', { id: 'p0' }),
asModerator.create('post', { id: 'p1' }), asModerator.create('Post', { id: 'p1' }),
asUser.create('post', { id: 'p2' }), asUser.create('Post', { id: 'p2' }),
asTick.create('post', { id: 'p3' }), asTick.create('Post', { id: 'p3' }),
asTrick.create('post', { id: 'p4' }), asTrick.create('Post', { id: 'p4' }),
asTrack.create('post', { id: 'p5' }), asTrack.create('Post', { id: 'p5' }),
asAdmin.create('post', { id: 'p6' }), asAdmin.create('Post', { id: 'p6' }),
asModerator.create('post', { id: 'p7' }), asModerator.create('Post', { id: 'p7' }),
asUser.create('post', { id: 'p8' }), asUser.create('Post', { id: 'p8' }),
asTick.create('post', { id: 'p9' }), asTick.create('Post', { id: 'p9' }),
asTrick.create('post', { id: 'p10' }), asTrick.create('Post', { id: 'p10' }),
asTrack.create('post', { id: 'p11' }), asTrack.create('Post', { id: 'p11' }),
asAdmin.create('post', { id: 'p12' }), asAdmin.create('Post', { id: 'p12' }),
asModerator.create('post', { id: 'p13' }), asModerator.create('Post', { id: 'p13' }),
asUser.create('post', { id: 'p14' }), asUser.create('Post', { id: 'p14' }),
asTick.create('post', { id: 'p15' }) asTick.create('Post', { id: 'p15' })
]) ])
await Promise.all([ await Promise.all([
relate('post', 'Categories', { from: 'p0', to: 'cat16' }), f.relate('Post', 'Categories', { from: 'p0', to: 'cat16' }),
relate('post', 'Categories', { from: 'p1', to: 'cat1' }), f.relate('Post', 'Categories', { from: 'p1', to: 'cat1' }),
relate('post', 'Categories', { from: 'p2', to: 'cat2' }), f.relate('Post', 'Categories', { from: 'p2', to: 'cat2' }),
relate('post', 'Categories', { from: 'p3', to: 'cat3' }), f.relate('Post', 'Categories', { from: 'p3', to: 'cat3' }),
relate('post', 'Categories', { from: 'p4', to: 'cat4' }), f.relate('Post', 'Categories', { from: 'p4', to: 'cat4' }),
relate('post', 'Categories', { from: 'p5', to: 'cat5' }), f.relate('Post', 'Categories', { from: 'p5', to: 'cat5' }),
relate('post', 'Categories', { from: 'p6', to: 'cat6' }), f.relate('Post', 'Categories', { from: 'p6', to: 'cat6' }),
relate('post', 'Categories', { from: 'p7', to: 'cat7' }), f.relate('Post', 'Categories', { from: 'p7', to: 'cat7' }),
relate('post', 'Categories', { from: 'p8', to: 'cat8' }), f.relate('Post', 'Categories', { from: 'p8', to: 'cat8' }),
relate('post', 'Categories', { from: 'p9', to: 'cat9' }), f.relate('Post', 'Categories', { from: 'p9', to: 'cat9' }),
relate('post', 'Categories', { from: 'p10', to: 'cat10' }), f.relate('Post', 'Categories', { from: 'p10', to: 'cat10' }),
relate('post', 'Categories', { from: 'p11', to: 'cat11' }), f.relate('Post', 'Categories', { from: 'p11', to: 'cat11' }),
relate('post', 'Categories', { from: 'p12', to: 'cat12' }), f.relate('Post', 'Categories', { from: 'p12', to: 'cat12' }),
relate('post', 'Categories', { from: 'p13', to: 'cat13' }), f.relate('Post', 'Categories', { from: 'p13', to: 'cat13' }),
relate('post', 'Categories', { from: 'p14', to: 'cat14' }), f.relate('Post', 'Categories', { from: 'p14', to: 'cat14' }),
relate('post', 'Categories', { from: 'p15', to: 'cat15' }), f.relate('Post', 'Categories', { from: 'p15', to: 'cat15' }),
relate('post', 'Tags', { from: 'p0', to: 't4' }), f.relate('Post', 'Tags', { from: 'p0', to: 't4' }),
relate('post', 'Tags', { from: 'p1', to: 't1' }), f.relate('Post', 'Tags', { from: 'p1', to: 't1' }),
relate('post', 'Tags', { from: 'p2', to: 't2' }), f.relate('Post', 'Tags', { from: 'p2', to: 't2' }),
relate('post', 'Tags', { from: 'p3', to: 't3' }), f.relate('Post', 'Tags', { from: 'p3', to: 't3' }),
relate('post', 'Tags', { from: 'p4', to: 't4' }), f.relate('Post', 'Tags', { from: 'p4', to: 't4' }),
relate('post', 'Tags', { from: 'p5', to: 't1' }), f.relate('Post', 'Tags', { from: 'p5', to: 't1' }),
relate('post', 'Tags', { from: 'p6', to: 't2' }), f.relate('Post', 'Tags', { from: 'p6', to: 't2' }),
relate('post', 'Tags', { from: 'p7', to: 't3' }), f.relate('Post', 'Tags', { from: 'p7', to: 't3' }),
relate('post', 'Tags', { from: 'p8', to: 't4' }), f.relate('Post', 'Tags', { from: 'p8', to: 't4' }),
relate('post', 'Tags', { from: 'p9', to: 't1' }), f.relate('Post', 'Tags', { from: 'p9', to: 't1' }),
relate('post', 'Tags', { from: 'p10', to: 't2' }), f.relate('Post', 'Tags', { from: 'p10', to: 't2' }),
relate('post', 'Tags', { from: 'p11', to: 't3' }), f.relate('Post', 'Tags', { from: 'p11', to: 't3' }),
relate('post', 'Tags', { from: 'p12', to: 't4' }), f.relate('Post', 'Tags', { from: 'p12', to: 't4' }),
relate('post', 'Tags', { from: 'p13', to: 't1' }), f.relate('Post', 'Tags', { from: 'p13', to: 't1' }),
relate('post', 'Tags', { from: 'p14', to: 't2' }), f.relate('Post', 'Tags', { from: 'p14', to: 't2' }),
relate('post', 'Tags', { from: 'p15', to: 't3' }) f.relate('Post', 'Tags', { from: 'p15', to: 't3' })
]) ])
await Promise.all([ await Promise.all([
relate('user', 'Shouted', { from: 'u1', to: 'p2' }), f.relate('User', 'Shouted', { from: 'u1', to: 'p2' }),
relate('user', 'Shouted', { from: 'u1', to: 'p3' }), f.relate('User', 'Shouted', { from: 'u1', to: 'p3' }),
relate('user', 'Shouted', { from: 'u2', to: 'p1' }), f.relate('User', 'Shouted', { from: 'u2', to: 'p1' }),
relate('user', 'Shouted', { from: 'u3', to: 'p1' }), f.relate('User', 'Shouted', { from: 'u3', to: 'p1' }),
relate('user', 'Shouted', { from: 'u3', to: 'p4' }), f.relate('User', 'Shouted', { from: 'u3', to: 'p4' }),
relate('user', 'Shouted', { from: 'u4', to: 'p1' }) f.relate('User', 'Shouted', { from: 'u4', to: 'p1' })
]) ])
await Promise.all([ await Promise.all([
create('comment', { id: 'c1' }), f.create('Comment', { id: 'c1' }),
create('comment', { id: 'c2' }), f.create('Comment', { id: 'c2' }),
create('comment', { id: 'c3' }), f.create('Comment', { id: 'c3' }),
create('comment', { id: 'c4' }), f.create('Comment', { id: 'c4' }),
create('comment', { id: 'c5' }), f.create('Comment', { id: 'c5' }),
create('comment', { id: 'c6' }), f.create('Comment', { id: 'c6' }),
create('comment', { id: 'c7' }) f.create('Comment', { id: 'c7' })
]) ])
await Promise.all([ await Promise.all([
relate('comment', 'Author', { from: 'u3', to: 'c1' }), f.relate('Comment', 'Author', { from: 'u3', to: 'c1' }),
relate('comment', 'Post', { from: 'c1', to: 'p1' }), f.relate('Comment', 'Post', { from: 'c1', to: 'p1' }),
relate('comment', 'Author', { from: 'u1', to: 'c2' }), f.relate('Comment', 'Author', { from: 'u1', to: 'c2' }),
relate('comment', 'Post', { from: 'c2', to: 'p1' }), f.relate('Comment', 'Post', { from: 'c2', to: 'p1' }),
relate('comment', 'Author', { from: 'u1', to: 'c3' }), f.relate('Comment', 'Author', { from: 'u1', to: 'c3' }),
relate('comment', 'Post', { from: 'c3', to: 'p3' }), f.relate('Comment', 'Post', { from: 'c3', to: 'p3' }),
relate('comment', 'Author', { from: 'u4', to: 'c4' }), f.relate('Comment', 'Author', { from: 'u4', to: 'c4' }),
relate('comment', 'Post', { from: 'c4', to: 'p2' }), f.relate('Comment', 'Post', { from: 'c4', to: 'p2' }),
relate('comment', 'Author', { from: 'u4', to: 'c5' }), f.relate('Comment', 'Author', { from: 'u4', to: 'c5' }),
relate('comment', 'Post', { from: 'c5', to: 'p3' }), f.relate('Comment', 'Post', { from: 'c5', to: 'p3' }),
relate('comment', 'Author', { from: 'u3', to: 'c6' }), f.relate('Comment', 'Author', { from: 'u3', to: 'c6' }),
relate('comment', 'Post', { from: 'c6', to: 'p4' }), f.relate('Comment', 'Post', { from: 'c6', to: 'p4' }),
relate('comment', 'Author', { from: 'u2', to: 'c7' }), f.relate('Comment', 'Author', { from: 'u2', to: 'c7' }),
relate('comment', 'Post', { from: 'c7', to: 'p2' }) f.relate('Comment', 'Post', { from: 'c7', to: 'p2' })
]) ])
await Promise.all([ await Promise.all([
asTick.create('report', { description: 'I don\'t like this comment', resource: { id: 'c1', type: 'comment' } }), asTick.create('Report', { description: 'I don\'t like this comment', resource: { id: 'c1', type: 'comment' } }),
asTrick.create('report', { description: 'I don\'t like this post', resource: { id: 'p1', type: 'contribution' } }), asTrick.create('Report', { description: 'I don\'t like this post', resource: { id: 'p1', type: 'contribution' } }),
asTrack.create('report', { description: 'I don\'t like this user', resource: { id: 'u1', type: 'user' } }) asTrack.create('Report', { description: 'I don\'t like this user', resource: { id: 'u1', type: 'user' } })
]) ])
await Promise.all([ await Promise.all([
create('organization', { id: 'o1', name: 'Democracy Deutschland', description: 'Description for democracy-deutschland.' }), f.create('Organization', { id: 'o1', name: 'Democracy Deutschland', description: 'Description for democracy-deutschland.' }),
create('organization', { id: 'o2', name: 'Human-Connection', description: 'Description for human-connection.' }), f.create('Organization', { id: 'o2', name: 'Human-Connection', description: 'Description for human-connection.' }),
create('organization', { id: 'o3', name: 'Pro Veg', description: 'Description for pro-veg.' }), f.create('Organization', { id: 'o3', name: 'Pro Veg', description: 'Description for pro-veg.' }),
create('organization', { id: 'o4', name: 'Greenpeace', description: 'Description for greenpeace.' }) f.create('Organization', { id: 'o4', name: 'Greenpeace', description: 'Description for greenpeace.' })
]) ])
await Promise.all([ await Promise.all([
relate('organization', 'CreatedBy', { from: 'u1', to: 'o1' }), f.relate('Organization', 'CreatedBy', { from: 'u1', to: 'o1' }),
relate('organization', 'CreatedBy', { from: 'u1', to: 'o2' }), f.relate('Organization', 'CreatedBy', { from: 'u1', to: 'o2' }),
relate('organization', 'OwnedBy', { from: 'u2', to: 'o2' }), f.relate('Organization', 'OwnedBy', { from: 'u2', to: 'o2' }),
relate('organization', 'OwnedBy', { from: 'u2', to: 'o3' }) f.relate('Organization', 'OwnedBy', { from: 'u2', to: 'o3' })
]) ])
/* eslint-disable-next-line no-console */ /* eslint-disable-next-line no-console */
console.log('Seeded Data...') console.log('Seeded Data...')

183
yarn.lock
View File

@ -871,15 +871,20 @@ acorn@^5.5.3:
resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279" resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279"
integrity sha512-T/zvzYRfbVojPWahDsE5evJdHb3oJoQfFbsrKM7w5Zcs++Tr257tia3BmMP8XYVjp1S9RZXQMh7gao96BlqZOw== integrity sha512-T/zvzYRfbVojPWahDsE5evJdHb3oJoQfFbsrKM7w5Zcs++Tr257tia3BmMP8XYVjp1S9RZXQMh7gao96BlqZOw==
acorn@^6.0.1, acorn@^6.0.2: acorn@^6.0.1:
version "6.0.4" version "6.0.4"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.0.4.tgz#77377e7353b72ec5104550aa2d2097a2fd40b754" resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.0.4.tgz#77377e7353b72ec5104550aa2d2097a2fd40b754"
integrity sha512-VY4i5EKSKkofY2I+6QLTbTTN/UvEQPCo6eiwzzSaSWfpaDhOmStMCMod6wmuPciNq+XS0faCglFu2lHZpdHUtg== integrity sha512-VY4i5EKSKkofY2I+6QLTbTTN/UvEQPCo6eiwzzSaSWfpaDhOmStMCMod6wmuPciNq+XS0faCglFu2lHZpdHUtg==
ajv@^6.5.3, ajv@^6.5.5, ajv@^6.6.1: acorn@^6.0.7:
version "6.6.1" version "6.1.0"
resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.6.1.tgz#6360f5ed0d80f232cc2b294c362d5dc2e538dd61" resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.1.0.tgz#b0a3be31752c97a0f7013c5f4903b71a05db6818"
integrity sha512-ZoJjft5B+EJBjUyu9C9Hc0OZyPZSSlOF+plzouTrg6UlA8f+e/n8NIgBFG/9tppJtpPWfthHakK7juJdNDODww== integrity sha512-MW/FjM+IvU9CgBzjO3UIPCE2pyEwUsoFl+VGdczOPEdxfGFjuKny/gN54mOuX7Qxmb9Rg9MCn2oKiSUeW+pjrw==
ajv@^6.5.5, ajv@^6.9.1:
version "6.9.2"
resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.9.2.tgz#4927adb83e7f48e5a32b45729744c71ec39c9c7b"
integrity sha512-4UFy0/LgDo7Oa/+wOAlj44tp9K78u38E5/359eSrqEp1Z5PdVfimCcs7SluXMP755RUQu6d2b4AvF0R1C9RZjg==
dependencies: dependencies:
fast-deep-equal "^2.0.1" fast-deep-equal "^2.0.1"
fast-json-stable-stringify "^2.0.0" fast-json-stable-stringify "^2.0.0"
@ -898,6 +903,11 @@ ansi-escapes@^3.0.0:
resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.1.0.tgz#f73207bb81207d75fd6c83f125af26eea378ca30" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.1.0.tgz#f73207bb81207d75fd6c83f125af26eea378ca30"
integrity sha512-UgAb8H9D41AQnu/PbWlCofQVcnV4Gs2bBJi9eZPxfU/hgglFh3SMDMENRIqdr7H6XFnXdoknctFByVsCOotTVw== integrity sha512-UgAb8H9D41AQnu/PbWlCofQVcnV4Gs2bBJi9eZPxfU/hgglFh3SMDMENRIqdr7H6XFnXdoknctFByVsCOotTVw==
ansi-escapes@^3.2.0:
version "3.2.0"
resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b"
integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ==
ansi-regex@^2.0.0: ansi-regex@^2.0.0:
version "2.1.1" version "2.1.1"
resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df"
@ -1693,16 +1703,7 @@ chai@~4.2.0:
pathval "^1.1.0" pathval "^1.1.0"
type-detect "^4.0.5" type-detect "^4.0.5"
chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.4.1: chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.4.1, chalk@^2.4.2:
version "2.4.1"
resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e"
integrity sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==
dependencies:
ansi-styles "^3.2.1"
escape-string-regexp "^1.0.5"
supports-color "^5.3.0"
chalk@^2.4.2:
version "2.4.2" version "2.4.2"
resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424"
integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==
@ -1767,11 +1768,6 @@ ci-info@^2.0.0:
resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-2.0.0.tgz#67a9e964be31a51e15e5010d58e6f12834002f46" resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-2.0.0.tgz#67a9e964be31a51e15e5010d58e6f12834002f46"
integrity sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ== integrity sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==
circular-json@^0.3.1:
version "0.3.3"
resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66"
integrity sha512-UZK3NBx2Mca+b5LsG7bY183pHWt5Y1xts4P3Pz7ENTwGVnJOUWbRb3ocjvX7hx9tq/yTAdclXm9sZ38gNuem4A==
class-utils@^0.3.5: class-utils@^0.3.5:
version "0.3.6" version "0.3.6"
resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463"
@ -2225,10 +2221,10 @@ doctrine@1.5.0:
esutils "^2.0.2" esutils "^2.0.2"
isarray "^1.0.0" isarray "^1.0.0"
doctrine@^2.1.0: doctrine@^3.0.0:
version "2.1.0" version "3.0.0"
resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961"
integrity sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw== integrity sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==
dependencies: dependencies:
esutils "^2.0.2" esutils "^2.0.2"
@ -2327,6 +2323,11 @@ electron-to-chromium@^1.3.86:
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.88.tgz#f36ab32634f49ef2b0fdc1e82e2d1cc17feb29e7" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.88.tgz#f36ab32634f49ef2b0fdc1e82e2d1cc17feb29e7"
integrity sha512-UPV4NuQMKeUh1S0OWRvwg0PI8ASHN9kBC8yDTk1ROXLC85W5GnhTRu/MZu3Teqx3JjlQYuckuHYXSUSgtb3J+A== integrity sha512-UPV4NuQMKeUh1S0OWRvwg0PI8ASHN9kBC8yDTk1ROXLC85W5GnhTRu/MZu3Teqx3JjlQYuckuHYXSUSgtb3J+A==
emoji-regex@^7.0.1:
version "7.0.3"
resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156"
integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==
encodeurl@~1.0.2: encodeurl@~1.0.2:
version "1.0.2" version "1.0.2"
resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59"
@ -2508,35 +2509,35 @@ eslint-visitor-keys@^1.0.0:
resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d"
integrity sha512-qzm/XxIbxm/FHyH341ZrbnMUpe+5Bocte9xkmFMzPMjRaZMcXww+MpBptFvtU+79L362nqiLhekCxCxDPaUMBQ== integrity sha512-qzm/XxIbxm/FHyH341ZrbnMUpe+5Bocte9xkmFMzPMjRaZMcXww+MpBptFvtU+79L362nqiLhekCxCxDPaUMBQ==
eslint@~5.13.0: eslint@~5.14.1:
version "5.13.0" version "5.14.1"
resolved "https://registry.yarnpkg.com/eslint/-/eslint-5.13.0.tgz#ce71cc529c450eed9504530939aa97527861ede9" resolved "https://registry.yarnpkg.com/eslint/-/eslint-5.14.1.tgz#490a28906be313685c55ccd43a39e8d22efc04ba"
integrity sha512-nqD5WQMisciZC5EHZowejLKQjWGuFS5c70fxqSKlnDME+oz9zmE8KTlX+lHSg+/5wsC/kf9Q9eMkC8qS3oM2fg== integrity sha512-CyUMbmsjxedx8B0mr79mNOqetvkbij/zrXnFeK2zc3pGRn3/tibjiNAv/3UxFEyfMDjh+ZqTrJrEGBFiGfD5Og==
dependencies: dependencies:
"@babel/code-frame" "^7.0.0" "@babel/code-frame" "^7.0.0"
ajv "^6.5.3" ajv "^6.9.1"
chalk "^2.1.0" chalk "^2.1.0"
cross-spawn "^6.0.5" cross-spawn "^6.0.5"
debug "^4.0.1" debug "^4.0.1"
doctrine "^2.1.0" doctrine "^3.0.0"
eslint-scope "^4.0.0" eslint-scope "^4.0.0"
eslint-utils "^1.3.1" eslint-utils "^1.3.1"
eslint-visitor-keys "^1.0.0" eslint-visitor-keys "^1.0.0"
espree "^5.0.0" espree "^5.0.1"
esquery "^1.0.1" esquery "^1.0.1"
esutils "^2.0.2" esutils "^2.0.2"
file-entry-cache "^2.0.0" file-entry-cache "^5.0.1"
functional-red-black-tree "^1.0.1" functional-red-black-tree "^1.0.1"
glob "^7.1.2" glob "^7.1.2"
globals "^11.7.0" globals "^11.7.0"
ignore "^4.0.6" ignore "^4.0.6"
import-fresh "^3.0.0" import-fresh "^3.0.0"
imurmurhash "^0.1.4" imurmurhash "^0.1.4"
inquirer "^6.1.0" inquirer "^6.2.2"
js-yaml "^3.12.0" js-yaml "^3.12.0"
json-stable-stringify-without-jsonify "^1.0.1" json-stable-stringify-without-jsonify "^1.0.1"
levn "^0.3.0" levn "^0.3.0"
lodash "^4.17.5" lodash "^4.17.11"
minimatch "^3.0.4" minimatch "^3.0.4"
mkdirp "^0.5.1" mkdirp "^0.5.1"
natural-compare "^1.4.0" natural-compare "^1.4.0"
@ -2547,15 +2548,15 @@ eslint@~5.13.0:
semver "^5.5.1" semver "^5.5.1"
strip-ansi "^4.0.0" strip-ansi "^4.0.0"
strip-json-comments "^2.0.1" strip-json-comments "^2.0.1"
table "^5.0.2" table "^5.2.3"
text-table "^0.2.0" text-table "^0.2.0"
espree@^5.0.0: espree@^5.0.1:
version "5.0.0" version "5.0.1"
resolved "https://registry.yarnpkg.com/espree/-/espree-5.0.0.tgz#fc7f984b62b36a0f543b13fb9cd7b9f4a7f5b65c" resolved "https://registry.yarnpkg.com/espree/-/espree-5.0.1.tgz#5d6526fa4fc7f0788a5cf75b15f30323e2f81f7a"
integrity sha512-1MpUfwsdS9MMoN7ZXqAr9e9UKdVHDcvrJpyx7mm1WuQlx/ygErEQBzgi5Nh5qBHIoYweprhtMkTCb9GhcAIcsA== integrity sha512-qWAZcWh4XE/RwzLJejfcofscgMc9CamR6Tn1+XRXNzrvUSSbiAjGOI/fggztjIi7y9VLPqnICMIPiGyr8JaZ0A==
dependencies: dependencies:
acorn "^6.0.2" acorn "^6.0.7"
acorn-jsx "^5.0.0" acorn-jsx "^5.0.0"
eslint-visitor-keys "^1.0.0" eslint-visitor-keys "^1.0.0"
@ -2726,7 +2727,7 @@ extend@^3.0.0, extend@~3.0.2:
resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa"
integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==
external-editor@^3.0.0: external-editor@^3.0.3:
version "3.0.3" version "3.0.3"
resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.0.3.tgz#5866db29a97826dbe4bf3afd24070ead9ea43a27" resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.0.3.tgz#5866db29a97826dbe4bf3afd24070ead9ea43a27"
integrity sha512-bn71H9+qWoOQKyZDo25mOMVpSmXROAsTJVVVYzrrtol3d4y+AsKjf4Iwl2Q+IuT0kFSQ1qo166UuIwqYq7mGnA== integrity sha512-bn71H9+qWoOQKyZDo25mOMVpSmXROAsTJVVVYzrrtol3d4y+AsKjf4Iwl2Q+IuT0kFSQ1qo166UuIwqYq7mGnA==
@ -2793,13 +2794,12 @@ figures@^2.0.0:
dependencies: dependencies:
escape-string-regexp "^1.0.5" escape-string-regexp "^1.0.5"
file-entry-cache@^2.0.0: file-entry-cache@^5.0.1:
version "2.0.0" version "5.0.1"
resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c"
integrity sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E= integrity sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g==
dependencies: dependencies:
flat-cache "^1.2.1" flat-cache "^2.0.1"
object-assign "^4.0.1"
fileset@^2.0.3: fileset@^2.0.3:
version "2.0.3" version "2.0.3"
@ -2864,15 +2864,19 @@ find-up@^3.0.0:
dependencies: dependencies:
locate-path "^3.0.0" locate-path "^3.0.0"
flat-cache@^1.2.1: flat-cache@^2.0.1:
version "1.3.4" version "2.0.1"
resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.3.4.tgz#2c2ef77525cc2929007dfffa1dd314aa9c9dee6f" resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-2.0.1.tgz#5d296d6f04bda44a4630a301413bdbc2ec085ec0"
integrity sha512-VwyB3Lkgacfik2vhqR4uv2rvebqmDvFu4jlN/C1RzWoJEo8I7z4Q404oiqYCkq41mni8EzQnm95emU9seckwtg== integrity sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA==
dependencies: dependencies:
circular-json "^0.3.1" flatted "^2.0.0"
graceful-fs "^4.1.2" rimraf "2.6.3"
rimraf "~2.6.2" write "1.0.3"
write "^0.2.1"
flatted@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.0.tgz#55122b6536ea496b4b44893ee2608141d10d9916"
integrity sha512-R+H8IZclI8AAkSBRQJLVOsxwAoHd6WC40b4QTNWIjzAa6BXOBfQcM587MXDTVPeYaopFNWHUFLx7eNmHDSxMWg==
fn-name@~2.0.1: fn-name@~2.0.1:
version "2.0.1" version "2.0.1"
@ -3509,21 +3513,21 @@ ini@^1.3.4, ini@~1.3.0:
resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927"
integrity sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw== integrity sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==
inquirer@^6.1.0: inquirer@^6.2.2:
version "6.2.1" version "6.2.2"
resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-6.2.1.tgz#9943fc4882161bdb0b0c9276769c75b32dbfcd52" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-6.2.2.tgz#46941176f65c9eb20804627149b743a218f25406"
integrity sha512-088kl3DRT2dLU5riVMKKr1DlImd6X7smDhpXUCkJDCKvTEJeRiXh0G132HG9u5a+6Ylw9plFRY7RuTnwohYSpg== integrity sha512-Z2rREiXA6cHRR9KBOarR3WuLlFzlIfAEIiB45ll5SSadMg7WqOh1MKEjjndfuH5ewXdixWCxqnVfGOQzPeiztA==
dependencies: dependencies:
ansi-escapes "^3.0.0" ansi-escapes "^3.2.0"
chalk "^2.0.0" chalk "^2.4.2"
cli-cursor "^2.1.0" cli-cursor "^2.1.0"
cli-width "^2.0.0" cli-width "^2.0.0"
external-editor "^3.0.0" external-editor "^3.0.3"
figures "^2.0.0" figures "^2.0.0"
lodash "^4.17.10" lodash "^4.17.11"
mute-stream "0.0.7" mute-stream "0.0.7"
run-async "^2.2.0" run-async "^2.2.0"
rxjs "^6.1.0" rxjs "^6.4.0"
string-width "^2.1.0" string-width "^2.1.0"
strip-ansi "^5.0.0" strip-ansi "^5.0.0"
through "^2.3.6" through "^2.3.6"
@ -5079,7 +5083,7 @@ oauth-sign@~0.9.0:
resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455"
integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==
object-assign@^4, object-assign@^4.0.1, object-assign@^4.1.0, object-assign@^4.1.1: object-assign@^4, object-assign@^4.1.0, object-assign@^4.1.1:
version "4.1.1" version "4.1.1"
resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863"
integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=
@ -5970,7 +5974,7 @@ retry@0.12.0:
resolved "https://registry.yarnpkg.com/retry/-/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b" resolved "https://registry.yarnpkg.com/retry/-/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b"
integrity sha1-G0KmJmoh8HQh0bC1S33BZ7AcATs= integrity sha1-G0KmJmoh8HQh0bC1S33BZ7AcATs=
rimraf@^2.5.4, rimraf@^2.6.1, rimraf@^2.6.2, rimraf@^2.6.3, rimraf@~2.6.2: rimraf@2.6.3, rimraf@^2.5.4, rimraf@^2.6.1, rimraf@^2.6.2, rimraf@^2.6.3:
version "2.6.3" version "2.6.3"
resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab"
integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==
@ -5994,10 +5998,10 @@ rx@^4.1.0:
resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782" resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782"
integrity sha1-pfE/957zt0D+MKqAP7CfmIBdR4I= integrity sha1-pfE/957zt0D+MKqAP7CfmIBdR4I=
rxjs@^6.1.0: rxjs@^6.4.0:
version "6.3.3" version "6.4.0"
resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.3.3.tgz#3c6a7fa420e844a81390fb1158a9ec614f4bad55" resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.4.0.tgz#f3bb0fe7bda7fb69deac0c16f17b50b0b8790504"
integrity sha512-JTWmoY9tWCs7zvIk/CvRjhjGaOd+OVBM987mxFo+OW66cGpdKjZcpmc74ES1sB//7Kl/PAe8+wEakuhG4pcgOw== integrity sha512-Z9Yfa11F6B9Sg/BK9MnqnQ+aQYicPLtilXBp2yUtDt2JRCE0h26d33EnfO3ZxoNxG0T92OUucP3Ct7cpfkdFfw==
dependencies: dependencies:
tslib "^1.9.0" tslib "^1.9.0"
@ -6195,10 +6199,10 @@ slash@^2.0.0:
resolved "https://registry.yarnpkg.com/slash/-/slash-2.0.0.tgz#de552851a1759df3a8f206535442f5ec4ddeab44" resolved "https://registry.yarnpkg.com/slash/-/slash-2.0.0.tgz#de552851a1759df3a8f206535442f5ec4ddeab44"
integrity sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A== integrity sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A==
slice-ansi@2.0.0: slice-ansi@^2.1.0:
version "2.0.0" version "2.1.0"
resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-2.0.0.tgz#5373bdb8559b45676e8541c66916cdd6251612e7" resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-2.1.0.tgz#cacd7693461a637a5788d92a7dd4fba068e81636"
integrity sha512-4j2WTWjp3GsZ+AOagyzVbzp4vWGtZ0hEZ/gDY/uTvm6MTxUfTUIsnMIFb1bn8o0RuXiqUw15H1bue8f22Vw2oQ== integrity sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==
dependencies: dependencies:
ansi-styles "^3.2.0" ansi-styles "^3.2.0"
astral-regex "^1.0.0" astral-regex "^1.0.0"
@ -6406,6 +6410,15 @@ string-width@^1.0.1:
is-fullwidth-code-point "^2.0.0" is-fullwidth-code-point "^2.0.0"
strip-ansi "^4.0.0" strip-ansi "^4.0.0"
string-width@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.0.0.tgz#5a1690a57cc78211fffd9bf24bbe24d090604eb1"
integrity sha512-rr8CUxBbvOZDUvc5lNIJ+OC1nPVpz+Siw9VBtUjB9b6jZehZLFt0JMCZzShFHIsI8cbhm0EsNIfWJMFV3cu3Ew==
dependencies:
emoji-regex "^7.0.1"
is-fullwidth-code-point "^2.0.0"
strip-ansi "^5.0.0"
string.prototype.padend@^3.0.0: string.prototype.padend@^3.0.0:
version "3.0.0" version "3.0.0"
resolved "https://registry.yarnpkg.com/string.prototype.padend/-/string.prototype.padend-3.0.0.tgz#f3aaef7c1719f170c5eab1c32bf780d96e21f2f0" resolved "https://registry.yarnpkg.com/string.prototype.padend/-/string.prototype.padend-3.0.0.tgz#f3aaef7c1719f170c5eab1c32bf780d96e21f2f0"
@ -6534,15 +6547,15 @@ synchronous-promise@^2.0.5:
resolved "https://registry.yarnpkg.com/synchronous-promise/-/synchronous-promise-2.0.6.tgz#de76e0ea2b3558c1e673942e47e714a930fa64aa" resolved "https://registry.yarnpkg.com/synchronous-promise/-/synchronous-promise-2.0.6.tgz#de76e0ea2b3558c1e673942e47e714a930fa64aa"
integrity sha512-TyOuWLwkmtPL49LHCX1caIwHjRzcVd62+GF6h8W/jHOeZUFHpnd2XJDVuUlaTaLPH1nuu2M69mfHr5XbQJnf/g== integrity sha512-TyOuWLwkmtPL49LHCX1caIwHjRzcVd62+GF6h8W/jHOeZUFHpnd2XJDVuUlaTaLPH1nuu2M69mfHr5XbQJnf/g==
table@^5.0.2: table@^5.2.3:
version "5.1.1" version "5.2.3"
resolved "https://registry.yarnpkg.com/table/-/table-5.1.1.tgz#92030192f1b7b51b6eeab23ed416862e47b70837" resolved "https://registry.yarnpkg.com/table/-/table-5.2.3.tgz#cde0cc6eb06751c009efab27e8c820ca5b67b7f2"
integrity sha512-NUjapYb/qd4PeFW03HnAuOJ7OMcBkJlqeClWxeNlQ0lXGSb52oZXGzkO0/I0ARegQ2eUT1g2VDJH0eUxDRcHmw== integrity sha512-N2RsDAMvDLvYwFcwbPyF3VmVSSkuF+G1e+8inhBLtHpvwXGw4QRPEZhihQNeEN0i1up6/f6ObCJXNdlRG3YVyQ==
dependencies: dependencies:
ajv "^6.6.1" ajv "^6.9.1"
lodash "^4.17.11" lodash "^4.17.11"
slice-ansi "2.0.0" slice-ansi "^2.1.0"
string-width "^2.1.1" string-width "^3.0.0"
tar@^4: tar@^4:
version "4.4.8" version "4.4.8"
@ -7081,10 +7094,10 @@ write-file-atomic@^2.3.0:
imurmurhash "^0.1.4" imurmurhash "^0.1.4"
signal-exit "^3.0.2" signal-exit "^3.0.2"
write@^0.2.1: write@1.0.3:
version "0.2.1" version "1.0.3"
resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" resolved "https://registry.yarnpkg.com/write/-/write-1.0.3.tgz#0800e14523b923a387e415123c865616aae0f5c3"
integrity sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c= integrity sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig==
dependencies: dependencies:
mkdirp "^0.5.1" mkdirp "^0.5.1"