Commit 370fac6a authored by Tom Quirk's avatar Tom Quirk

Group design item_spec tests by presence of notes

In an effort to improve readability of this test
parent 6732ec11
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`Design management list item component hides comment count 1`] = `
exports[`Design management list item component with no notes hides comment count 1`] = `
<router-link-stub
class="card cursor-pointer text-plain js-design-list-item design-list-item"
to="[object Object]"
......@@ -49,7 +49,7 @@ exports[`Design management list item component hides comment count 1`] = `
</router-link-stub>
`;
exports[`Design management list item component renders item with correct status icon for creation event 1`] = `
exports[`Design management list item component with no notes renders item with correct status icon for creation event 1`] = `
<router-link-stub
class="card cursor-pointer text-plain js-design-list-item design-list-item"
to="[object Object]"
......@@ -111,7 +111,7 @@ exports[`Design management list item component renders item with correct status
</router-link-stub>
`;
exports[`Design management list item component renders item with correct status icon for deletion event 1`] = `
exports[`Design management list item component with no notes renders item with correct status icon for deletion event 1`] = `
<router-link-stub
class="card cursor-pointer text-plain js-design-list-item design-list-item"
to="[object Object]"
......@@ -173,7 +173,7 @@ exports[`Design management list item component renders item with correct status
</router-link-stub>
`;
exports[`Design management list item component renders item with correct status icon for modification event 1`] = `
exports[`Design management list item component with no notes renders item with correct status icon for modification event 1`] = `
<router-link-stub
class="card cursor-pointer text-plain js-design-list-item design-list-item"
to="[object Object]"
......@@ -235,7 +235,7 @@ exports[`Design management list item component renders item with correct status
</router-link-stub>
`;
exports[`Design management list item component renders item with multiple comments 1`] = `
exports[`Design management list item component with notes renders item with multiple comments 1`] = `
<router-link-stub
class="card cursor-pointer text-plain js-design-list-item design-list-item"
to="[object Object]"
......@@ -301,7 +301,7 @@ exports[`Design management list item component renders item with multiple commen
</router-link-stub>
`;
exports[`Design management list item component renders item with no status icon for none event 1`] = `
exports[`Design management list item component with no notes renders item with no status icon for none event 1`] = `
<router-link-stub
class="card cursor-pointer text-plain js-design-list-item design-list-item"
to="[object Object]"
......@@ -350,7 +350,7 @@ exports[`Design management list item component renders item with no status icon
</router-link-stub>
`;
exports[`Design management list item component renders item with single comment 1`] = `
exports[`Design management list item component with notes renders item with single comment 1`] = `
<router-link-stub
class="card cursor-pointer text-plain js-design-list-item design-list-item"
to="[object Object]"
......@@ -416,7 +416,7 @@ exports[`Design management list item component renders item with single comment
</router-link-stub>
`;
exports[`Design management list item component renders loading spinner when no image prop present 1`] = `
exports[`Design management list item component with no notes renders loading spinner when no image prop present 1`] = `
<router-link-stub
class="card cursor-pointer text-plain js-design-list-item design-list-item"
to="[object Object]"
......
......@@ -41,6 +41,7 @@ describe('Design management list item component', () => {
wrapper.destroy();
});
describe('with notes', () => {
it('renders item with single comment', () => {
createComponent();
......@@ -52,7 +53,9 @@ describe('Design management list item component', () => {
expect(wrapper.element).toMatchSnapshot();
});
});
describe('with no notes', () => {
it('hides comment count', () => {
createComponent({ notesCount: 0 });
......@@ -88,4 +91,5 @@ describe('Design management list item component', () => {
expect(wrapper.element).toMatchSnapshot();
});
});
});
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment