Skip to content

Commit e7a9305

Browse files
authored
Merge pull request #265 from waic/add-test-case-0037-01
WAIC-TEST-0037-01 / (関連する達成方法なし): required属性による必須項目の特定
2 parents 4c985c6 + f85c7a0 commit e7a9305

File tree

2 files changed

+275
-0
lines changed

2 files changed

+275
-0
lines changed

WAIC-CODE/WAIC-CODE-0037-01.html

Lines changed: 118 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
<!DOCTYPE html>
2+
3+
<html lang="ja">
4+
<head>
5+
<meta charset="utf-8">
6+
<title>WAIC-CODE-0037-01</title>
7+
<meta name="copyright" content="This document is licensed under a Creative Commons 4.0">
8+
<link rel="license" href="https://creativecommons.org/licenses/by/4.0/">
9+
<meta name="author" content="ウェブアクセシビリティ基盤委員会(WAIC)">
10+
</head>
11+
12+
<body>
13+
<h1>required属性による必須項目の特定</h1>
14+
15+
<h2>required属性が設定されている</h2>
16+
<form action="#" method="post" id="login1" onsubmit="return errorCheck1()">
17+
<p>注:[*]は必須項目を示します。</p>
18+
<p>
19+
<label for="usrname1">ログインネーム[*]</label>
20+
<input type="text" name="usrname1" id="usrname1" required />
21+
</p>
22+
<p>
23+
<label for="pwd1">パスワード[*]</label>
24+
<input type="password" name="pwd1" id="pwd1" size="12" required />
25+
</p>
26+
<p>
27+
<label for="os_pc1">利用しているOS(PC)[*]</label>
28+
<select id="os_pc1" name="os_pc1" required>
29+
<option value="Windows">Windows</option>
30+
<option value="macOS">macOS</option>
31+
</select>
32+
</p>
33+
<p>
34+
<label for="os_mobile1">利用しているOS(モバイル)[*]</label>
35+
<select id="os_mobile1" name="os_mobile1" required>
36+
<option value="">選択してください</option>
37+
<option value="iOS">iOS</option>
38+
<option value="Android">Android</option>
39+
</select>
40+
</p>
41+
<fieldset>
42+
<legend>スクリーンリーダーの利用状況</legend>
43+
<input type="radio" id="yes1" name="sr1" value="1" required />
44+
<label for="yes1">利用している[*]</label>
45+
<input type="radio" id="no1" name="sr1" value="2" required />
46+
<label for="no1">利用していない[*]</label>
47+
</fieldset>
48+
<p>利用しているスクリーンリーダー</p>
49+
<div>
50+
<input type="checkbox" id="pctk1" name="pctk1" required />
51+
<label for="pctk1">PC-Talker[*]</label>
52+
</div>
53+
<div>
54+
<input type="checkbox" id="nvda1" name="nvda1" required />
55+
<label for="nvda1">NVDA[*]</label>
56+
</div>
57+
<p>
58+
<label for="other1">その他コメント[*]</label>
59+
<textarea id="other1" name="other1" required></textarea>
60+
</p>
61+
<p>
62+
<input type="submit" value="次へ" id="next_btn1" name="next_btn1" />
63+
</p>
64+
</form>
65+
66+
<h2>required属性が設定されていない</h2>
67+
<form action="#" method="post" id="login2" onsubmit="return errorCheck1()">
68+
<p>注:[*]は必須項目を示します。</p>
69+
<p>
70+
<label for="usrname2">ログインネーム[*]</label>
71+
<input type="text" name="usrname2" id="usrname2">
72+
</p>
73+
<p>
74+
<label for="pwd2">パスワード[*]</label>
75+
<input type="password" name="pwd2" id="pwd2" size="12">
76+
</p>
77+
<p>
78+
<label for="os_pc2">利用しているOS(PC)[*]</label>
79+
<select id="os_pc2" name="os_pc2">
80+
<option value="Windows">Windows</option>
81+
<option value="macOS">macOS</option>
82+
</select>
83+
</p>
84+
<p>
85+
<label for="os_mobile2">利用しているOS(モバイル)[*]</label>
86+
<select id="os_mobile2" name="os_mobile2">
87+
<option value="">選択してください</option>
88+
<option value="iOS">iOS</option>
89+
<option value="Android">Android</option>
90+
</select>
91+
</p>
92+
<fieldset>
93+
<legend>スクリーンリーダーの利用状況</legend>
94+
<input type="radio" id="yes2" name="sr2" value="1">
95+
<label for="yes2">利用している[*]</label>
96+
<input type="radio" id="no2" name="sr2" value="2">
97+
<label for="no2">利用していない[*]</label>
98+
</fieldset>
99+
<p>利用しているスクリーンリーダー</p>
100+
<div>
101+
<input type="checkbox" id="pctk2" name="pctk2">
102+
<label for="pctk2">PC-Talker[*]</label>
103+
</div>
104+
<div>
105+
<input type="checkbox" id="nvda2" name="nvda2">
106+
<label for="nvda2">NVDA[*]</label>
107+
</div>
108+
<p>
109+
<label for="other2">その他コメント[*]</label>
110+
<textarea id="other2" name="other2"></textarea>
111+
</p>
112+
<p>
113+
<input type="submit" value="次へ" id="next_btn2" name="next_btn2" />
114+
</p>
115+
</form>
116+
117+
</body>
118+
</html>
Lines changed: 157 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,157 @@
1+
# テスト ID
2+
3+
WAIC-TEST-0037-01
4+
5+
# テストのタイトル
6+
7+
required 属性による必須項目の特定(input要素、select要素、textarea要素)
8+
9+
# テストの目的
10+
11+
required属性が設定された要素にフォーカスを移動した際、支援技術に必須であることが伝わることを確認する
12+
13+
# テストの対象となる達成基準 (複数)
14+
15+
1.3.1, 3.3.3
16+
17+
# 関連する達成方法 (複数)
18+
19+
なし
20+
21+
# テストコード (テストファイルへのリンク)
22+
23+
[WAIC-CODE-0037-01](https://waic.github.io/as_test/WAIC-CODE/WAIC-CODE-0037-01.html)
24+
25+
# テストコードのソース (抜粋)
26+
27+
```html
28+
<h2>required属性が設定されている</h2>
29+
<form action="#" method="post" id="login1" onsubmit="return errorCheck1()">
30+
<p>注:[*]は必須項目を示します。</p>
31+
<p>
32+
<label for="usrname1">ログインネーム[*]</label>
33+
<input type="text" name="usrname1" id="usrname1" required />
34+
</p>
35+
<p>
36+
<label for="pwd1">パスワード[*]</label>
37+
<input type="password" name="pwd1" id="pwd1" size="12" required />
38+
</p>
39+
<p>
40+
<label for="os_pc1">利用しているOS(PC)[*]</label>
41+
<select id="os_pc1" name="os_pc1" required>
42+
<option value="Windows">Windows</option>
43+
<option value="macOS">macOS</option>
44+
</select>
45+
</p>
46+
<p>
47+
<label for="os_mobile1">利用しているOS(モバイル)[*]</label>
48+
<select id="os_mobile1" name="os_mobile1" required>
49+
<option value="">選択してください</option>
50+
<option value="iOS">iOS</option>
51+
<option value="Android">Android</option>
52+
</select>
53+
</p>
54+
<fieldset>
55+
<legend>スクリーンリーダーの利用状況</legend>
56+
<input type="radio" id="yes1" name="sr1" value="1" required />
57+
<label for="yes1">利用している[*]</label>
58+
<input type="radio" id="no1" name="sr1" value="2" required />
59+
<label for="no1">利用していない[*]</label>
60+
</fieldset>
61+
<p>利用しているスクリーンリーダー</p>
62+
<div>
63+
<input type="checkbox" id="pctk1" name="pctk1" required />
64+
<label for="pctk1">PC-Talker[*]</label>
65+
</div>
66+
<div>
67+
<input type="checkbox" id="nvda1" name="nvda1" required />
68+
<label for="nvda1">NVDA[*]</label>
69+
</div>
70+
<p>
71+
<label for="other1">その他コメント[*]</label>
72+
<textarea id="other1" name="other1" required></textarea>
73+
</p>
74+
<p>
75+
<input type="submit" value="次へ" id="next_btn1" name="next_btn1" />
76+
</p>
77+
</form>
78+
79+
<h2>required属性が設定されていない</h2>
80+
<form action="#" method="post" id="login2" onsubmit="return errorCheck1()">
81+
<p>注:[*]は必須項目を示します。</p>
82+
<p>
83+
<label for="usrname2">ログインネーム[*]</label>
84+
<input type="text" name="usrname2" id="usrname2">
85+
</p>
86+
<p>
87+
<label for="pwd2">パスワード[*]</label>
88+
<input type="password" name="pwd2" id="pwd2" size="12">
89+
</p>
90+
<p>
91+
<label for="os_pc2">利用しているOS(PC)[*]</label>
92+
<select id="os_pc2" name="os_pc2">
93+
<option value="Windows">Windows</option>
94+
<option value="macOS">macOS</option>
95+
</select>
96+
</p>
97+
<p>
98+
<label for="os_mobile2">利用しているOS(モバイル)[*]</label>
99+
<select id="os_mobile2" name="os_mobile2">
100+
<option value="">選択してください</option>
101+
<option value="iOS">iOS</option>
102+
<option value="Android">Android</option>
103+
</select>
104+
</p>
105+
<fieldset>
106+
<legend>スクリーンリーダーの利用状況</legend>
107+
<input type="radio" id="yes2" name="sr2" value="1">
108+
<label for="yes2">利用している[*]</label>
109+
<input type="radio" id="no2" name="sr2" value="2">
110+
<label for="no2">利用していない[*]</label>
111+
</fieldset>
112+
<p>利用しているスクリーンリーダー</p>
113+
<div>
114+
<input type="checkbox" id="pctk2" name="pctk2">
115+
<label for="pctk2">PC-Talker[*]</label>
116+
</div>
117+
<div>
118+
<input type="checkbox" id="nvda2" name="nvda2">
119+
<label for="nvda2">NVDA[*]</label>
120+
</div>
121+
<p>
122+
<label for="other2">その他コメント[*]</label>
123+
<textarea id="other2" name="other2"></textarea>
124+
</p>
125+
<p>
126+
<input type="submit" value="次へ" id="next_btn2" name="next_btn2" />
127+
</p>
128+
</form>
129+
```
130+
131+
# テスト手順 (視覚閲覧環境)
132+
133+
テスト不要
134+
135+
# 期待される結果 (視覚閲覧環境)
136+
137+
なし
138+
139+
# テスト実施時の注意点 (視覚閲覧環境)
140+
141+
なし
142+
143+
# テスト手順 (音声閲覧環境)
144+
145+
テストファイルを操作し、結果を確認
146+
147+
# 期待される結果 (音声閲覧環境)
148+
149+
required属性が設定された要素にフォーカスを移動した際、支援技術に必須であることが伝わる
150+
151+
# テスト実施時の注意点 (音声閲覧環境)
152+
153+
なし
154+
155+
# 関連する要素や属性
156+
157+
required 属性が指定されているinput 要素、select 要素、textarea 要素

0 commit comments

Comments
 (0)