Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitbbce1af

Browse files
committed
remove unnecesary tests
1 parent8772cf0 commitbbce1af

File tree

1 file changed

+3
-29
lines changed

1 file changed

+3
-29
lines changed

‎site/src/components/SettingsAccountForm/SettingsAccountForm.test.tsx

Lines changed: 3 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { AccountForm, AccountFormValues } from "./SettingsAccountForm"
77
// only that editable is set to true or false. This is passed from
88
// the call to /authorization done by authXService
99
describe("AccountForm",()=>{
10-
describe("for owners",()=>{
10+
describe("when editable is set to true",()=>{
1111
it("allows updating username",async()=>{
1212
// Given
1313
constmockInitialValues:AccountFormValues={
@@ -33,34 +33,8 @@ describe("AccountForm", () => {
3333
})
3434
})
3535

36-
describe("for user admins",()=>{
37-
it("allows updating username",async()=>{
38-
// Given
39-
constmockInitialValues:AccountFormValues={
40-
username:MockUser2.username,
41-
editable:true,
42-
}
43-
44-
// When
45-
render(
46-
<AccountForm
47-
email={MockUser2.email}
48-
initialValues={mockInitialValues}
49-
isLoading={false}
50-
onSubmit={()=>{
51-
return
52-
}}
53-
/>,
54-
)
55-
56-
// Then
57-
constel=awaitscreen.findByLabelText("Username")
58-
expect(el).toBeEnabled()
59-
})
60-
})
61-
62-
describe("for members",()=>{
63-
it("allows updating username",async()=>{
36+
describe("when editable is set to false",()=>{
37+
it("does not allow updating username",async()=>{
6438
// Given
6539
constmockInitialValues:AccountFormValues={
6640
username:MockUser2.username,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp