What I'm looking for in an answer
- Concrete relevant(newer?) examples of why one choice is better than the other
- OR, a concrete suggestion of why using a different language is the better choice over using Javascript to test the live API
I'm new to Angular and just started a job working on QA for a project with a front end written in Angular. I'm planning on writing e2e for the UI in Protractor with Jasmine. I need to write roughly equivalent e2e tests for the API, I know I don't want mocking tests (Unit tests will be written in Karma or in the C# back end directly, I'm still working that out). I want to hit the live endpoints.
My thought was to use Javascript for my testing, to keep the list of languages being used in the product short. I've narrowed down to using either Jasmine with FrisbyJS or Mocha and Chai. I want to choose something that will survive for the foreseeable future, but at the least the next 2 years.
Jasmine and FrisbyJS
Pros:
- I'm using Jasmine already with Protractor/Karma
- FrisbyJS seems easy enough to use once setup
- Does do testing of live API endpoints easily
- Jasmine is an industry standard and will survive long-term
Cons:
- Frisby seems to have gone through a major rewrite and all tutorials I find are from <= 2015 and before this rewrite that now uses Jest instead of Jasmine-Node to run the tests and the documentation on the github page is just wrong in places and I'm having to figure out how to run things I don't even know how to use yet (I have no issue struggling through learning if it's the best choice though!)
- Lack of newer examples on how to use the framework
- Still in the middle of rewrite
- Unsure of longevity
Mocha and Chai
Pros:
- Seem to be a lot of newer tutorials
- Does do testing of live API endpoints easily
Cons:
- Not using Jasmine, so new testers will have to learn both Jasmine (which is being using with Protractor for UI) and Mocha (maybe this isn't a big deal)
- Seems newer, so unsure of the longevity of the framework/module
Some Background Considerations
- I've researched using PostMan or SoapUI for testing of live API (what's the term for this too please??) endpoints, but determined I'm going to have to code regardless, so I'd prefer to not introduce another language or have to pay for another service when I can make languages I have already work
- I have a lot of experience using Java and TestNG to do live API and UI testing (with a custom wrapper library built around Selenium), so I know what it should look like in general
- I'm hoping to reach out to someone with more experience in this with an Angular background as I am the QA expert at my position and I have no one here I can physically pester with questions.
I apologize if this is too much an opinion question. If there's another place I should post this please direct me and I'll remedy with a removal of this question.