mock api
This commit is contained in:
@@ -34,7 +34,8 @@
|
||||
"just-test": "karma start --config karma.conf.js",
|
||||
"just-test-in-node": "mocha --recursive --compilers js:babel-core/register test/core test/components test/bugs test/swagger-ui-dist-package",
|
||||
"e2e": "nightwatch test/e2e/scenarios --config test/e2e/nightwatch.json --verbose",
|
||||
"e2e-initial-render": "nightwatch test/e2e/scenarios --config test/e2e/nightwatch.json --group initial-render"
|
||||
"e2e-initial-render": "nightwatch test/e2e/scenarios --config test/e2e/nightwatch.json --group initial-render",
|
||||
"mock:api": "json-server --watch test/e2e/db.json --port 3204"
|
||||
},
|
||||
"dependencies": {
|
||||
"base64-js": "^1.2.0",
|
||||
@@ -105,6 +106,7 @@
|
||||
"html-webpack-plugin": "^2.29.0",
|
||||
"imports-loader": "0.7.1",
|
||||
"json-loader": "0.5.4",
|
||||
"json-server": "^0.11.0",
|
||||
"karma": "^1.7.0",
|
||||
"karma-chrome-launcher": "^2.2.0",
|
||||
"karma-mocha": "^1.3.0",
|
||||
|
||||
5
test/e2e/db.json
Normal file
5
test/e2e/db.json
Normal file
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"pet": [
|
||||
{"id":1,"category":{"id":0,"name":"string"},"name":"doggie","photoUrls":["string"],"tags":[{"id":0,"name":"string"}],"status":"available"}
|
||||
]
|
||||
}
|
||||
@@ -13,8 +13,8 @@
|
||||
"url":"http://www.apache.org/licenses/LICENSE-2.0.html"
|
||||
}
|
||||
},
|
||||
"host":"petstore.swagger.io",
|
||||
"basePath":"/v2",
|
||||
"host":"localhost:3204",
|
||||
"basePath":"/",
|
||||
"tags":[
|
||||
{
|
||||
"name":"pet",
|
||||
|
||||
Reference in New Issue
Block a user