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

grep-tests-from-pull-requests

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

grep-tests-from-pull-requests - npm Package Compare versions

Comparing version 1.1.0 to 1.2.0

2

package.json
{
"name": "grep-tests-from-pull-requests",
"version": "1.1.0",
"version": "1.2.0",
"description": "Grabs the test tags to run from the pull request text",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -5,2 +5,4 @@ # grep-tests-from-pull-requests

Read the blog post [Pick Tests To Run Using The Pull Request Text](https://glebbahmutov.com/blog/pick-tests-using-pull-request/).
## Install

@@ -43,2 +45,19 @@

## Resolved value
The function might resolve with an object if the pull request was found. You can check if the user wants to run all the tests, or a list of tags
```js
const testsToRun = await require('grep-tests-from-pull-requests')(...)
if (testsToRun) {
if (testsToRun.all) {
console.log('running all tests')
} else if (testsToRun.tags.length) {
console.log('the user picked %s tags to run', testsToRun.tags.join(', '))
} else {
console.log('the user did not pick any tests to run')
}
}
```
## Debugging

@@ -45,0 +64,0 @@

@@ -86,2 +86,4 @@ /// <reference types="cypress" />

}
return testsToRun
}

@@ -88,0 +90,0 @@ }

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