“N-tier architecture is also called multi-tier architecture because the software is engineered to have the processing, data management, and presentation functions physically and logically separated. That means that these different functions are hosted on several machines or clusters, ensuring that services are provided without resources being shared and, as such, these services are delivered at top capacity. The “N” in the name n-tier architecture refers to any number from 1.”
Also see Web Application Architecture
Application Architecture : 2 Layer
Web UI & Web API
- Mocking is needed for both
Data
andBusiness
however both UI and API use models fromCore.Entities
which were mapped inData
/Business
.
Business
- Will mostly have pure functions with the exeption of probably
DateTime
related functions. - Knows nothing about the
Data
module so no mocking is needed for unit tests in the
Application Architecture : nLayer
Web UI & Web API
- No mocking is needed for
Data
only business, if a repository fromData
is injected this is considered anEND RUN
Business
- Mocking is needed for data, should accept and respond with
Core.Entities