mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Update test
This commit is contained in:
parent
490ae58499
commit
c3f2262b6b
2 changed files with 20 additions and 20 deletions
|
|
@ -1,14 +1,14 @@
|
|||
import { AuthProvider } from '../routers/auth/auth_types'
|
||||
import { EntityManager } from 'typeorm'
|
||||
import { StatusType } from '../datalayer/user/model'
|
||||
import { EntityManager, ILike } from 'typeorm'
|
||||
import { User } from '../entity/user'
|
||||
import { Profile } from '../entity/profile'
|
||||
import { SignupErrorCode } from '../generated/graphql'
|
||||
import { validateUsername } from '../utils/usernamePolicy'
|
||||
import { Invite } from '../entity/groups/invite'
|
||||
import { GroupMembership } from '../entity/groups/group_membership'
|
||||
import { AppDataSource } from '../server'
|
||||
import { Invite } from '../entity/groups/invite'
|
||||
import { Profile } from '../entity/profile'
|
||||
import { User } from '../entity/user'
|
||||
import { getRepository } from '../entity/utils'
|
||||
import { SignupErrorCode } from '../generated/graphql'
|
||||
import { AuthProvider } from '../routers/auth/auth_types'
|
||||
import { AppDataSource } from '../server'
|
||||
import { validateUsername } from '../utils/usernamePolicy'
|
||||
import { sendConfirmationEmail } from './send_emails'
|
||||
|
||||
export const createUser = async (input: {
|
||||
|
|
|
|||
|
|
@ -1,22 +1,22 @@
|
|||
import { createTestUser, deleteTestUser, updateTestUser } from '../db'
|
||||
import { generateFakeUuid, request } from '../util'
|
||||
import { StatusType } from '../../src/datalayer/user/model'
|
||||
import { getRepository } from '../../src/entity/utils'
|
||||
import { User } from '../../src/entity/user'
|
||||
import { MailDataRequired } from '@sendgrid/helpers/classes/mail'
|
||||
import chai, { expect } from 'chai'
|
||||
import sinon from 'sinon'
|
||||
import * as util from '../../src/utils/sendEmail'
|
||||
import sinonChai from 'sinon-chai'
|
||||
import supertest from 'supertest'
|
||||
import { StatusType } from '../../src/datalayer/user/model'
|
||||
import { searchPages } from '../../src/elastic/pages'
|
||||
import { User } from '../../src/entity/user'
|
||||
import { getRepository } from '../../src/entity/utils'
|
||||
import { AuthProvider } from '../../src/routers/auth/auth_types'
|
||||
import { createPendingUserToken } from '../../src/routers/auth/jwt_helpers'
|
||||
import {
|
||||
comparePassword,
|
||||
generateVerificationToken,
|
||||
hashPassword,
|
||||
} from '../../src/utils/auth'
|
||||
import sinonChai from 'sinon-chai'
|
||||
import chai, { expect } from 'chai'
|
||||
import { searchPages } from '../../src/elastic/pages'
|
||||
import { createPendingUserToken } from '../../src/routers/auth/jwt_helpers'
|
||||
import { AuthProvider } from '../../src/routers/auth/auth_types'
|
||||
import * as util from '../../src/utils/sendEmail'
|
||||
import { createTestUser, deleteTestUser, updateTestUser } from '../db'
|
||||
import { generateFakeUuid, request } from '../util'
|
||||
|
||||
chai.use(sinonChai)
|
||||
|
||||
|
|
@ -178,7 +178,7 @@ describe('auth router', () => {
|
|||
|
||||
context('when email and password are valid', () => {
|
||||
before(() => {
|
||||
email = user.email
|
||||
email = user.email + ' ' // space at the end is intentional
|
||||
password = correctPassword
|
||||
})
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue