test(Checkbox): update test cases

This commit is contained in:
chenjiahan
2020-11-27 17:34:43 +08:00
parent f8234a5b5f
commit 999bdccdbb
4 changed files with 125 additions and 238 deletions
@@ -1,41 +0,0 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`checked-color prop 1`] = `
<div class="van-checkbox-group">
<div role="checkbox" tabindex="0" aria-checked="true" class="van-checkbox">
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"><i class="van-icon van-icon-success" style="border-color: black; background-color: black;">
<!----></i></div><span class="van-checkbox__label">label</span>
</div>
<div role="checkbox" tabindex="0" aria-checked="true" class="van-checkbox">
<div class="van-checkbox__icon van-checkbox__icon--round van-checkbox__icon--checked"><i class="van-icon van-icon-success" style="border-color: white; background-color: white;">
<!----></i></div><span class="van-checkbox__label">label</span>
</div>
</div>
`;
exports[`icon-size prop 1`] = `
<div class="van-checkbox-group">
<div role="checkbox" tabindex="0" aria-checked="false" class="van-checkbox">
<div class="van-checkbox__icon van-checkbox__icon--round" style="font-size: 10rem;"><i class="van-icon van-icon-success">
<!----></i></div><span class="van-checkbox__label">label</span>
</div>
<div role="checkbox" tabindex="0" aria-checked="false" class="van-checkbox">
<div class="van-checkbox__icon van-checkbox__icon--round" style="font-size: 5rem;"><i class="van-icon van-icon-success">
<!----></i></div><span class="van-checkbox__label">label</span>
</div>
</div>
`;
exports[`label disabled 1`] = `
<div role="checkbox" tabindex="0" aria-checked="undefined" class="van-checkbox van-checkbox--label-disabled">
<div class="van-checkbox__icon van-checkbox__icon--round"><i class="van-icon van-icon-success">
<!----></i></div><span class="van-checkbox__label">Label</span>
</div>
`;
exports[`label-position prop 1`] = `
<div role="checkbox" tabindex="0" aria-checked="undefined" class="van-checkbox"><span class="van-checkbox__label van-checkbox__label--left">Label</span>
<div class="van-checkbox__icon van-checkbox__icon--round"><i class="van-icon van-icon-success">
<!----></i></div>
</div>
`;
@@ -0,0 +1,16 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`should adjust label position when using label-position prop 1`] = `
<div role="checkbox"
class="van-checkbox"
tabindex="0"
>
<span class="van-checkbox__label van-checkbox__label--left">
Label
</span>
<div class="van-checkbox__icon van-checkbox__icon--round">
<i class="van-badge__wrapper van-icon van-icon-success">
</i>
</div>
</div>
`;