You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Looks kind of similar โฆ
Can it be that this is related to a bug in Neode?
Additional Information
Can it be that the data base in GitHub Actions has no constraints while testing?
Locally I get this output if there are no constraints:
Summary of all failing tests
FAIL src/middleware/slugifyMiddleware.spec.js (14.663s)
โ slugifyMiddleware โบ CreatePost โบ if slug exists โบ but if the client specifies a slug โบ rejects CreatePost
Error: expect(received).resolves.toMatchObject(expected)
- Expected - 5
+ Received + 1
Object {
- "errors": Array [
- Object {
- "message": "Post with this slug already exists!",
- },
- ],
+ "errors": undefined,
}
Probably your database has no unique constraints!
To see all constraints go to http://localhost:7474/browser/ and
paste the following:
```
CALL db.constraints();
```
Learn how to setup the database here:
https://docs.human-connection.org/human-connection/backend#database-indices-and-constraints
149 | done()
150 | } catch (error) {
> 151 | throw new Error(`
| ^
152 | ${error}
153 |
154 | Probably your database has no unique constraints!
at Object.<anonymous> (src/middleware/slugifyMiddleware.spec.js:151:19)
โ slugifyMiddleware โบ SignupVerification โบ given a user has signed up with their email address โบ if slug exists โบ but if the client specifies a slug โบ rejects SignupVerification (on FAIL Neo4j constraints may not defined in database)
expect(received).resolves.toMatchObject(expected)
- Expected - 5
+ Received + 1
Object {
- "errors": Array [
- Object {
- "message": "User with this slug already exists!",
- },
- ],
+ "errors": undefined,
}
264 | variables,
265 | }),
> 266 | ).resolves.toMatchObject({
| ^
267 | errors: [
268 | {
269 | message: 'User with this slug already exists!',
at Object.toMatchObject (node_modules/expect/build/index.js:234:20)
at Object.<anonymous> (src/middleware/slugifyMiddleware.spec.js:266:24)
FAIL src/schema/resolvers/emails.spec.js
โ VerifyEmailAddress โบ authenticated โบ given a `UnverifiedEmailAddress` โบ given valid nonce for `UnverifiedEmailAddress` node โบ and the `UnverifiedEmailAddress` belongs to the authenticated user โบ Edge case: In the meantime someone created an `EmailAddress` node with the given email โบ throws UserInputError because of unique constraints
expect(received).resolves.toMatchObject(expected)
- Expected - 5
+ Received + 5
Object {
"data": Object {
- "VerifyEmailAddress": null,
+ "VerifyEmailAddress": Object {
+ "createdAt": "2021-10-20T10:59:51.993Z",
+ "email": "[email protected]",
+ "verifiedAt": "2021-10-20T10:59:52.006Z",
},
- "errors": Array [
- Object {
- "message": "A user account with this email already exists.",
},
- ],
+ "errors": undefined,
}
293 |
294 | it('throws UserInputError because of unique constraints', async () => {
> 295 | await expect(mutate({ mutation, variables })).resolves.toMatchObject({
| ^
296 | data: { VerifyEmailAddress: null },
297 | errors: [{ message: 'A user account with this email already exists.' }],
298 | })
at Object.toMatchObject (node_modules/expect/build/index.js:234:20)
at Object.<anonymous> (src/schema/resolvers/emails.spec.js:295:70)
FAIL src/models/User.spec.js
โ slug โบ must be unique
Error: expect(received).rejects.toThrow()
Received promise resolved instead of rejected
Resolved to value: {"_deleted": false, "_eager": Map {"emoted" => [Collection]}, "_identity": {"high": 0, "low": 6543}, "_labels": ["User"], "_model": {"_hidden": [Array], "_indexed": [Array], "_labels": [Array], "_name": "User", "_neode": [Neode], "_primary_key": "id", "_properties": [Map], "_readonly": [Array], "_relationships": [Map], "_schema": [Object], "_unique": [Array]}, "_neode": {"_enterprise": false, "driver": [Driver], "factory": [Factory], "models": [ModelMap], "schema": [Schema]}, "_properties": Map {"id" => "9888c23b-9e20-4665-8fe7-4e2df8615d49", "slug" => "matt", "deleted" => false, "disabled" => false, "role" => "user", "createdAt" => "2021-10-20T10:59:52.671Z", "updatedAt" => "2021-10-20T10:59:52.671Z", "allowEmbedIframes" => false, "showShoutsPublicly" => false, "sendNotificationEmails" => true}}
Probably your database has no unique constraints!
To see all constraints go to http://localhost:7474/browser/ and
paste the following:
```
CALL db.constraints();
```
Learn how to setup the database here:
https://docs.human-connection.org/human-connection/backend#database-indices-and-constraints
44 | done()
45 | } catch (error) {
> 46 | throw new Error(`
| ^
47 | ${error}
48 |
49 | Probably your database has no unique constraints!
at Object.<anonymous> (src/models/User.spec.js:46:13)
Test Suites: 3 failed, 42 passed, 45 total
Tests: 4 failed, 1 skipped, 1 todo, 479 passed, 485 total
Snapshots: 0 total
Time: 252.582s, estimated 294s
Ran all test suites.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Uh oh!
There was an error while loading. Please reload this page.
๐ Bug Report
!!! duplicate of #4341
Still some more often appearing flaky tests:
Looks kind of similar โฆ
Can it be that this is related to a bug in Neode?
Additional Information
Can it be that the data base in GitHub Actions has no constraints while testing?
Locally I get this output if there are no constraints:
Additional Informations
Some flaky tests may be related to:
The text was updated successfully, but these errors were encountered: