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

How to fetch folder description to html report #52

Open
musanas opened this issue Nov 30, 2018 · 5 comments
Open

How to fetch folder description to html report #52

musanas opened this issue Nov 30, 2018 · 5 comments

Comments

@musanas
Copy link

musanas commented Nov 30, 2018

Hi,

In my collection, I have arranged different apis in to different folders
And each folder has some small descriptions like below
folder

I am trying to display this in the newman HTML report
Basically like {{folder name}} - {{the description}}

I have played with it much
I understand the below part in hbs file does this
`

Requests

{{#each aggregations}}
    {{#if parent.name}}
    <div class="panel-group" id="collapse-folder-{{parent.id}}" role="tablist" aria-multiselectable="true">
        <div role="tab" id="folderHead-{{parent.id}}">
            <h4 style="font-size: 18px;" class="panel-title"><a data-toggle="collapse" data-parent="#accordion" href="#folderData-{{parent.id}}" aria-controls="collapseOne"><strong>{{parent.name}} - {{parent.description}}</strong></a></h4>
        </div>
        <br/>
        <div id="folderData-{{parent.id}}" class="panel-collapse collapsed" role="tabpanel" aria-labelledby="folderHead-{{parent.id}}">
        {{> aggregations}}
        </div>
    </div>
    {{else}}
    {{> aggregations}}
    {{/if}}
{{/each}}
</div>`

I can get the folder name , folder id etc
I couldn't get the folder description
I understand that these informations are there in the {{summary}} object and I can console the same in cli as well, I just not aware of what handlebars object need to pass for this
PS C:\Development\CP-Bronze-Code-New\cloudpay-api-qa> node newmantest.js { "_": { "postman_id": "bb3eeb6b-7535-4800-805a-65867ec59159" }, "item": [ { "id": "4c356d2f-b863-4c3e-9143-6ef829f3bd29", "name": "Employees by Company Number Copy", "description": { "content": "Not used anywhere in Payroll app at the moment", "type": "text/plain" }, "item": [ { "id": "4237f338-5e80-4c1c-be0e-a2801eb9a356",

Can you please throw some light here, what handlebar object need to be used to get the folder description in html report

Thanks
Musaffir

@gederian
Copy link

gederian commented Nov 30, 2018 via email

@gederian
Copy link

gederian commented Nov 30, 2018 via email

@kunagpal kunagpal transferred this issue from postmanlabs/newman Dec 24, 2018
@kunagpal kunagpal added the enhancement New feature or request label Dec 24, 2018
@kunagpal
Copy link
Contributor

@musanas As can be seen from the compiled folder structure here: https://github.com/postmanlabs/newman-reporter-html/blob/develop/lib/index.js#L146, folder descriptions are not added. However, we're more than happy to accommodate this as a feature request.

@musanas
Copy link
Author

musanas commented Dec 26, 2018

Thanks @kunagpal

@DannyDainton
Copy link
Collaborator

As an interim step and to unblock things for you, this feature had been added into the newman-reporter-htmlextra reporter, if you wanted to check that out.

@DannyDainton DannyDainton added feature product/newman and removed enhancement New feature or request labels Jul 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants