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

Feature/stub description #77

Merged
merged 3 commits into from
Dec 8, 2017
Merged

Feature/stub description #77

merged 3 commits into from
Dec 8, 2017

Conversation

goughy000
Copy link
Contributor

Adds a new description field which can be used to show optional descriptions in the logs. Useful when you have a number of stubs loaded for the same endpoint and it starts to get confusing as to which is being matched

---
-  description: Stub one
   request:
      url: ^/one$
      method: GET

   response:
      status: 200
      latency: 100
      body: 'One!'

-  description: Stub two
   request:
      url: ^/two$
      method: GET

   response:
      status: 200
      latency: 100
      body: 'Two!'

-  request:
      url: ^/three$
      method: GET

   response:
      status: 200
      latency: 100
      body: 'Three!'

image

@codecov-io
Copy link

codecov-io commented Jul 31, 2017

Codecov Report

Merging #77 into master will increase coverage by 0.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #77      +/-   ##
==========================================
+ Coverage   98.96%   98.97%   +0.01%     
==========================================
  Files          35       35              
  Lines        1065     1078      +13     
  Branches      177      178       +1     
==========================================
+ Hits         1054     1067      +13     
  Misses          4        4              
  Partials        7        7
Impacted Files Coverage Δ
...github/azagniotov/stubby4j/utils/ConsoleUtils.java 100% <ø> (ø) ⬆️
...io/github/azagniotov/stubby4j/yaml/YAMLParser.java 100% <100%> (ø) ⬆️
...b/azagniotov/stubby4j/stubs/StubHttpLifecycle.java 97.33% <100%> (+0.19%) ⬆️
...niotov/stubby4j/yaml/ConfigurableYAMLProperty.java 100% <100%> (ø) ⬆️
...thub/azagniotov/stubby4j/stubs/StubRepository.java 99.15% <100%> (+0.02%) ⬆️

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 d11b9cf...1d06930. Read the comment docs.

@azagniotov
Copy link
Owner

Thanks @goughy000 ! Will address this shortly!

@pieterlange
Copy link

@azagniotov can this get merged? looks like a very useful feature when debugging rules.

The logformat could use some work too. If i make a PR for a customizable logformat, will it sit idle like this one? ;)

@goughy000
Copy link
Contributor Author

@pieterlange, @azagniotov has merged before so I'm sure he has just forgotten about this one

Logging could do with an overhaul I think, maybe incorporate a common logging framework like SLF4J ?

@azagniotov
Copy link
Owner

I think we just need README update, @goughy000

@azagniotov azagniotov merged commit 224b7af into azagniotov:master Dec 8, 2017
@azagniotov
Copy link
Owner

@goughy000 Version 5.0.2 has been released. Please allow few hours for it to be available on maven central. The docs are as follows: https://github.com/azagniotov/stubby4j#stubfeature-description

I appreciate your time & work on this!

@goughy000
Copy link
Contributor Author

You are very welcome

@azagniotov
Copy link
Owner

@pieterlange It has been merged and the new version has been released on Maven. Regarding your suggested PR, pls go ahead and I will make sure to merge & release it as soon as it is ready

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.

None yet

4 participants