• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

cdimascio / express-openapi-validator / 2442
91%

Build:
DEFAULT BRANCH: master
Ran 14 Feb 2021 08:55PM UTC
Jobs 3
Files 23
Run time 4s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
2442

push

travis-ci

web-flow
Fix Mutation of API Spec (#537)

* test: Add Failing Test Case for Issue 535.

Add failing test case for
https://github.com/cdimascio/express-openapi-validator/issues/535.

The problem manifests itself when calling `middleware()` with an object
multiple times, as the object itself is mutated which might cause errors
on subsequent calls.

In this specific example, the parameters for GET /ping/{value} are
modified in such a way that a second call will cause a validation error.
This happens in `preprocessPathLevelParameters`.

* fix: Clone API Spec to avoid Mutation of Parameter

Clone the API specification passed to the `middleware()` function. This
avoids mutating the `apiSpec` parameter passed to that function, which
can lead to unexpected behaviour.

Fixes https://github.com/cdimascio/express-openapi-validator/issues/535.

1041 of 1217 branches covered (85.54%)

Branch coverage included in aggregate %.

1273 of 1345 relevant lines covered (94.65%)

397.02 hits per line

Jobs
ID Job ID Ran Files Coverage
1 2442.1 (COVERALLS_REPO_TOKEN=[secure] CODACY_PROJECT_TOKEN=[secure]) 14 Feb 2021 08:55PM UTC 0
90.16
Travis Job 2442.1
2 2442.2 (COVERALLS_REPO_TOKEN=[secure] CODACY_PROJECT_TOKEN=[secure]) 14 Feb 2021 08:55PM UTC 0
90.16
Travis Job 2442.2
3 2442.3 (COVERALLS_REPO_TOKEN=[secure] CODACY_PROJECT_TOKEN=[secure]) 14 Feb 2021 08:55PM UTC 0
90.24
Travis Job 2442.3
Source Files on build 2442
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #2442
  • 2866ce6b on github
  • Prev Build on master (#2434)
  • Next Build on master (#2443)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc