Do Protractor tools as similar as Cypress features exist? - protractor

Currently, I use Protractor for my project. But I discover Cypress and I'm falling in love with some feature like auto-loading tests and testing GUI that allow to see screenshot for each steps.
I search some tools similar for Protractor but nothing. Does someone know some tools like that, please ?
Thank you for your answer

To screenshot after each step you can use protractor-html-reporter-2
and set option screenshotsOnlyOnFailure to false.
screenshotsOnlyOnFailure (bool) default: true To display screenshots
only in testcases that failed. Default value is "true".

Related

how can i generate stepdefintion file from feature file in protractor (looking for something like specflow)

Have tried "cucumber gherkin full support" extension, but it gives option to navigate to a step not to generate step". Is there any way i can generate step definition from feature file directly?
enter image description here
strong textenter image description here
If you have not implemented your step definitions, Cucumber will warn you asking to create them with the template.
You can copy paste them and implement your logic inside it.
To generate the steps instead of running it through protractor you can add another command to in your scripts like
"cuke-test": "cucumber-js -r outputjs/pathtoyourstepdeffolder/*.js", and give it a dry run. It should give you the snippets for the unimplemented steps. The tidy gherkin extension in chrome is quite good too.

Chrome Dev Tools : Code Folding

Is there any way to enable cold folding in the CodeMirror used in the sources panel of Chrome Dev Tools.
Normally you would enable this through an option
foldGutter: true
I can see that the options for CodeMirror are being handled via source_frame_module.js.
Is it possible to customize this file?
Currently you cannot modify anything about how CodeMirror in DevTools operates. The only thing that can be done is re-styling via a custom theme extension. There have been numerous bug reports asking for this kind of functionality, but due to security reasons it hasn't been acted on yet nor is planned to be as far as I know.

Karma clear screen before running tests

I use karma to run jasmine specs. Every time a file changes the tests are run. This is awesome but it would be even better if the previous test output would be removed from the terminal.
Is there a way to clear the terminal before tests are run in karma?
It is not supported. I like this idea though. I created issue #1004 to support this.
The issue #Sylvain has created is still open, but there is a plugin karma-clear-screen-reporter which does the job. Internally it uses the magic:
console.log('\u001b[2J\u001b[0;0H');
Alternatively you can also place this at the top of your test runner code to clear the console yourself.
Context
My answer is the same as #bluenote10
The difference is that I made some improvements to the package he posted and published it on my github:
Karma Clear Screen
Improvements
Improvement in the initial message.
Date of the update.
In addition to console.log('\u001b[2J\u001b[0;0H'); the spacing has been improved.

Unable to Copy XPath to Selenium IDE 2.0.0

Whenever I try to Copy Xpath of any item I select through Firebug, I'm just provided with item ID alone.
e.g., //*[#id="txtUsername"]
I know that the path would be something lengthy which needs to placed at Target textbox. I tried my level best to get it done but failed with all my attempts :(
Please help me to find out the place where I'm going wrong? Is that either in Firebug or Selenium?????
P.S: I'm using Selenium IDE V2.0.0 and Firebug V1.11.2.
You need to be careful when using Firebug and Selenium together with respect to the XPath. Firebug will give you the full XPath which is great but Selenium may not understand that target. You may need to use a much smaller subset of the XPath (e.g. Selenium may want '//input' while Firebug will give you a MUCH larger (the complete) XPath).
for many of the Selenium commands, if you are using the IDE, if you click on part of the page you are automating with the IDE set to Record, you will see a target value display. To the right of the target value but to the left of the 'Find' box, there should be a drop down menu to give you options for targets. Depending on the webpage you are automating different targets will work better.
Regardless of which method you choose to use to find the XPath to work with Selenium, I can recommend at least the following: Use the 'Find' feature I mentioned above. Place the XPath or any target you want to use in the target value field and click the 'Find' button. The location will display on the webpage and you will know whether or not you've missed the mark.
I hope this helps!

XMLSpy in Eclipse

I need to test XMLSpy functionality in Eclipse. After I switch Eclipse to XMLSpy Perspective and QTP is runnig (record or run mode), it does not work. Could you help me?
Thanks.
Some more information would be helpful. "It does not work" is extremely vague. What does not work? Do you mean that QTP does not record anything at all? Do you mean that QTP records something, but it is incorrect? Does it record some of your test, but misses one particular control, such as a grid? Do you have the right QTP add-ins/plugins enabled to support automation with Eclipse?
Altova support does not seem to have any reference including "Quik Test Pro" issues.
However, check for other plugins (other than XmlSpy):
similar tools has been known to fail in interaction with TPTP for instance.
Check also your Error log view, and complete your question with error messages displayed at the time of the recording.
(source: eclipse.org)