File tree Expand file tree Collapse file tree
test/integration-tests/user Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,40 +4,10 @@ const chai = require('chai')
44chai . use ( require ( 'chai-http' ) )
55
66const expect = chai . expect
7- const { v4 : uuidv4 } = require ( 'uuid' )
87
98const constants = require ( '../constants.js' )
109const app = require ( '../../../src/index.js' )
1110
12- async function createRegistryUserForUpdateTest ( orgShortName ) {
13- const username = `${ uuidv4 ( ) } @update-user.test`
14- await chai . request ( app )
15- . post ( `/api/registry/org/${ orgShortName } /user` )
16- . set ( constants . headers )
17- . send ( {
18- username,
19- name : {
20- first : 'Update' ,
21- last : 'User'
22- } ,
23- status : 'active'
24- } )
25- . then ( ( res ) => {
26- expect ( res ) . to . have . status ( 200 )
27- } )
28-
29- let user
30- await chai . request ( app )
31- . get ( `/api/registry/org/${ orgShortName } /user/${ username } ` )
32- . set ( constants . headers )
33- . then ( ( res ) => {
34- expect ( res ) . to . have . status ( 200 )
35- user = res . body
36- } )
37-
38- return user
39- }
40-
4111describe ( 'Testing Edit user endpoint' , ( ) => {
4212 context ( 'Positive Tests' , ( ) => {
4313 it ( 'Should correctly remove an admin from the original organization admins array when migrated to a new organization' , async ( ) => {
You can’t perform that action at this time.
0 commit comments