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

Include query parameters and headers in the generated Postman collection. #537

Merged
merged 9 commits into from
Jul 16, 2019

Conversation

MrMage
Copy link
Contributor

@MrMage MrMage commented Jul 12, 2019

Fixes #485.

@MrMage MrMage changed the title Include query parameters in the generated Postman collection. Include query parameters and headers in the generated Postman collection. Jul 12, 2019
@shalvah
Copy link
Contributor

shalvah commented Jul 13, 2019

Thanks. Please update the tests.

@codecov-io
Copy link

codecov-io commented Jul 15, 2019

Codecov Report

Merging #537 into master will increase coverage by 0.16%.
The diff coverage is 100%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #537      +/-   ##
============================================
+ Coverage     90.72%   90.88%   +0.16%     
- Complexity      289      290       +1     
============================================
  Files            14       14              
  Lines           679      691      +12     
============================================
+ Hits            616      628      +12     
  Misses           63       63
Impacted Files Coverage Δ Complexity Δ
src/Postman/CollectionWriter.php 93.18% <100%> (+2.55%) 19 <2> (+1) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d07f68a...f8430b6. Read the comment docs.

@MrMage
Copy link
Contributor Author

MrMage commented Jul 15, 2019

@shalvah sorry, I had missed the tests. I have now:

  • fixed the existing tests
  • added new tests for query params and custom headers (added features in this test)
  • added a test for body params (previously implemented but not tested)
  • improved the formatting of some of the collection fixture JSON files, for easier updating of the test fixtures in the future
  • improved diff output for failing tests by decoding the JSON fixtures as arrays instead of objects (this gives us more detailed info on exactly which properties are different).

Copy link
Contributor

@shalvah shalvah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work. A few minor changes to go...

tests/GenerateDocumentationTest.php Show resolved Hide resolved
tests/GenerateDocumentationTest.php Show resolved Hide resolved
src/Postman/CollectionWriter.php Outdated Show resolved Hide resolved
@MrMage
Copy link
Contributor Author

MrMage commented Jul 16, 2019

@shalvah applied your changes, please take another look.

I'd suggest using GitHub's "Squash and Merge" function when merging to reduce the number of commits in the main repo's history.

@shalvah
Copy link
Contributor

shalvah commented Jul 16, 2019

Nice work!

@shalvah shalvah merged commit 573e9ef into mpociot:master Jul 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Request headers not added to Postman collections
3 participants