优化
This commit is contained in:
@@ -100,17 +100,14 @@ describe('FeeItemsView public master data and access', () => {
|
||||
})
|
||||
|
||||
it('keeps all three row actions visible without a premature more menu', () => {
|
||||
expect(source).toContain('size="small" plain type="primary"')
|
||||
expect(source).toContain('size="small"\n plain\n :type=')
|
||||
expect(source).toContain('size="small" plain type="danger"')
|
||||
expect(source).toContain('<Pencil :size="15" />编辑')
|
||||
expect(source).toContain('<Power :size="15" />')
|
||||
expect(source).toContain('<Trash2 :size="15" />删除')
|
||||
expect(source).not.toContain('MoreHorizontal')
|
||||
expect(source).not.toContain("access.can('firstleg:fee-item:edit')\" link")
|
||||
expect(source).not.toContain("access.can('firstleg:fee-item:delete')\" link")
|
||||
const actions = source.slice(source.indexOf('<template #actions='), source.indexOf('</template>', source.indexOf('<template #actions=')))
|
||||
expect(actions.match(/class="density-action"/g)).toHaveLength(3)
|
||||
expect(actions).toContain('>编辑</el-button>')
|
||||
expect(actions).toContain('>删除</el-button>')
|
||||
expect(actions).toContain('data-tone="danger"')
|
||||
expect(actions).toContain(':data-tone=')
|
||||
expect(actions).not.toMatch(/<(?:el-dropdown|Pencil|Power|Eye|Trash2|Download|CircleX)\b/)
|
||||
})
|
||||
|
||||
it('keeps the prototype table treatment and mobile form fallback without inventing a pricing mode', () => {
|
||||
expect(source).toContain(':page-sizes="[20, 50, 100]"\n border\n stripe')
|
||||
expect(source).toContain('@media (max-width: 720px)')
|
||||
|
||||
Reference in New Issue
Block a user