@accounter/server 0.0.9-alpha-20251210081057-0c84c2d320ba0837ffcc554d0c5472376f180fa6 → 0.0.9-alpha-20251210083505-7da76130a1cfc5740c43048b95dbb71748441f56

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @accounter/server
2
2
 
3
- ## 0.0.9-alpha-20251210081057-0c84c2d320ba0837ffcc554d0c5472376f180fa6
3
+ ## 0.0.9-alpha-20251210083505-7da76130a1cfc5740c43048b95dbb71748441f56
4
4
 
5
5
  ### Patch Changes
6
6
 
@@ -147,6 +147,18 @@
147
147
  - **Documentation**: Extensive documentation has been added, including JSDoc examples, idempotency
148
148
  semantics, security warnings, and thread safety considerations.
149
149
 
150
+ - [#2788](https://github.com/Urigo/accounter-fullstack/pull/2788)
151
+ [`fd2c542`](https://github.com/Urigo/accounter-fullstack/commit/fd2c542eeed905d8a83137e2559485c29b3ecc66)
152
+ Thanks [@gilgardosh](https://github.com/gilgardosh)! - - **Test Suite Split**: The project's test
153
+ suite has been formally split into distinct 'unit' and 'integration' test projects using Vitest,
154
+ enhancing organization and execution efficiency.
155
+ - **New Test Commands**: New `yarn` commands have been introduced: `yarn test` for unit tests,
156
+ `yarn test:integration` for both unit and integration tests, and `yarn test:all` for running all
157
+ suites.
158
+ - **Updated Documentation**: Both the root `README.md` and `packages/server/README.md` have been
159
+ updated with comprehensive documentation on the new test suite structure, how to run tests, and
160
+ prerequisites for integration tests.
161
+
150
162
  - [#2751](https://github.com/Urigo/accounter-fullstack/pull/2751)
151
163
  [`77ad870`](https://github.com/Urigo/accounter-fullstack/commit/77ad8705cfadfab6a4e182c80937b8d96467098a)
152
164
  Thanks [@gilgardosh](https://github.com/gilgardosh)! - - **Centralized DB Pool Management**: The
@@ -222,10 +234,10 @@
222
234
  [`ef68321`](https://github.com/Urigo/accounter-fullstack/commit/ef68321608d60a7208e82a2c413f27beb502e3cc),
223
235
  [`ef68321`](https://github.com/Urigo/accounter-fullstack/commit/ef68321608d60a7208e82a2c413f27beb502e3cc),
224
236
  [`c7d6f21`](https://github.com/Urigo/accounter-fullstack/commit/c7d6f21ed62658159b1323334501daca03c8d3e5)]:
225
- - @accounter/green-invoice-graphql@0.8.3-alpha-20251210081057-0c84c2d320ba0837ffcc554d0c5472376f180fa6
226
- - @accounter/pcn874-generator@0.6.4-alpha-20251210081057-0c84c2d320ba0837ffcc554d0c5472376f180fa6
227
- - @accounter/shaam-uniform-format-generator@0.2.3-alpha-20251210081057-0c84c2d320ba0837ffcc554d0c5472376f180fa6
228
- - @accounter/shaam6111-generator@0.1.5-alpha-20251210081057-0c84c2d320ba0837ffcc554d0c5472376f180fa6
237
+ - @accounter/green-invoice-graphql@0.8.3-alpha-20251210083505-7da76130a1cfc5740c43048b95dbb71748441f56
238
+ - @accounter/pcn874-generator@0.6.4-alpha-20251210083505-7da76130a1cfc5740c43048b95dbb71748441f56
239
+ - @accounter/shaam-uniform-format-generator@0.2.3-alpha-20251210083505-7da76130a1cfc5740c43048b95dbb71748441f56
240
+ - @accounter/shaam6111-generator@0.1.5-alpha-20251210083505-7da76130a1cfc5740c43048b95dbb71748441f56
229
241
 
230
242
  ## 0.0.8
231
243
 
package/README.md CHANGED
@@ -1,5 +1,39 @@
1
1
  # @accounter-helper/server
2
2
 
3
+ ## Test Suites
4
+
5
+ The test suite is split into two Vitest projects for efficiency and isolation:
6
+
7
+ ### 1. Unit Tests (`yarn test`)
8
+
9
+ Fast, isolated tests with no external dependencies. Runs by default and excludes DB-backed tests and
10
+ demo fixtures.
11
+
12
+ ### 2. Integration Tests (`yarn test:integration`)
13
+
14
+ DB-backed tests including:
15
+
16
+ - Server helpers and test harness (`packages/server/src/__tests__/**`)
17
+ - Module integration tests (`packages/server/src/modules/**/*.integration.test.ts`)
18
+
19
+ **Prerequisites:**
20
+
21
+ - PostgreSQL running
22
+ - Migrations applied (see below)
23
+
24
+ ### Running Tests
25
+
26
+ ```bash
27
+ # Fast unit tests only (default)
28
+ yarn test
29
+
30
+ # Unit + integration tests (for PRs)
31
+ yarn test:integration
32
+
33
+ # All suites (for main branch merges)
34
+ yarn test:all
35
+ ```
36
+
3
37
  ## Test DB Harness
4
38
 
5
39
  This package includes a Vitest-friendly PostgreSQL test harness with:
@@ -4,8 +4,8 @@ import type { GetMeshOptions } from '@graphql-mesh/runtime';
4
4
  import type { YamlConfig } from '@graphql-mesh/types';
5
5
  import { MeshHTTPHandler } from '@graphql-mesh/http';
6
6
  import { type ExecuteMeshFn, type SubscribeMeshFn, type MeshContext as BaseMeshContext, type MeshInstance } from '@graphql-mesh/runtime';
7
- import type { GreenInvoiceNewTypes } from './sources/GreenInvoiceNew/types';
8
7
  import type { GreenInvoiceTypes } from './sources/GreenInvoice/types';
8
+ import type { GreenInvoiceNewTypes } from './sources/GreenInvoiceNew/types';
9
9
  export type Maybe<T> = T | null;
10
10
  export type InputMaybe<T> = Maybe<T>;
11
11
  export type Exact<T extends {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@accounter/server",
3
- "version": "0.0.9-alpha-20251210081057-0c84c2d320ba0837ffcc554d0c5472376f180fa6",
3
+ "version": "0.0.9-alpha-20251210083505-7da76130a1cfc5740c43048b95dbb71748441f56",
4
4
  "type": "module",
5
5
  "description": "",
6
6
  "license": "MIT",
package/.env.test DELETED
@@ -1,13 +0,0 @@
1
- ; Database variables
2
- POSTGRES_USER=postgres
3
- POSTGRES_PASSWORD=postgres
4
- POSTGRES_HOST=localhost
5
- POSTGRES_PORT=5432
6
- POSTGRES_DB=accounter
7
- POSTGRES_SSL='0'
8
-
9
- ; Local entities (Auto-generated if using the seed script on setup)
10
- DEFAULT_FINANCIAL_ENTITY_ID=00000000-0000-0000-0000-000000000000
11
-
12
- ; Mesh dev (Richer logs on the dev environment)
13
- DEBUG=1