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

Mapping a similar path to yml config will match wrong domains #31

Open
ghost opened this issue Aug 29, 2019 · 0 comments
Open

Mapping a similar path to yml config will match wrong domains #31

ghost opened this issue Aug 29, 2019 · 0 comments
Labels
bug Something isn't working

Comments

@ghost
Copy link

ghost commented Aug 29, 2019

Describe the bug
Mapping a similar path to tshield.yml will match wrong domains

To Reproduce
Steps to reproduce the behavior:

  1. Define a tshield.yml
domains:

  'http://localhost:9092':
    name: 'customer-backend'
    paths:
      - /users

  'http://localhost:9090':
    name: 'invoice-backend'
    paths:
      - /secure/users
  1. Make a request to /secure/users

Expected behavior
A request should be saved in "invoice-backend/secure-users/get/0.content"

  Scenario: Save response body for similar paths
    Given an api "http://localhost:9092" with path "/users" and name "customer-backend"
    And an api "http://localhost:9090" with path "/secure/users" and name "invoice-backend"
    When "/users" is accessed throught tshield
    And "/secure/users" is accessed throught tshield
    Then response should be saved in "customer-backend/users/get/0.content"
    And response should be saved in "invoice-backend/secure-users/get/0.content"

Additional context

  • TShield version: 0.10.0.0
$ ruby -v
ruby 2.5.0p0 (2017-12-25 revision 61468) [x86_64-darwin18]
@ghost ghost added the bug Something isn't working label Aug 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

0 participants