@accounter/server 0.0.9-alpha-20251210170728-fe2c044a6279c36a9ba58b13bae56b181e8f85f5 → 0.0.9-alpha-20251210171954-c9c0e7693ebe08d3643d9ee2c00c03606a53e334
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 +21 -5
- package/dist/green-invoice-graphql/src/mesh-artifacts/index.d.ts +1 -1
- package/dist/server/src/__tests__/helpers/test-db-config.js +1 -1
- package/dist/server/src/__tests__/helpers/test-db-config.js.map +1 -1
- package/package.json +1 -1
- package/src/__tests__/helpers/test-db-config.ts +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @accounter/server
|
|
2
2
|
|
|
3
|
-
## 0.0.9-alpha-
|
|
3
|
+
## 0.0.9-alpha-20251210171954-c9c0e7693ebe08d3643d9ee2c00c03606a53e334
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
@@ -122,6 +122,22 @@
|
|
|
122
122
|
utilize the `businessId` when constructing links to business detail pages, resolving the issue
|
|
123
123
|
of incorrect navigation.
|
|
124
124
|
|
|
125
|
+
- [#2802](https://github.com/Urigo/accounter-fullstack/pull/2802)
|
|
126
|
+
[`b385a79`](https://github.com/Urigo/accounter-fullstack/commit/b385a79f96fe9435b30511bea0af76407e375da6)
|
|
127
|
+
Thanks [@gilgardosh](https://github.com/gilgardosh)! - - **Centralized Test Database Management**:
|
|
128
|
+
Integration tests now leverage a `TestDatabase` utility class, centralizing database connection,
|
|
129
|
+
pooling, and transaction management for improved consistency and isolation.
|
|
130
|
+
- **Transactional Test Isolation**: Individual test cases are now wrapped in `db.withTransaction`
|
|
131
|
+
blocks, ensuring that each test runs within its own transaction and automatically rolls back
|
|
132
|
+
changes, preventing data leakage between tests.
|
|
133
|
+
- **Simplified Test Setup/Teardown**: The `beforeAll`, `afterAll`, `beforeEach`, and `afterEach`
|
|
134
|
+
hooks in several test files have been streamlined, removing manual `pg.Pool` and `pg.PoolClient`
|
|
135
|
+
management in favor of the `TestDatabase` class's methods.
|
|
136
|
+
- **Removed Obsolete Function**: The `resetSetupFlags` function, previously a no-op, has been
|
|
137
|
+
removed from `db-setup.ts`.
|
|
138
|
+
- **Import Path Correction**: A minor import path correction for `DBProvider` was made in
|
|
139
|
+
`business-trips.provider.ts`.
|
|
140
|
+
|
|
125
141
|
- [#2750](https://github.com/Urigo/accounter-fullstack/pull/2750)
|
|
126
142
|
[`98b8b85`](https://github.com/Urigo/accounter-fullstack/commit/98b8b859ad566372ec3cd65bc57bcc0d6fcdd6fb)
|
|
127
143
|
Thanks [@gilgardosh](https://github.com/gilgardosh)! - - **Database Schema Update**: A new `users`
|
|
@@ -271,10 +287,10 @@
|
|
|
271
287
|
[`ef68321`](https://github.com/Urigo/accounter-fullstack/commit/ef68321608d60a7208e82a2c413f27beb502e3cc),
|
|
272
288
|
[`ef68321`](https://github.com/Urigo/accounter-fullstack/commit/ef68321608d60a7208e82a2c413f27beb502e3cc),
|
|
273
289
|
[`c7d6f21`](https://github.com/Urigo/accounter-fullstack/commit/c7d6f21ed62658159b1323334501daca03c8d3e5)]:
|
|
274
|
-
- @accounter/green-invoice-graphql@0.8.3-alpha-
|
|
275
|
-
- @accounter/pcn874-generator@0.6.4-alpha-
|
|
276
|
-
- @accounter/shaam-uniform-format-generator@0.2.3-alpha-
|
|
277
|
-
- @accounter/shaam6111-generator@0.1.5-alpha-
|
|
290
|
+
- @accounter/green-invoice-graphql@0.8.3-alpha-20251210171954-c9c0e7693ebe08d3643d9ee2c00c03606a53e334
|
|
291
|
+
- @accounter/pcn874-generator@0.6.4-alpha-20251210171954-c9c0e7693ebe08d3643d9ee2c00c03606a53e334
|
|
292
|
+
- @accounter/shaam-uniform-format-generator@0.2.3-alpha-20251210171954-c9c0e7693ebe08d3643d9ee2c00c03606a53e334
|
|
293
|
+
- @accounter/shaam6111-generator@0.1.5-alpha-20251210171954-c9c0e7693ebe08d3643d9ee2c00c03606a53e334
|
|
278
294
|
|
|
279
295
|
## 0.0.8
|
|
280
296
|
|
|
@@ -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 { GreenInvoiceTypes } from './sources/GreenInvoice/types';
|
|
8
7
|
import type { GreenInvoiceNewTypes } from './sources/GreenInvoiceNew/types';
|
|
8
|
+
import type { GreenInvoiceTypes } from './sources/GreenInvoice/types';
|
|
9
9
|
export type Maybe<T> = T | null;
|
|
10
10
|
export type InputMaybe<T> = Maybe<T>;
|
|
11
11
|
export type Exact<T extends {
|
|
@@ -10,7 +10,7 @@ export const testDbConfig = {
|
|
|
10
10
|
password: process.env.POSTGRES_PASSWORD || 'postgres',
|
|
11
11
|
host: process.env.POSTGRES_HOST || 'localhost',
|
|
12
12
|
port: parseInt(process.env.POSTGRES_PORT || '5432', 10),
|
|
13
|
-
database: process.env.POSTGRES_DB || '
|
|
13
|
+
database: process.env.POSTGRES_DB || 'accounter_test',
|
|
14
14
|
ssl: process.env.POSTGRES_SSL === '1',
|
|
15
15
|
};
|
|
16
16
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"test-db-config.js","sourceRoot":"","sources":["../../../../../src/__tests__/helpers/test-db-config.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC,6BAA6B;AAC7B,MAAM,EAAE,CAAC;AAET;;;GAGG;AACH,MAAM,CAAC,MAAM,YAAY,GAAe;IACtC,IAAI,EAAE,OAAO,CAAC,GAAG,CAAC,aAAa,IAAI,UAAU;IAC7C,QAAQ,EAAE,OAAO,CAAC,GAAG,CAAC,iBAAiB,IAAI,UAAU;IACrD,IAAI,EAAE,OAAO,CAAC,GAAG,CAAC,aAAa,IAAI,WAAW;IAC9C,IAAI,EAAE,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,aAAa,IAAI,MAAM,EAAE,EAAE,CAAC;IACvD,QAAQ,EAAE,OAAO,CAAC,GAAG,CAAC,WAAW,IAAI,
|
|
1
|
+
{"version":3,"file":"test-db-config.js","sourceRoot":"","sources":["../../../../../src/__tests__/helpers/test-db-config.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC,6BAA6B;AAC7B,MAAM,EAAE,CAAC;AAET;;;GAGG;AACH,MAAM,CAAC,MAAM,YAAY,GAAe;IACtC,IAAI,EAAE,OAAO,CAAC,GAAG,CAAC,aAAa,IAAI,UAAU;IAC7C,QAAQ,EAAE,OAAO,CAAC,GAAG,CAAC,iBAAiB,IAAI,UAAU;IACrD,IAAI,EAAE,OAAO,CAAC,GAAG,CAAC,aAAa,IAAI,WAAW;IAC9C,IAAI,EAAE,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,aAAa,IAAI,MAAM,EAAE,EAAE,CAAC;IACvD,QAAQ,EAAE,OAAO,CAAC,GAAG,CAAC,WAAW,IAAI,gBAAgB;IACrD,GAAG,EAAE,OAAO,CAAC,GAAG,CAAC,YAAY,KAAK,GAAG;CACtC,CAAC;AAEF;;;GAGG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,kBAAkB,CAAC;AAE9E;;;;GAIG;AACH,MAAM,UAAU,YAAY,CAAC,SAAiB;IAC5C,OAAO,GAAG,YAAY,IAAI,SAAS,EAAE,CAAC;AACxC,CAAC"}
|
package/package.json
CHANGED
|
@@ -13,7 +13,7 @@ export const testDbConfig: PoolConfig = {
|
|
|
13
13
|
password: process.env.POSTGRES_PASSWORD || 'postgres',
|
|
14
14
|
host: process.env.POSTGRES_HOST || 'localhost',
|
|
15
15
|
port: parseInt(process.env.POSTGRES_PORT || '5432', 10),
|
|
16
|
-
database: process.env.POSTGRES_DB || '
|
|
16
|
+
database: process.env.POSTGRES_DB || 'accounter_test',
|
|
17
17
|
ssl: process.env.POSTGRES_SSL === '1',
|
|
18
18
|
};
|
|
19
19
|
|