@api3/commons 0.5.0 → 0.6.0
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/README.md +6 -4
- package/package.json +2 -2
- package/src/processing/processing.test.ts +4 -4
package/README.md
CHANGED
|
@@ -43,12 +43,14 @@ import { createLogger } from '@api3/commons/logger';
|
|
|
43
43
|
|
|
44
44
|
To release a new version follow these steps:
|
|
45
45
|
|
|
46
|
-
1. `git checkout main` - Always publish from `main` branch. Also, ensure that the working
|
|
47
|
-
uncommitted changes).
|
|
46
|
+
1. `git checkout main && git pull` - Always publish from up to date `main` branch. Also, ensure that the working
|
|
47
|
+
directory is clean (has no uncommitted changes).
|
|
48
48
|
2. `pnpm version [major|minor|patch]` - Choose the right version bump. This will bump the version, create a git tag and
|
|
49
49
|
commit it.
|
|
50
|
-
3. `pnpm publish --access public` -
|
|
51
|
-
4. `git push --follow-tags` - Push the tagged commit upstream.
|
|
50
|
+
3. `pnpm publish --access public` - Build the package and publish the new version to NPM.
|
|
51
|
+
4. `git push --follow-tags` - Push the tagged commit upstream. If you don't have access to push directly to main branch,
|
|
52
|
+
create a separate branch and open a PR. This PR must be merged using the "Rebase and merge" strategy to preserve the
|
|
53
|
+
git tag.
|
|
52
54
|
5. Create a new [release on GitHub](https://github.com/api3dao/commons/releases). Use the "Generate release notes"
|
|
53
55
|
feature to generate the release notes from the PR titles.
|
|
54
56
|
|
package/package.json
CHANGED
|
@@ -58,7 +58,7 @@ describe(preProcessEndpointParametersV1.name, () => {
|
|
|
58
58
|
|
|
59
59
|
const throwingFunc = async () => preProcessEndpointParametersV1(preProcessingSpecifications, parameters);
|
|
60
60
|
|
|
61
|
-
await expect(throwingFunc).rejects.
|
|
61
|
+
await expect(throwingFunc).rejects.toThrow('SyntaxError: Unexpected identifier');
|
|
62
62
|
});
|
|
63
63
|
|
|
64
64
|
it('demonstrates access to endpointParameters, but reserved parameters are inaccessible', async () => {
|
|
@@ -192,7 +192,7 @@ describe(postProcessResponseV1.name, () => {
|
|
|
192
192
|
|
|
193
193
|
const throwingFunc = async () => postProcessResponseV1({ price: 1000 }, postProcessingSpecifications, parameters);
|
|
194
194
|
|
|
195
|
-
await expect(throwingFunc).rejects.
|
|
195
|
+
await expect(throwingFunc).rejects.toThrow('SyntaxError: Unexpected identifier');
|
|
196
196
|
});
|
|
197
197
|
});
|
|
198
198
|
|
|
@@ -298,7 +298,7 @@ describe(preProcessEndpointParametersV2.name, () => {
|
|
|
298
298
|
|
|
299
299
|
const throwingFunc = async () => preProcessEndpointParametersV2(preProcessingSpecificationV2, parameters);
|
|
300
300
|
|
|
301
|
-
await expect(throwingFunc).rejects.
|
|
301
|
+
await expect(throwingFunc).rejects.toThrow('SyntaxError: Unexpected identifier');
|
|
302
302
|
});
|
|
303
303
|
|
|
304
304
|
it('reserved parameters are inaccessible', async () => {
|
|
@@ -454,7 +454,7 @@ describe(postProcessResponseV2.name, () => {
|
|
|
454
454
|
const throwingFunc = async () =>
|
|
455
455
|
postProcessResponseV2({ price: 1000 }, postProcessingSpecificationV2, parameters);
|
|
456
456
|
|
|
457
|
-
await expect(throwingFunc).rejects.
|
|
457
|
+
await expect(throwingFunc).rejects.toThrow('SyntaxError: Unexpected identifier');
|
|
458
458
|
});
|
|
459
459
|
});
|
|
460
460
|
|