Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@open-wc/testing-helpers

Package Overview
Dependencies
Maintainers
2
Versions
156
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@open-wc/testing-helpers - npm Package Compare versions

Comparing version 0.7.6 to 0.7.7

11

CHANGELOG.md

@@ -6,2 +6,13 @@ # Change Log

## [0.7.7](https://github.com/open-wc/open-wc/tree/master/packages/testing-helpers/compare/@open-wc/testing-helpers@0.7.6...@open-wc/testing-helpers@0.7.7) (2019-01-24)
### Bug Fixes
* add docu for fixtureCleanup ([ab0170a](https://github.com/open-wc/open-wc/tree/master/packages/testing-helpers/commit/ab0170a))
## [0.7.6](https://github.com/open-wc/open-wc/tree/master/packages/testing-helpers/compare/@open-wc/testing-helpers@0.7.5...@open-wc/testing-helpers@0.7.6) (2019-01-20)

@@ -8,0 +19,0 @@

4

package.json
{
"name": "@open-wc/testing-helpers",
"version": "0.7.6",
"version": "0.7.7",
"description": "Testing Helpers following open-wc recommendations",

@@ -31,3 +31,3 @@ "author": "open-wc",

},
"gitHead": "8bd9cadbdf0dc5c2910bd85eb58efbcbe6b2d61c"
"gitHead": "e19e6de88a9bcfac81161c7cca86070a56bcccbd"
}

@@ -86,1 +86,19 @@ # Testing Helpers

```
## Fixture Cleanup
By default, if you import anything via `import { ... } from '@open-wc/testing-helpers';`, it will automatically register a side-effect that cleans up your fixtures.
If you want to be in full control you can do so by using
```js
import { fixture, fixtureCleanup } from '@open-wc/testing-helpers/index-no-side-effects.js';
it('can instantiate an element with properties', async () => {
const el = await fixture(html`<my-el .foo=${'bar'}></my-el>`);
expect(el.foo).to.equal('bar');
fixtureCleanup();
}
// Alternatively, you can add the fixtureCleanup in the afterEach function, but note that this is exactly what the automatically registered side-effect does.
afterEach(() => {
fixtureCleanup();
});
```
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc