Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -255,36 +255,47 @@ exports[`Panel Filtering Default Snapshot HTML Snapshot 1`] = `
<div class=\\"slds-form_stacked slds-grow slds-scrollable_y slds-grid slds-grid_vertical\\">
<div class=\\"slds-filters\\">
<div class=\\"slds-filters__header slds-grid slds-has-divider_bottom-space\\">
<h2 class=\\"slds-align-middle slds-text-heading_small\\">Filter</h2><button class=\\"slds-button slds-button_icon slds-button_icon-bare slds-button_icon-small slds-col_bump-left\\" title=\\"Close Panel\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon\\"><use href=\\"/assets/icons/utility-sprite/svg/symbols.svg#forward\\"></use></svg><span class=\\"slds-assistive-text\\">Close Panel</span></button></div>
<div
class=\\"slds-filters__body\\">
<h2 class=\\"slds-align-middle slds-text-heading_small\\">Filter</h2><button class=\\"slds-button slds-button_icon slds-button_icon-bare slds-button_icon-small slds-col_bump-left\\" title=\\"Close Panel\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon\\">
<use href=\\"/assets/icons/utility-sprite/svg/symbols.svg#forward\\"></use>
</svg><span class=\\"slds-assistive-text\\">Close Panel</span></button>
</div>
<div class=\\"slds-filters__body\\">
<ol class=\\"slds-list_vertical slds-list_vertical-space\\">
<li class=\\"slds-item slds-hint-parent\\">
<div class=\\"slds-filters__item slds-grid slds-grid_vertical-align-center\\">
<div class=\\"slds-grow\\" style=\\"display:inline-block\\"><button class=\\"slds-button_reset slds-grow slds-has-blur-focus\\" type=\\"button\\" aria-haspopup=\\"dialog\\" id=\\"sample-panel-filtering-show-me\\" tabindex=\\"0\\"><span class=\\"slds-assistive-text\\">Edit filter:</span><p class=\\"slds-text-body_small\\">Show Me</p><p>All Products</p></button></div>
<div class=\\"slds-grow\\" style=\\"display:inline-block\\"><button class=\\"slds-button_reset slds-grow slds-has-blur-focus\\" type=\\"button\\" aria-haspopup=\\"dialog\\" id=\\"sample-panel-filtering-show-me\\" tabindex=\\"0\\"><span class=\\"slds-assistive-text\\">Edit filter:</span>
<p class=\\"slds-text-body_small\\">Show Me</p>
<p>All Products</p>
</button></div>
</div>
</li>
</ol>
<h3 class=\\"slds-text-body_small slds-m-vertical_x-small\\">Matching all these filters</h3>
<ol class=\\"slds-list_vertical slds-list_vertical-space\\">
<li class=\\"slds-item slds-hint-parent\\">
<div class=\\"slds-filters__item slds-grid slds-grid_vertical-align-center\\">
<div class=\\"slds-grow\\" style=\\"display:inline-block\\"><button class=\\"slds-button_reset slds-grow slds-has-blur-focus\\" type=\\"button\\" aria-haspopup=\\"dialog\\" id=\\"sample-panel-filtering-created-date\\" tabindex=\\"0\\"><span class=\\"slds-assistive-text\\">Edit filter:</span><p class=\\"slds-text-body_small\\">Created Date</p><p>equals THIS WEEK</p></button></div>
<button
class=\\"slds-button slds-button_icon slds-button_icon-bare slds-button_icon-small\\" title=\\"Remove Filter: Created Date equals THIS WEEK\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon slds-button__icon_hint\\"><use href=\\"/assets/icons/utility-sprite/svg/symbols.svg#close\\"></use></svg><span class=\\"slds-assistive-text\\">Remove Filter: Created Date equals THIS WEEK</span></button>
<div class=\\"slds-grow\\" style=\\"display:inline-block\\"><button class=\\"slds-button_reset slds-grow slds-has-blur-focus\\" type=\\"button\\" aria-haspopup=\\"dialog\\" id=\\"sample-panel-filtering-created-date\\" tabindex=\\"0\\"><span class=\\"slds-assistive-text\\">Edit filter:</span>
<p class=\\"slds-text-body_small\\">Created Date</p>
<p>equals THIS WEEK</p>
</button></div><button class=\\"slds-button slds-button_icon slds-button_icon-bare slds-button_icon-small\\" title=\\"Remove Filter: Created Date equals THIS WEEK\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon slds-button__icon_hint\\">
<use href=\\"/assets/icons/utility-sprite/svg/symbols.svg#close\\"></use>
</svg><span class=\\"slds-assistive-text\\">Remove Filter: Created Date equals THIS WEEK</span></button>
</div>
</li>
<li class=\\"slds-item slds-hint-parent\\">
<div class=\\"slds-filters__item slds-grid slds-grid_vertical-align-center\\">
<div class=\\"slds-grow\\" style=\\"display:inline-block\\"><button class=\\"slds-button_reset slds-grow slds-has-blur-focus\\" type=\\"button\\" aria-haspopup=\\"dialog\\" id=\\"sample-panel-filtering-list-price\\" tabindex=\\"0\\"><span class=\\"slds-assistive-text\\">Edit filter:</span><p class=\\"slds-text-body_small\\">List Price</p><p>greater than &quot;500&quot;</p></button></div>
<button
class=\\"slds-button slds-button_icon slds-button_icon-bare slds-button_icon-small\\" title=\\"Remove Filter: List Price greater than &quot;500&quot;\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon slds-button__icon_hint\\"><use href=\\"/assets/icons/utility-sprite/svg/symbols.svg#close\\"></use></svg><span class=\\"slds-assistive-text\\">Remove Filter: List Price greater than &quot;500&quot;</span></button>
<div class=\\"slds-grow\\" style=\\"display:inline-block\\"><button class=\\"slds-button_reset slds-grow slds-has-blur-focus\\" type=\\"button\\" aria-haspopup=\\"dialog\\" id=\\"sample-panel-filtering-list-price\\" tabindex=\\"0\\"><span class=\\"slds-assistive-text\\">Edit filter:</span>
<p class=\\"slds-text-body_small\\">List Price</p>
<p>greater than &quot;500&quot;</p>
</button></div><button class=\\"slds-button slds-button_icon slds-button_icon-bare slds-button_icon-small\\" title=\\"Remove Filter: List Price greater than &quot;500&quot;\\" type=\\"button\\"><svg aria-hidden=\\"true\\" class=\\"slds-button__icon slds-button__icon_hint\\">
<use href=\\"/assets/icons/utility-sprite/svg/symbols.svg#close\\"></use>
</svg><span class=\\"slds-assistive-text\\">Remove Filter: List Price greater than &quot;500&quot;</span></button>
</div>
</li>
</ol>
</div>
<div class=\\"slds-filters__footer slds-grid slds-shrink-none\\"><button class=\\"slds-button_reset slds-text-link\\" type=\\"button\\">Add Filter</button><button class=\\"slds-button_reset slds-text-link slds-col_bump-left\\" type=\\"button\\">Remove All</button></div>
</div>
<div class=\\"slds-filters__footer slds-grid slds-shrink-none\\"><button class=\\"slds-button_reset slds-text-link\\" type=\\"button\\">Add Filter</button><button class=\\"slds-button_reset slds-text-link slds-col_bump-left\\" type=\\"button\\">Remove All</button></div>
</div>
</div>
</div>"
`;
2 changes: 1 addition & 1 deletion tests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Use Jest to test the presence of:

#### How to add new suites of tests

Suites such as DOM snanpshot tests or accessibility tests should be added to all stories and the whole library at once. Stories that do not pass, should be exluded from continuous integration tests and an issue should be created to remove the component from exlusion. In short, add types of testing to all new components by excluding existing components that fail instead of adding existing components to a list of components to test. This forces new components to meet the requirements of the new tests and creates a list of components that need to be worked on instead of a list of components that currently pass.
Suites such as DOM snanpshot tests or accessibility tests should be added to all stories and the whole library at once. Stories that do not pass, should be excluded from continuous integration tests and an issue should be created to remove the component from exclusion. In short, add types of testing to all new components by excluding existing components that fail instead of adding existing components to a list of components to test. This forces new components to meet the requirements of the new tests and creates a list of components that need to be worked on instead of a list of components that currently pass.

#### Source files

Expand Down