@@ -13,17 +13,17 @@ describe("Profile section", () => {
13
13
const username = faker . internet . userName ( ) ;
14
14
const biography = faker . person . bio ( ) ;
15
15
const isCurrentUser = false ;
16
- const userId = faker . string . nanoid ( ) ;
17
- const onUpdate = jest . fn ( ) ;
16
+ const handleEditProfileOpen = jest . fn ( ) ;
17
+ const handleChangePasswordOpen = jest . fn ( ) ;
18
18
render (
19
19
< ProfileSection
20
20
firstName = { firstName }
21
21
lastName = { lastName }
22
22
username = { username }
23
23
biography = { biography }
24
24
isCurrentUser = { isCurrentUser }
25
- userId = { userId }
26
- onUpdate = { onUpdate }
25
+ handleEditProfileOpen = { handleEditProfileOpen }
26
+ handleChangePasswordOpen = { handleChangePasswordOpen }
27
27
/>
28
28
) ;
29
29
expect ( screen . getByText ( `${ firstName } ${ lastName } ` ) ) . toBeInTheDocument ( ) ;
@@ -35,17 +35,17 @@ describe("Profile section", () => {
35
35
const username = faker . internet . userName ( ) ;
36
36
const biography = faker . person . bio ( ) ;
37
37
const isCurrentUser = false ;
38
- const userId = faker . string . nanoid ( ) ;
39
- const onUpdate = jest . fn ( ) ;
38
+ const handleEditProfileOpen = jest . fn ( ) ;
39
+ const handleChangePasswordOpen = jest . fn ( ) ;
40
40
render (
41
41
< ProfileSection
42
42
firstName = { firstName }
43
43
lastName = { lastName }
44
44
username = { username }
45
45
biography = { biography }
46
46
isCurrentUser = { isCurrentUser }
47
- userId = { userId }
48
- onUpdate = { onUpdate }
47
+ handleEditProfileOpen = { handleEditProfileOpen }
48
+ handleChangePasswordOpen = { handleChangePasswordOpen }
49
49
/>
50
50
) ;
51
51
expect ( screen . getByText ( `@${ username } ` ) ) . toBeInTheDocument ( ) ;
@@ -59,17 +59,17 @@ describe("Profiles that don't belong to the current authenticated user", () => {
59
59
const username = faker . internet . userName ( ) ;
60
60
const biography = faker . person . bio ( ) ;
61
61
const isCurrentUser = false ;
62
- const userId = faker . string . nanoid ( ) ;
63
- const onUpdate = jest . fn ( ) ;
62
+ const handleEditProfileOpen = jest . fn ( ) ;
63
+ const handleChangePasswordOpen = jest . fn ( ) ;
64
64
render (
65
65
< ProfileSection
66
66
firstName = { firstName }
67
67
lastName = { lastName }
68
68
username = { username }
69
69
biography = { biography }
70
70
isCurrentUser = { isCurrentUser }
71
- userId = { userId }
72
- onUpdate = { onUpdate }
71
+ handleEditProfileOpen = { handleEditProfileOpen }
72
+ handleChangePasswordOpen = { handleChangePasswordOpen }
73
73
/>
74
74
) ;
75
75
const editProfileButton = screen . queryByRole ( "button" , {
@@ -84,17 +84,17 @@ describe("Profiles that don't belong to the current authenticated user", () => {
84
84
const username = faker . internet . userName ( ) ;
85
85
const biography = faker . person . bio ( ) ;
86
86
const isCurrentUser = false ;
87
- const userId = faker . string . nanoid ( ) ;
88
- const onUpdate = jest . fn ( ) ;
87
+ const handleEditProfileOpen = jest . fn ( ) ;
88
+ const handleChangePasswordOpen = jest . fn ( ) ;
89
89
render (
90
90
< ProfileSection
91
91
firstName = { firstName }
92
92
lastName = { lastName }
93
93
username = { username }
94
94
biography = { biography }
95
95
isCurrentUser = { isCurrentUser }
96
- userId = { userId }
97
- onUpdate = { onUpdate }
96
+ handleEditProfileOpen = { handleEditProfileOpen }
97
+ handleChangePasswordOpen = { handleChangePasswordOpen }
98
98
/>
99
99
) ;
100
100
const editProfileButton = screen . queryByRole ( "button" , {
@@ -111,17 +111,17 @@ describe("Profiles that belong to the current authenticated user", () => {
111
111
const username = faker . internet . userName ( ) ;
112
112
const biography = faker . person . bio ( ) ;
113
113
const isCurrentUser = true ;
114
- const userId = faker . string . nanoid ( ) ;
115
- const onUpdate = jest . fn ( ) ;
114
+ const handleEditProfileOpen = jest . fn ( ) ;
115
+ const handleChangePasswordOpen = jest . fn ( ) ;
116
116
render (
117
117
< ProfileSection
118
118
firstName = { firstName }
119
119
lastName = { lastName }
120
120
username = { username }
121
121
biography = { biography }
122
122
isCurrentUser = { isCurrentUser }
123
- userId = { userId }
124
- onUpdate = { onUpdate }
123
+ handleEditProfileOpen = { handleEditProfileOpen }
124
+ handleChangePasswordOpen = { handleChangePasswordOpen }
125
125
/>
126
126
) ;
127
127
const editProfileButton = screen . queryByRole ( "button" , {
@@ -136,17 +136,17 @@ describe("Profiles that belong to the current authenticated user", () => {
136
136
const username = faker . internet . userName ( ) ;
137
137
const biography = faker . person . bio ( ) ;
138
138
const isCurrentUser = true ;
139
- const userId = faker . string . nanoid ( ) ;
140
- const onUpdate = jest . fn ( ) ;
139
+ const handleEditProfileOpen = jest . fn ( ) ;
140
+ const handleChangePasswordOpen = jest . fn ( ) ;
141
141
render (
142
142
< ProfileSection
143
143
firstName = { firstName }
144
144
lastName = { lastName }
145
145
username = { username }
146
146
biography = { biography }
147
147
isCurrentUser = { isCurrentUser }
148
- userId = { userId }
149
- onUpdate = { onUpdate }
148
+ handleEditProfileOpen = { handleEditProfileOpen }
149
+ handleChangePasswordOpen = { handleChangePasswordOpen }
150
150
/>
151
151
) ;
152
152
const editProfileButton = screen . queryByRole ( "button" , {
0 commit comments