test(NavBar): update test cases
This commit is contained in:
@@ -19,7 +19,7 @@ exports[`should change icon class prefix when using icon-prefix prop 1`] = `
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`should render default slot and match snapshot 1`] = `
|
||||
exports[`should render default slot correctly 1`] = `
|
||||
<div class="van-cell">
|
||||
<!---->
|
||||
<!---->
|
||||
@@ -29,7 +29,7 @@ exports[`should render default slot and match snapshot 1`] = `
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`should render extra slot and match snapshot 1`] = `
|
||||
exports[`should render extra slot correctly 1`] = `
|
||||
<div class="van-cell">
|
||||
<!---->
|
||||
<!---->
|
||||
@@ -37,7 +37,7 @@ exports[`should render extra slot and match snapshot 1`] = `
|
||||
<!---->Custom Extra</div>
|
||||
`;
|
||||
|
||||
exports[`should render icon slot and match snapshot 1`] = `
|
||||
exports[`should render icon slot correctly 1`] = `
|
||||
<div class="van-cell">Custom Icon
|
||||
<!---->
|
||||
<!---->
|
||||
@@ -46,7 +46,7 @@ exports[`should render icon slot and match snapshot 1`] = `
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`should render label slot and match snapshot 1`] = `
|
||||
exports[`should render label slot correctly 1`] = `
|
||||
<div class="van-cell">
|
||||
<!---->
|
||||
<div class="van-cell__title"><span>Title</span>
|
||||
@@ -58,7 +58,7 @@ exports[`should render label slot and match snapshot 1`] = `
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`should render title slot and match snapshot 1`] = `
|
||||
exports[`should render title slot correctly 1`] = `
|
||||
<div class="van-cell">
|
||||
<!---->
|
||||
<div class="van-cell__title">Custom Title
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import Cell from '..';
|
||||
import { mount } from '@vue/test-utils';
|
||||
|
||||
test('should render default slot and match snapshot', () => {
|
||||
test('should render default slot correctly', () => {
|
||||
const wrapper = mount(Cell, {
|
||||
slots: {
|
||||
default: () => 'Custom Default',
|
||||
@@ -10,7 +10,7 @@ test('should render default slot and match snapshot', () => {
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('should render title slot and match snapshot', () => {
|
||||
test('should render title slot correctly', () => {
|
||||
const wrapper = mount(Cell, {
|
||||
slots: {
|
||||
title: () => 'Custom Title',
|
||||
@@ -19,7 +19,7 @@ test('should render title slot and match snapshot', () => {
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('should render label slot and match snapshot', () => {
|
||||
test('should render label slot correctly', () => {
|
||||
const wrapper = mount(Cell, {
|
||||
props: {
|
||||
title: 'Title',
|
||||
@@ -31,7 +31,7 @@ test('should render label slot and match snapshot', () => {
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('should render icon slot and match snapshot', () => {
|
||||
test('should render icon slot correctly', () => {
|
||||
const wrapper = mount(Cell, {
|
||||
slots: {
|
||||
icon: () => 'Custom Icon',
|
||||
@@ -40,7 +40,7 @@ test('should render icon slot and match snapshot', () => {
|
||||
expect(wrapper.html()).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('should render extra slot and match snapshot', () => {
|
||||
test('should render extra slot correctly', () => {
|
||||
const wrapper = mount(Cell, {
|
||||
slots: {
|
||||
extra: () => 'Custom Extra',
|
||||
|
||||
Reference in New Issue
Block a user