7

I've recently stumbled upon a modern end-to-end testing framework called Cypress which is going to be released in public beta this year. It really looks awesome at the first glance - there are interesting built-in features, like mocking network requests from out-of-the-box, explicitly waiting for specific AJAX requests, straight-forward way to make API calls directly via Cypress, built-in dashboard and many others (okay, I'm already bought).

And, what is interested, Cypress is not built on top of Selenium, which has many advantages, but also has a potentially important drawback at the moment - it looks like there is no way to run Cypress tests in IE, Safari or Firefox.

We, on the other hand, have a huge test codebase for an Angular application built on top of Protractor. Is Cypress the right tool for testing AngularJS applications? What are the potential issues related to Cypress not being built on top of WebDriver? What other things should we consider when deciding to switch to Cypress or not?

  • 1
    First I've heard of it--sounds interesting. One concern though is that if you look at the history for the readme page, they keep moving the public beta date and have been "about to go to public beta" for over two years now (e.g. github.com/cypress-io/cypress/commit/… ). I might wait and see if they actually make it before investing in a tool that may or may not still be around in 5 years. – c32hedge Sep 7 '17 at 21:36
  • @c32hedge ah, right, good call! Probably too early to switch..I am thinking to may be try something separate using Cypress - say, some high-level isolated internal smoke tests.Thanks. – alecxe Sep 7 '17 at 21:42
  • 1
    Here is Medium article exactly about what you are asking: Cypress.io vs Protractor: e2e testing battle Hope it will be helpful! – Mikki Oct 2 '17 at 14:20
5

Open source:

Cypress.IO looks promising, but I have been holding off with starting to use it on a production project. My main reason that it is a commercial company and I cannot be sure they keep their open-source promise. I think development tools should be open-source. I don't want to invest my time and our company's resources if I am not sure I can re-use it for a future project or company due to budgeting restrictions.

The main question is are they going full open-source or do they have a premium model on features. It could be that their business model will be extra services like cloud parallel test running, but current their business models are unknown.

They keep saying they will open-source it, but we keep waiting.

Cross browser support:

Support for cross browser support is on their feature list. Worst case they build a wrapper around WebDriver. Still I wonder how important automated cross-browser testing is now-a-days. I would expect frameworks to take care of that, I haven't run into a lot of cross-browser issues lately. But then I am not supporting older IE and or mobile-apps at the moment. If you support only the modern latest browser then maybe just testing on Chrome could be sufficient.

Page Objects:

Another worry I have how to structure the code for maintainability. For a new testing framework I would expect to have that build-in.

Can I use the Page Object pattern? As far as page objects are concerned, you should be able to use regular JavaScript functions and aliasing with .as() to essentially recreate what page objects give you.

https://docs.cypress.io/faq/questions/using-cypress-faq.html#Can-I-use-the-Page-Object-pattern

Cypress hasn't. The .as() structure looks interesting, but I think in the end I would build my own wrappers around cypress which feels like it beats the purpose. Also I wonder if it would work with their visual test runner.

Usages:

Some consulting companies are using it and showing it off. Here is a recent meetup in the Netherlands. They have been pushing it in their communication for atleast a year now.

Conclusion:

I would keep waiting until it is released or take the risk of vendor-lockin.

4

Open Source:

I am a developer at Cypress.io. Cypress recently released its public beta and is now open source. The code for it's core product, the Test Runner can be found here.

The Cypress Dashboard Service, used to display test recordings and data when tests are run in CI, will be free for open source projects and paid based on usage for private projects (similar to GitHub). We've tried to be as transparent as possible on our pricing here. You can also contact us directly if you have more questions - support@cypress.io. We are currently doing some pricing discovery before we release exact pricing, but it will be similar to other development tools.

Cross Browser Support

We agree that cross browser support is less of a priority than it used to be, but we still intend to have cross browser support. It is on our roadmap which can be found in our documentation and GitHub repo.

Conclusion:

We have many things on our roadmap for the future and are extremely excited with the contributions we've seen so far after open sourcing. Mostly, we encourage you to just try it out. npm install cypress --save-dev - It takes 5 minutes to get your tests up and running.

1

Go Agile. Try it in small incremental steps.

I would at least give it a chance for initial prototype by making a quick smoke suite out of it and see from there how it goes and will take further incremental steps as per the outcome.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.