i am building a flask RESTapi and i am using postman to make http post requests to my api , i want to use the werkzeug debugger , but postman wont allow me to put in the debugging pin and debug the code from postman , what can i do ?
Never needed any debugger for postman. This is not the tool you need the long blanket of code for one endpoint to test.
It gives a good option - console. I have never experienced any trouble this simple element didn't help me so far.
Related
I have created an Express REST API and followed various methods to put debugger inside API callback function, but no luck. I also tried This link. Still I am not able to use debugger on API call. Any help would be appreciated.
Normally all you need to do to get such breakpoints hit is starting your Node.js run configuration in debugger and then opening <yourserver URL>/list in browser:
I'm testing a native ios/android app using a webdriverio boilerplate (https://github.com/webdriverio/appium-boilerplate) project as basis.
But for some scenarios I need to put a user with a precondition info, and for that i want to send a HTTP request to a webserver to set the info for that user.
There is any way to send a post wile using webdriverio an appium on native apps?
I'm trying to send the post after initialize the app but nothing seems to be happening...
You can make HTTP POST request using webdriverio. It doesn't matter what the mode of test(appium, selenium, cucumber, etc.,.)
Please try this answer if this helps:
How to use 3rd party method that takes callback in webdriverio
I tried nsis for the first time.
You want to send a post to the api server using nsis.
I used the inetc module, the InetLoad module, and the nsJSON module
All communication is not possible.
Help me, I do not feel at all.
For example, if you have headers, data, and url, you know how to use the module. Please.
I am trying to communicate with the api server using inetc :: post
Pop Returns OK from $ 0.
However, if you look at the server logs, you will see a header check fail.
Why?
I want to test the Web API of a system which has also a CLI accessible via a telnet connection. The tests must verify that the response given to the API requests matches the output of commands given to the CLI.
The problem is that as far as I know there's no way to initiate a telnet connection from inside a postman script.
What will be the best way to achieve this?
Maybe postman is not the best tool for this job?
What will be the best way to achieve this?
A dedicated script written in NodeJS or any other programming language with or without help of some test framework like Jest \ karma. For sure not Postman.
You can use Postman to run the above mentioned script with pre-request script but it just make the all process much more complicated. Almost any modern script language will give you the option to send http request, no need to use postman.
Maybe postman is not the best tool for this job?
You are right, it's not.
The Heroku app i'm trying to get to work (code here):
https://github.com/heroku/facebook-template-nodejs
"Unsafe Javascript attempt to access frame with URL" errors occur when the page is loaded in chrome.
The login button takes you to facebook but does not actually log you into the app and gives the same errors.
Has anyone got this app to work on Chrome or can anyone advise as to how to patch it up?
P.S. it seems to work fine on Mozilla.
Almost certain this is a cross domain policy issue, as stated above. Generally speaking, you just need to add the correct header info to the response.
Access-Control-Allow-Origin: *
In Node, I think it is just a matter of adding it as another header in the response, using
response.writeHead
See http://nodejs.org/api/http.html#http_response_writehead_statuscode_reasonphrase_headers
Oh, and there's explicit instructions on how to do it if you're using Express. I see no reason why it can't work using plain old node then.
http://enable-cors.org/server_expressjs.html
So I looked at your link, in your case I think you just have to enter the header info prior to using any other express app methods.
As to why it works in Firefox and not Chrome, not sure. Both support CORS many versions back. Maybe you have some Chrome extension that's interfering.