Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

newman: could not find "htmlextra --reporter-htmlextra-title "ABC " --reporter-htmlextra-export ABC.html" reporter #385

Closed
1 task done
ShilpaSachdeva opened this issue May 3, 2022 · 2 comments
Labels
state: triaged This issue has been triaged

Comments

@ShilpaSachdeva
Copy link

ShilpaSachdeva commented May 3, 2022

Is There An Existing Issue

What Are You Seeing

I am trying to run my collections in parallel using https://github.com/postmanlabs/newman/blob/develop/examples/parallel-collection-runs.js.
In options, i give reporter as htmlextra
reporters: ('htmlextra --reporter-htmlextra-title "ABC_Test " --reporter-htmlextra-export abc.html')
In gitlab-ci.yml, i have

image: 
  name: dannydainton/htmlextra
  entrypoint: [""]

stages:
    - build
    - test

install_dependencies:
  stage: build
  script:
    - npm install

  artifacts:
    paths:
      - node_modules/
      
cache:
  paths:
    - node_modules/

api_testing:
  stage: test
  script: npm test (this runs parallel.js file)
  artifacts:
        paths:
          - abc.html

package.json looks like:

{
  "name": "parallelrun",
  "version": "1.0.0",
  "description": "",
  "main": "parallel.js",
  "scripts": {
    "test": "node parallel.js"
  },
  "dependencies": {
    "async": "3.2.3",
    "newman": "^5.3.2",
    "newman-reporter-htmlextra": "^1.22.8"
  }
}

Steps To Reproduce The Issue

Running locally or in pipeline gives same error
newman: could not find "cli, htmlextra --reporter-htmlextra-title "ABC " --reporter-htmlextra-export abc.html" reporter
ensure that the reporter is installed in the same directory as newman
please install reporter using npm

Full Newman Command Or Node Script

Locally in terminal
npm init (will install dependency from package.json)
node parallel.js (will execute similar file https://github.com/postmanlabs/newman/blob/develop/examples/parallel-collection-runs.js
but with reports in option as mentioned above )

HTMLEXTRA Version

1.22.8

Newman Version

5.3.2

Additional Context

No response

@ShilpaSachdeva ShilpaSachdeva added state: needs-triage This issue needs to be triaged type: bug Something isn't working labels May 3, 2022
@DannyDainton
Copy link
Owner

DannyDainton commented May 3, 2022

What's this doing?

reporters: ('htmlextra --reporter-htmlextra-title "ABC_Test " --reporter-htmlextra-export abc.html')

That property is for adding reporters, not the flags for the reporters.

reporters: ('htmlextra')

A basic example:

https://gitlab.com/DannyDainton/postman-ci-pipeline-example/-/blob/master/.gitlab-ci.yml

This isn't a bug with the reporter, it's an issue with your use of the YAML file. Closing this issue.

@DannyDainton DannyDainton added state: triaged This issue has been triaged and removed type: bug Something isn't working state: needs-triage This issue needs to be triaged labels May 3, 2022
@DannyDainton DannyDainton changed the title newman: could not find "htmlextra --reporter-htmlextra-title "ABC " --reporter-htmlextra-export ABC.html" reporter ensure that the reporter is installed in the same directory as newman please install reporter using npm newman: could not find "htmlextra --reporter-htmlextra-title "ABC " --reporter-htmlextra-export ABC.html" reporter May 3, 2022
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 18, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
state: triaged This issue has been triaged
Projects
None yet
Development

No branches or pull requests

2 participants