meeshkan / hmt

HTTP Mocking Toolkit
MIT License
52 stars 7 forks source link

Name record output '<host>-recordings.jsonl' by default #97

Closed carolstran closed 4 years ago

carolstran commented 4 years ago

Description

While creating a mock of the Studio Ghibli API, I ran into a potential enhancement. After running meeshkan record and recording some API traffic via curl, my recordings were saved to the logs directory... but under the name ghibliapi.herokuapp.com.jsonl (ghibliapi.herokuapp.com is the API host).

Perhaps it would make more sense to have this file always be named recordings.jsonl by default. That way, it matches the documentation and makes it more clear to the user what this file is for.

Additional information

Python version: 3.8.1 Meeshkan version: 0.2.16

In case you're curious, here's a gist of the jsonl that was generated post-recordings: https://gist.github.com/carolstran/7418f2e6a2139a5a42142db5a076bfe4

fornwall commented 4 years ago

Perhaps we could have both host and recordings in there, like in ghibliapi.herokuapp.com-recordings.jsonl or recordings-ghibliapi.herokuapp.com.jsonl?

ksaaskil commented 4 years ago

Ok, we discussed with Carolyn and we can go with ghibliapi.herokuapp.com-recordings.jsonl then!