Are user acceptance test (UAT) and end-to-end (E2E) test the same thing?

User Acceptance Test is a phase in a typical software development process.

From the other side, End-To-End test is one of the approaches to testing the complex applications which involves all layers of the application to interact with each other during test execution.

It means that you can execute End-to-End test in User Acceptance Test phase, and you can't consider those two terms as one, that has the same meaning.


End-to-End testing is typically performed by a technical QA team, whereas User Acceptance Testing is typically performed by a business user. The perspectives are different, and while some duplication of effort could happen, the defects identified may vary.


TLDR;

Acceptance and End-to-end tests are designed to test the applications functionality from a users perspective, you can group these together as "Functional tests". Do not mock database or network access, these tests should run against a production environment. Use TestCafe.

Unit tests cover a unit of work which means a single method. Mock dependencies like database or network access. Use Jest.

Integration tests cover multiple units of work that are related, for example a single/multiple ReactJS components. Mock dependencies like database or network access. Use Jest.


Acceptance and End-to-end tests are designed to test the applications functionality. They are usually created by BA, QA, and Engineering before development starts, and then automated by an engineer during development.

1. End to end tests (Actions)

Often a manual effort by someone on the team to make sure all of the functionality still works after new updates. This can be automated by using a UI testing tool like TestCafe.

For example "An authenticated user can start a job application, input all relevant details, and submit the application."

2. Acceptance tests (Visual)

Acceptance tests are automated with tools like Jest/TestCafe and concentrate on story functionality and/or what exists on a page if an action occurs.

For example "An authenticated user can view all job applications on the dashboard page."

3. Unit tests

Created during development by the engineer. Tests a unit of work which could be a single method, or a method that is composed of multiple private methods. A good rule of thumb would be to only test the public interface of a class.

Private methods don't always necessarily need to be tested as they are part of a unit of work. But in the case where there is complex logic in the private method it might be a good idea to test it in isolation. You could use Jest while mocking dependencies of the unit of work like database and network access.

4. Integration tests

Created during development by the engineer. Tests a unit of work without mocking. Generally focuses on a wider scope than a unit test. For example, creating a user might include storing details in the database, sending a web request to a service, and responding to the client. Often requires an in-memory web server to run the tests. Use Jest.