Robert Schäfer
5856e74b39
Fix yarn run db:reset
2019-02-22 14:13:03 +01:00
Matt Rider
4a43583c6b
Create abusive-user to report, PR review suggestions
2019-02-21 22:43:51 -03:00
Matt Rider
40c210a0ce
Start unit testing report feature
2019-02-21 21:13:30 -03:00
Robert Schäfer
eda2ea34fc
Incorporate @appinteractive's feedback
...
@appinteractive can we merge this soon?
2019-02-21 20:03:22 +01:00
Robert Schäfer
132dba04dd
Refactor tests with the new factory API
2019-02-21 16:06:13 +01:00
Robert Schäfer
aa07a2a616
Refactor Id Middleware
...
I found a way to cleanly request additional attributes in our
middleware. We can use this pattern if we e.g. require the author of
posts and comments to check if the user is the author and therefore
authorized to update or delete the post.
CC @mattwr18 @appinteractive @tirokk
2019-02-21 10:50:41 +01:00
Robert Schäfer
98983bb575
Fix lint
2019-02-21 10:32:07 +01:00
Robert Schäfer
91a13593dc
Provide a better interface for factories
...
You can now run graphql mutations *from the point of view* of a user.
@mattwr18 @Tirokk Do you have a better idea how to name the factory
builder?
2019-02-21 02:17:07 +01:00
Robert Schäfer
d4a999ee91
Configure factories#cleanDatabase easier
2019-02-21 00:27:26 +01:00
Robert Schäfer
4a1e06402a
Fix lint
2019-02-20 15:26:49 +01:00
Robert Schäfer
7abc1583dc
Implement + test unique slugs for user
...
I put the relevant line on categories and organizations too, but I
didn't test it separately. I could have tested it but found it
unnecessary repeating
2019-02-20 14:03:36 +01:00
Robert Schäfer
bfc5603fa8
All tests are passing!
2019-02-20 12:56:57 +01:00
Robert Schäfer
a61362b269
Fix slugify unit test with async mock functions
2019-02-20 11:48:06 +01:00
Robert Schäfer
ba26c0e188
Seed reported comments, posts and users
2019-02-20 11:36:50 +01:00
Robert Schäfer
3532b473ee
Choose another slug is green
2019-02-20 01:30:32 +01:00
Robert Schäfer
7a70b9ece4
Implement authorization on Post mutations
2019-02-20 01:01:41 +01:00
Robert Schäfer
f1dd52f579
Expose yet another bug in the authorization
...
Cannot read property id of null
CC @appinteractive
2019-02-20 01:01:41 +01:00
Robert Schäfer
9c4e599ff1
Separate middleware for ids
2019-02-19 23:39:39 +01:00
Robert Schäfer
30bb54c6fa
Fix slugify test
2019-02-19 23:00:59 +01:00
Robert Schäfer
e6a996e0dd
Harden permissions spec
...
If we expect an error to be thrown, the test should fail if no error was
raised.
2019-02-19 22:55:23 +01:00
Robert Schäfer
f703164f1d
Expose cannot read property id of null error
...
CC @appinteractive
2019-02-19 13:36:02 +01:00
Robert Schäfer
8a7435ebb7
Clean up seed-db.js
2019-02-19 01:51:04 +01:00
Robert Schäfer
4488cc9864
Seed comments
2019-02-19 01:43:11 +01:00
Robert Schäfer
1afcb4b0c9
Seed organizations
2019-02-19 01:17:38 +01:00
Robert Schäfer
a981181e94
Seed user shouts
2019-02-19 01:04:05 +01:00
Robert Schäfer
62d450ef68
Remove boilerplate code with method relate()
2019-02-19 00:54:21 +01:00
Robert Schäfer
eb22555797
Change API: create/relate
...
Separating the relations from mere properties removes boilerplate code.
2019-02-19 00:17:06 +01:00
Robert Schäfer
e51817c849
Seed follow relations between users
2019-02-18 23:49:54 +01:00
Robert Schäfer
f9083c8d4b
Remove obsolete legacy seeds
2019-02-18 23:39:06 +01:00
Robert Schäfer
df9b4b9b8b
Seed blacklisted relationships between users
2019-02-18 23:37:44 +01:00
Robert Schäfer
dd8fe73e6d
Create more posts, connect users with badges
2019-02-18 23:26:46 +01:00
Robert Schäfer
aa2ce1f639
Remove redundancy in database cleaner
2019-02-18 23:02:52 +01:00
Robert Schäfer
924a57a7ca
Seed badges and tags
2019-02-18 22:48:22 +01:00
Robert Schäfer
437e8589f8
Categories posts in seeding
2019-02-18 18:08:45 +01:00
Robert Schäfer
9dba02cf09
Create posts by multiple authors
2019-02-18 17:23:12 +01:00
Grzegorz Leoniec
cbbd33301f
Improved search query
2019-02-18 16:57:17 +01:00
Robert Schäfer
1734554a88
Fix seeds without the use of neode
...
@appinteractive ping
2019-02-18 15:35:45 +01:00
Robert Schäfer
f024bd3821
Remove redundancy
2019-02-18 13:25:11 +01:00
Robert Schäfer
f17242b824
Transfer relevant changes from branch neode
2019-02-18 12:57:07 +01:00
Grzegorz Leoniec
da804e26ae
Fix search
2019-02-17 17:32:14 +01:00
Robert Schäfer
cadb309ecf
Fix lint
2019-02-15 02:05:08 +01:00
Robert Schäfer
6b5d329759
Implement test for search
...
@appinteractive could you have a look if sanitization of search queries
work? I created a test and I see "unterminated string" exceptions. This
is not what we want! All user input should be escaped.
2019-02-15 01:46:33 +01:00
Robert Schäfer
2715f940b5
Sketch a test
2019-02-15 00:50:37 +01:00
Robert Schäfer
56936c4038
Setup a routine how to create indices initially
...
In order to create the indices programmatically we need to change the
default password for security concerns. To create the user we need to
start the neo4j database. So I decided to provide a bash script that
let us do it once the container are started.
In production we must change the NEO4J_PASSWORD.
2019-02-14 16:15:58 +01:00
Grzegorz Leoniec
4f8f0debbe
Added findPost query
2019-02-13 16:02:25 +01:00
Grzegorz Leoniec
b515da66f9
Merge branch 'master' into editor
2019-02-13 12:55:08 +01:00
Grzegorz Leoniec
b70eea8919
Fixed eslint
2019-02-08 09:49:22 +01:00
Grzegorz Leoniec
ae9ebcc3ab
Upgraded graphql from 0.13.0 to 14.1.1
2019-02-07 15:36:07 +01:00
Grzegorz Leoniec
2f2bc5e507
Improved link cleaning
2019-02-07 08:46:34 +01:00
Grzegorz Leoniec
ad2bba586e
Fixed link target
2019-02-06 17:20:38 +01:00