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

allure-jasmine

Package Overview
Dependencies
Maintainers
3
Versions
70
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

allure-jasmine - npm Package Compare versions

Comparing version 2.5.0 to 2.6.0

6

dist/src/JasmineAllureReporter.js

@@ -84,5 +84,2 @@ "use strict";

allureTest.stage = allure_js_commons_1.Stage.RUNNING;
(0, allure_js_commons_1.getSuitesLabels)(this.groupStack.map(({ name }) => name)).forEach((label) => {
allureTest.addLabel(label.name, label.value);
});
for (const labels of this.labelStack) {

@@ -135,2 +132,5 @@ for (const label of labels) {

this.groupStack.pop();
(0, allure_js_commons_1.getSuitesLabels)(this.groupStack.map(({ name }) => name)).forEach((label) => {
currentTest.addLabel(label.name, label.value);
});
}

@@ -137,0 +137,0 @@ suiteDone() {

{
"name": "allure-jasmine",
"version": "2.5.0",
"version": "2.6.0",
"description": "Allure Jasmine integration",

@@ -35,3 +35,3 @@ "license": "Apache-2.0",

"dependencies": {
"allure-js-commons": "2.5.0"
"allure-js-commons": "2.6.0"
},

@@ -38,0 +38,0 @@ "nyc": {

@@ -6,1 +6,40 @@ # allure-jasmine

For usage example see `test/Setup.ts`
## Usage with Jest (`jest@<27`)
Use your favorite node package manager to install required packages:
```bash
npm add -D jest-jasmine2 allure-jasmine allure-js-commons @types/jasmine
```
Create `allure-setup.ts` file:
```ts
import { JasmineAllureReporter } from "allure-jasmine";
import { JasmineAllureInterface } from "allure-jasmine/dist/src/JasmineAllureReporter";
const reporter = new JasmineAllureReporter({ resultsDir: "allure-results" });
jasmine.getEnv().addReporter(reporter);
// @ts-expect-error
global.allure = reporter.getInterface();
declare global {
const allure: JasmineAllureInterface;
}
```
Change your `jest.config.js` file:
```js
module.exports = {
preset: "ts-jest",
+ testRunner: "jest-jasmine2",
+ setupFilesAfterEnv: ["./allure-setup.ts"],
};
```
You can find example setup and usage in this [repo](https://github.com/vovsemenv/allure-jest-example)
[allure-jest]: https://github.com/allure-framework/allure-js/tree/master/packages/allure-jest

Sorry, the diff of this file is not supported yet

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