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

@automated/automated

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@automated/automated

Use-case-oriented testing

  • 0.100.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2
increased by100%
Maintainers
1
Weekly downloads
 
Created
Source

Automated ⚙️

Automated is a test framework designed to simplify testing by standardizing.

With a few lines of code here’s what you get out of the box:

  1. Multiple viewport visual regression coverage
  2. Jest unit tests (via snapshots)
  3. Code coverage (can persist to CI)
  4. Storybook artifacts (can persist to CI)
  5. Isolated component development environment (Storybook)

Installation

__automated.tsx

Quick start

  1. Go to one of your components and let’s say the component is named “Foo”
  2. Put it in a folder called “foo” with the component file named index.tsx
  3. Make the component the default export
  4. Add a sibling file named __automated.tsx, with the following contents
import Component from '.';

export default {
  Component,
  dirname: __dirname,
};
  1. Then run yarn automated init (You’ll see some files added).
  2. Now you can run yarn automated storybook to see it in an isolated dev environment
  3. Open another terminal and run yarn automated jest to generate snapshots and visual regression tests.

Examples

  1. Least content example
  2. More robust

API

__automated.tsx contents

export default {
  // [required] the subject React component
  Component,

  // [required] this supports automatic naming
  dirname: __dirname,

  // an array of use-cases
  useCases,
};

Contributing

# in one terminal
yarn nps dev

# in another
cd example && AUTOMATED_DEVELOPMENT=true yarn automated jest

Keywords

FAQs

Package last updated on 07 Sep 2022

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