Coming soon - Get a detailed view of why an account is flagged as spam!
view details

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

10
Advice for testing large SPA?
Post Body

Hey there!

So I work for company where we're currently using microservice architecture. Each team owns a number of API's as well as their own microsite.

Due to reasons I won't go into, we're looking to move to a NuxtJS SPA. Where instead of each-team owning their own microsite, they'll own their respective API's, as well as a set of Vue components. These Vue components will then get imported into the main SPA repo to build the functioning website.

Having not worked with this model before, I'm wondering what the best testing strategy is. My thinking so far is:

  • Unit / functional tests will be part of the vue component repos.
  • UI System tests will live as part of the SPA repo and run against every PR, we'll be mocking any dependent API's
  • Page object classes will exist for each vue component repo, which can be imported/used in the SPA repo for these tests.

So, a few unknowns I'm currently not sure about:

  • What other testing can be done in the vue component repos to minimize breaking changes into the SPA repo? For example, if we were to conduct visual regression testing, should we be testing the vue components individually, or testing an entire page in the SPA? (The former seems more logical to me?)
  • Should E2E tests we typically run a release be part of the SPA application? My concerns with these are obviously:
  1. E2E tests will be hitting an actual environment, which could prevent us from releasing.
  2. The underlying page object classes that're used to write the E2E tests, will live outside the SPA repo. Given the same page objects will be used to run the system tests at PR time, it should be hard for this to happen, but It's entirely plausible.
  • Ideally, we need a way to run the UI system tests in the SPA repo when someone makes a change to one of it's dependencies to ensure the dependency hasn't broken any of the tests, what's a good way of achieving this?

This is my first time having to do this kind of stuff, and it's been a fun learning exercise, however I'm in unknown territory, so any advice would be much appreciated!

Thanks!

Author
Account Strength
100%
Account Age
7 years
Verified Email
Yes
Verified Flair
No
Total Karma
23,857
Link Karma
12,532
Comment Karma
10,817
Profile updated: 6 days ago
Posts updated: 11 months ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
4 years ago