New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@mojotech/prismatest-adapter-tests

Package Overview
Dependencies
Maintainers
3
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mojotech/prismatest-adapter-tests

Tests for the adapters used with the Prismatest library

  • 0.1.11
  • latest
  • npm
  • Socket score

Version published
Maintainers
3
Created
Source

Prismatest Adapter Tests

This module exports a set of tests that should be used when implementing adapters. They ensure that the adapters all adhere to a common baseline of functionality.

Applying

Using these tests is simple. Simply import the generateTests helper and call it. Provide your adapter and a way to render a JSX element with your adapter.

For example:

import { generateTests } from '@mojotech/prismatest-adapter-tests';
import myAdapter from './index';
import * as ReactDOM from 'react-dom';

generateTests(myAdapter, e => {
  const domContainer = document.createElement('div');
  ReactDOM.render(e, domContainer);
  return domContainer;
});

Default View Tests

These tests ensure that the default views all behave similarly for each adapter.

FAQs

Package last updated on 28 Feb 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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