diff --git a/components/card/Card.vue b/components/card/Card.vue
index 0149ca303..3eda11840 100644
--- a/components/card/Card.vue
+++ b/components/card/Card.vue
@@ -3,7 +3,15 @@
:class="classes"
class="mdc-card"
>
-
+
+
+
+
{
expect(w.classes()).toContain('mdc-card__action--icon')
})
})
+
+ it('should render with primary action', () => {
+ let wrapper = mount(Card, {
+ slots: {
+ default: [CardMedia]
+ },
+ propsData: {
+ primaryAction: true
+ }
+ })
+ expect(wrapper).toMatchSnapshot()
+
+ let primaryAction = wrapper.find('.mdc-card__primary-action')
+ expect(primaryAction.exists()).toBe(true)
+ expect(primaryAction.find('.mdc-card__media').exists()).toBe(true)
+ })
})
describe('CardPrimaryAction', () => {
diff --git a/components/card/__test__/__snapshots__/Card.spec.js.snap b/components/card/__test__/__snapshots__/Card.spec.js.snap
index 76500787b..d8dd99ae6 100644
--- a/components/card/__test__/__snapshots__/Card.spec.js.snap
+++ b/components/card/__test__/__snapshots__/Card.spec.js.snap
@@ -67,4 +67,15 @@ exports[`Card should render with no prop 1`] = `
`;
+exports[`Card should render with primary action 1`] = `
+
+`;
+
exports[`CardPrimaryAction should render with no prop 1`] = ``;