nike-inc / bokor Goto Github PK
View Code? Open in Web Editor NEWBokor is a simple, Record and Playback Mock Server written in Node.js, utilized for Service Virtualization.
License: Apache License 2.0
Bokor is a simple, Record and Playback Mock Server written in Node.js, utilized for Service Virtualization.
License: Apache License 2.0
Great tool.
I was thinking if there is thought or a roadmap to add a cli for Bokor.
The simple use case that is would solve would be not needing a seperate bokor/index.js
file, when using bokor whenever using a "default" scructure.
In an app you need to start the dev server (typically) and then start the bokor server which most of the time takes in default files.
i.e. "start:bokok": "npm run start:dev && node bokor
At some point it would be nice if we could add a cli option that would allow us to simply run
"start:bokok": "npm run start:dev && bokor
The cli would use default file path and names unless args to overwrite some of those values was passed in.
I control-c'd it after 60 seconds. I have noooooooo idea if it is going to take forever or some finite amount.
In the example, I mean.
There is a issue where a PUT request does not remove the accept encoding header like the GET requests and is possible for the recording to be gzip'ed and unreadable.
Refer the fantastic http://todobackend.com/ comparison portal.
The web.py example is pretty self contained.
Your demo should be a (fill in the blanks) version of this:
git clone [email protected]:moredip/todo-backend-py.git
cd todo-backend-py/
pip install web.py
(Setup Bokor to record here)
python todo-backend.py
Launch tests in browser, via http://todobackend.com/specs/index.html?https://localhost:8080
Stop the todo-backend.py server
stop Bokor
(inspect captured traffic)
Then .. instructions as to how to play back and pass the same test-harness suite.
Be aware though that the author set up web.py
incorrectly, and you might need to find the python process in ps aux
to kill it if control-c isn't responding.
When running a curl command through bokor I am receiving the following error:
if(server && !proxyReq.getHeader('expect')) {
^
TypeError: proxyReq.getHeader is not a function
Digging into it the dependency http-proxy was updated in May (https://github.com/http-party/node-http-proxy/pull/1447/files) which is causing the issue.
Downgrading the package resolves issue: npm install [email protected]
This solution is not ideal due to DOS vulnerability: https://www.npmjs.com/advisories/1486
The error is coming out of the Sepia packages /bokor/lib/sepia/src/cache.js:253:13)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.