commitizen 5.0.2 → 6.0.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/.github/workflows/publish-approved-releases.yml +42 -0
- package/CONTRIBUTING.md +13 -2
- package/README.md +97 -6
- package/SECURITY.md +17 -0
- package/bin/git-cz.js +9 -6
- package/dist/cli/strategies/git-cz.js +1 -1
- package/dist/commitizen/adapter.js +26 -3
- package/dist/commitizen/configLoader.js +7 -7
- package/dist/commitizen/protocol.js +156 -0
- package/dist/common/util.js +0 -4
- package/docs/migrating-adapters.md +212 -0
- package/junit-testresults.xml +113 -110
- package/package.json +10 -11
- package/pnpm-workspace.yaml +8 -0
- package/renovate.json +12 -0
- package/dist/configLoader/findup.js +0 -33
- package/dist/configLoader/getContent.js +0 -72
- package/dist/configLoader/getNormalizedConfig.js +0 -30
- package/dist/configLoader/loader.js +0 -59
- package/dist/configLoader.js +0 -34
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
# Migration guide for adapter maintainers
|
|
2
|
+
|
|
3
|
+
Commitizen changed a lot between 4.3 and 6.0. This guide is for people who
|
|
4
|
+
publish a commitizen adapter. It covers what changed, what still works, and
|
|
5
|
+
what we recommend doing.
|
|
6
|
+
|
|
7
|
+
**Short version:** an adapter that works with commitizen 4 still works with
|
|
8
|
+
commitizen 5 and 6, without changes, as long as it runs on a supported Node.js
|
|
9
|
+
version. Everything below is optional, but it makes your adapter smaller and
|
|
10
|
+
easier to maintain.
|
|
11
|
+
|
|
12
|
+
## What changed
|
|
13
|
+
|
|
14
|
+
| Version | Change | Affects you if |
|
|
15
|
+
|---|---|---|
|
|
16
|
+
| commitizen 5.0 | Requires Node.js 22.23.5+, 24.22.3+ or 26.13.1+. | Your adapter, or a dependency of it, doesn't run on those versions. |
|
|
17
|
+
| `@commitizen/config` 1.0 | The config loader is now its own package. | You call `require('commitizen').configLoader.load()`. |
|
|
18
|
+
| cz-conventional-changelog 5.0 | Published as an ES module. `require()` still returns `{ prompter }`. | You import it from code that runs on an unsupported Node.js version. |
|
|
19
|
+
| cz-conventional-changelog 6.0 | No longer depends on commitizen, so installing it no longer installs the `cz` command. | Your docs tell users to install only your adapter. |
|
|
20
|
+
| commitizen 5.1 | Adapters can run as their own programs ([adapter protocol](#adopting-the-adapter-protocol)). | You want a newer prompt library, ES modules or top-level `await`. |
|
|
21
|
+
| commitizen 6.0 | No longer installs cz-conventional-changelog. | You `require('cz-conventional-changelog')` without depending on it. |
|
|
22
|
+
|
|
23
|
+
## What keeps working
|
|
24
|
+
|
|
25
|
+
The original adapter contract hasn't changed and isn't deprecated:
|
|
26
|
+
|
|
27
|
+
- commitizen loads `config.commitizen.path` with `require()`. ES modules load
|
|
28
|
+
too, because supported Node.js versions can `require()` them, as long as
|
|
29
|
+
they have no top-level `await`.
|
|
30
|
+
- It calls `prompter(cz, commit)`, or `default.prompter(cz, commit)`.
|
|
31
|
+
- `cz` is commitizen's Inquirer.js 8 instance. It stays on major version 8, so
|
|
32
|
+
custom prompts that subclass Inquirer.js 8 keep working.
|
|
33
|
+
- `commit(message)` takes one string. commitizen never passes a third argument
|
|
34
|
+
to `prompter`. Some adapters rely on that.
|
|
35
|
+
- `require('commitizen').configLoader.load()` still exists and returns the same
|
|
36
|
+
object as before.
|
|
37
|
+
- Config is still read from `config.commitizen` in `package.json`, `.czrc` or
|
|
38
|
+
`.cz.json`. The search starts in the current directory, walks up, and then
|
|
39
|
+
checks the home directory.
|
|
40
|
+
|
|
41
|
+
## Reading config without depending on commitizen
|
|
42
|
+
|
|
43
|
+
Many adapters depend on `commitizen` only to call `configLoader.load()`. That
|
|
44
|
+
has two costs. Every install of your adapter also installs a copy of
|
|
45
|
+
commitizen. And when a project's commitizen version differs from the one your
|
|
46
|
+
adapter asks for, users end up with two copies.
|
|
47
|
+
|
|
48
|
+
Use [`@commitizen/config`](https://github.com/commitizen/config) instead. It is
|
|
49
|
+
the same loader, published on its own:
|
|
50
|
+
|
|
51
|
+
```diff
|
|
52
|
+
- const { configLoader } = require('commitizen');
|
|
53
|
+
- const config = configLoader.load() || {};
|
|
54
|
+
+ const { load } = require('@commitizen/config');
|
|
55
|
+
+ const config = load() || {};
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
or, in an ES module:
|
|
59
|
+
|
|
60
|
+
```js
|
|
61
|
+
import { load } from '@commitizen/config';
|
|
62
|
+
const config = load() || {};
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
`load(configPath?, cwd?)` behaves exactly like `configLoader.load()`. It's an
|
|
66
|
+
ES module without top-level `await`, so `require()` works on every Node.js
|
|
67
|
+
version commitizen supports.
|
|
68
|
+
|
|
69
|
+
Then remove `commitizen` from your `dependencies`.
|
|
70
|
+
|
|
71
|
+
**If users relied on your adapter for the `cz` command.** npm links the bins of
|
|
72
|
+
dependencies, so `npm install your-adapter` used to give users `cz` and
|
|
73
|
+
`git-cz` too. Once you drop the dependency, tell them to install commitizen
|
|
74
|
+
themselves:
|
|
75
|
+
|
|
76
|
+
```sh
|
|
77
|
+
npm install --save-dev commitizen your-adapter
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
This is a breaking change for those users, so release it as a major version.
|
|
81
|
+
cz-conventional-changelog did this in 6.0.0. If you want npm to install
|
|
82
|
+
commitizen alongside your adapter, list it in `peerDependencies` rather than
|
|
83
|
+
`dependencies`. It won't create a second copy.
|
|
84
|
+
|
|
85
|
+
## If your adapter uses cz-conventional-changelog
|
|
86
|
+
|
|
87
|
+
Before commitizen 6, every commitizen install also put cz-conventional-changelog
|
|
88
|
+
in `node_modules`, so code that called `require('cz-conventional-changelog')`
|
|
89
|
+
or `require('cz-conventional-changelog/engine')` could work without depending
|
|
90
|
+
on it. From commitizen 6 that is no longer true. If you import it, list it in
|
|
91
|
+
your own `dependencies`.
|
|
92
|
+
|
|
93
|
+
cz-conventional-changelog 5 and later are ES modules, but `require()` still
|
|
94
|
+
works:
|
|
95
|
+
|
|
96
|
+
- `require('cz-conventional-changelog')` returns `{ prompter }`.
|
|
97
|
+
- `require('cz-conventional-changelog/engine')` returns the engine function.
|
|
98
|
+
|
|
99
|
+
## Adopting the adapter protocol
|
|
100
|
+
|
|
101
|
+
commitizen 5.1 can run an adapter as its own program instead of loading it into
|
|
102
|
+
the commitizen process. A protocol adapter:
|
|
103
|
+
|
|
104
|
+
- uses any prompt library or version, such as `@inquirer/prompts`,
|
|
105
|
+
`@clack/prompts` or `node:readline`, instead of commitizen's Inquirer.js 8;
|
|
106
|
+
- can be an ES module with top-level `await`;
|
|
107
|
+
- gets its config from commitizen, so it doesn't need `@commitizen/config`
|
|
108
|
+
either (unless you also want it to run on its own).
|
|
109
|
+
|
|
110
|
+
### The contract
|
|
111
|
+
|
|
112
|
+
Declare the protocol in `package.json`:
|
|
113
|
+
|
|
114
|
+
```json
|
|
115
|
+
{
|
|
116
|
+
"main": "./index.js",
|
|
117
|
+
"commitizenAdapter": {
|
|
118
|
+
"protocol": [1],
|
|
119
|
+
"bin": "./bin.js"
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
- `protocol` lists the protocol versions your adapter supports. commitizen picks
|
|
125
|
+
the highest version both support. It's an array so a future protocol 2 can be
|
|
126
|
+
added without dropping 1.
|
|
127
|
+
- `bin` is the program commitizen runs, relative to the package root. It runs
|
|
128
|
+
with the same Node.js as commitizen and with the user's terminal attached.
|
|
129
|
+
- `main` must point to a file that exists. commitizen finds every adapter with
|
|
130
|
+
`require.resolve()` before it reads `commitizenAdapter`. It never loads that
|
|
131
|
+
file for a protocol adapter.
|
|
132
|
+
|
|
133
|
+
commitizen sets these environment variables:
|
|
134
|
+
|
|
135
|
+
| Variable | Meaning |
|
|
136
|
+
|---|---|
|
|
137
|
+
| `CZ_PROTOCOL` | The protocol version commitizen chose, currently `1`. |
|
|
138
|
+
| `CZ_MESSAGE_FILE` | An empty file. Write the commit message to it. |
|
|
139
|
+
| `CZ_CONFIG_FILE` | A JSON file with the commitizen config, the same object `load()` returns, or `{}` if there is none. |
|
|
140
|
+
| `CZ_GIT_ROOT` | The repository root. |
|
|
141
|
+
|
|
142
|
+
How the program ends tells commitizen what to do:
|
|
143
|
+
|
|
144
|
+
| Exit status | Message file | commitizen |
|
|
145
|
+
|---|---|---|
|
|
146
|
+
| 0 | has a message | Commits it, including `--hook` and `--retry` support. |
|
|
147
|
+
| 0 | empty | Commits nothing and exits with 0 (the user cancelled). |
|
|
148
|
+
| not 0 | anything | Commits nothing and exits with the same status. Print your own error first. |
|
|
149
|
+
|
|
150
|
+
For Ctrl-C, exit with 130.
|
|
151
|
+
|
|
152
|
+
### Supporting old and new commitizen in one package
|
|
153
|
+
|
|
154
|
+
Keep `prompter` as the package's `main` export and add `commitizenAdapter`.
|
|
155
|
+
commitizen 5.1 and later run `bin`. Older versions ignore the field and call
|
|
156
|
+
`prompter`, as before. You don't need a major release for this.
|
|
157
|
+
|
|
158
|
+
If your prompts are written for Inquirer.js 8, you don't have to write them
|
|
159
|
+
twice. cz-conventional-changelog keeps its questions in the Inquirer.js 8
|
|
160
|
+
format. Its legacy `prompter` passes them to `cz.prompt()`, and its protocol
|
|
161
|
+
program asks the same questions with `@inquirer/prompts` through a small
|
|
162
|
+
function that maps each question onto `select`, `input` or `confirm`. See
|
|
163
|
+
[`protocol.js`](https://github.com/commitizen/cz-conventional-changelog/blob/master/protocol.js).
|
|
164
|
+
|
|
165
|
+
Expect some visible differences when you switch prompt libraries. For example,
|
|
166
|
+
`@inquirer/prompts` asks you to press Enter after answering a yes/no question.
|
|
167
|
+
|
|
168
|
+
### A minimal protocol adapter
|
|
169
|
+
|
|
170
|
+
[examples/protocol-adapter](../examples/protocol-adapter) is a complete
|
|
171
|
+
protocol adapter with no dependencies. Here is its core:
|
|
172
|
+
|
|
173
|
+
```js
|
|
174
|
+
import fs from 'node:fs';
|
|
175
|
+
|
|
176
|
+
const config = process.env.CZ_CONFIG_FILE
|
|
177
|
+
? JSON.parse(fs.readFileSync(process.env.CZ_CONFIG_FILE, 'utf8'))
|
|
178
|
+
: {};
|
|
179
|
+
|
|
180
|
+
const message = await askQuestions(config); // your prompts
|
|
181
|
+
|
|
182
|
+
if (process.env.CZ_MESSAGE_FILE) {
|
|
183
|
+
fs.writeFileSync(process.env.CZ_MESSAGE_FILE, message);
|
|
184
|
+
} else {
|
|
185
|
+
// Run on its own: print the message.
|
|
186
|
+
process.stdout.write(message + '\n');
|
|
187
|
+
}
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
### Testing
|
|
191
|
+
|
|
192
|
+
- Test the program as a child process. Set `CZ_MESSAGE_FILE` and
|
|
193
|
+
`CZ_CONFIG_FILE` to temporary files, then check the message file and the exit
|
|
194
|
+
status.
|
|
195
|
+
- Move the logic into functions you can import and pass fake prompts to them.
|
|
196
|
+
Prompt libraries usually need a real terminal.
|
|
197
|
+
- To try it with commitizen, set `"path"` in a test repository's `.czrc` to
|
|
198
|
+
your adapter's directory, stage a file and run `npx --no -- cz`.
|
|
199
|
+
|
|
200
|
+
## Checklist
|
|
201
|
+
|
|
202
|
+
- [ ] Runs on Node.js 22, 24 and 26.
|
|
203
|
+
- [ ] Reads config with `@commitizen/config` (or from `CZ_CONFIG_FILE`), not
|
|
204
|
+
`require('commitizen')`.
|
|
205
|
+
- [ ] `commitizen` is not in `dependencies`. The README tells users to install
|
|
206
|
+
it.
|
|
207
|
+
- [ ] Anything you `require()` or `import` is in your own `dependencies`,
|
|
208
|
+
including cz-conventional-changelog.
|
|
209
|
+
- [ ] Optional: `commitizenAdapter` added, with `prompter` kept for commitizen
|
|
210
|
+
5.0 and earlier.
|
|
211
|
+
|
|
212
|
+
Questions or problems: [open an issue](https://github.com/commitizen/cz-cli/issues).
|
package/junit-testresults.xml
CHANGED
|
@@ -1,144 +1,147 @@
|
|
|
1
|
-
<testsuite name="Mocha Tests" tests="
|
|
2
|
-
<testcase classname="adapter" name="resolves adapter paths" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="
|
|
3
|
-
<testcase classname="adapter" name="
|
|
4
|
-
<testcase classname="adapter" name="
|
|
5
|
-
<testcase classname="adapter" name="gets adapter prompter functions
|
|
1
|
+
<testsuite name="Mocha Tests" tests="153" failures="0" errors="0" skipped="0" timestamp="Sun, 06 Dec 2026 01:42:27 GMT" time="64.926">
|
|
2
|
+
<testcase classname="adapter" name="resolves adapter paths" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="3.19"/>
|
|
3
|
+
<testcase classname="adapter" name="suggests installing an adapter that is not installed" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.014"/>
|
|
4
|
+
<testcase classname="adapter" name="resolves scoped adapter paths" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.366"/>
|
|
5
|
+
<testcase classname="adapter" name="gets adapter prompter functions" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="2.359"/>
|
|
6
|
+
<testcase classname="adapter" name="gets adapter prompter functions for default export adapters" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.974"/>
|
|
6
7
|
<testcase classname="adapter (unit) getInstallStringMappings" name="maps npm flags" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
7
8
|
<testcase classname="adapter (unit) getInstallStringMappings" name="uses --save for a prod install (save without saveDev)" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
8
9
|
<testcase classname="adapter (unit) getInstallStringMappings" name="maps yarn flags" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
9
10
|
<testcase classname="adapter (unit) getInstallStringMappings" name="maps pnpm flags and always ignores dependency build scripts" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
10
|
-
<testcase classname="adapter (unit) getInstallStringMappings" name="pnpm adds --save-exact for either `exact` or `saveExact`" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
11
|
+
<testcase classname="adapter (unit) getInstallStringMappings" name="pnpm adds --save-exact for either `exact` or `saveExact`" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
11
12
|
<testcase classname="adapter (unit) getInstallStringMappings" name="falls back to the npm mapping for an unknown package manager" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
12
13
|
<testcase classname="adapter (unit) generateInstallAdapterCommand" name="builds an npm install command by default" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
13
14
|
<testcase classname="adapter (unit) generateInstallAdapterCommand" name="builds a yarn add command" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
14
|
-
<testcase classname="adapter (unit) generateInstallAdapterCommand" name="builds a pnpm add command" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
15
|
+
<testcase classname="adapter (unit) generateInstallAdapterCommand" name="builds a pnpm add command" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
15
16
|
<testcase classname="adapter (unit) generateInstallAdapterCommand" name="falls back to "install" for an unrecognised package manager" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
16
|
-
<testcase classname="adapter (unit) getNearestNodeModulesDirectory" name="searches from the current directory when no options are given" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
17
|
-
<testcase classname="adapter (unit) getNearestNodeModulesDirectory" name="accepts a directory string" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
18
|
-
<testcase classname="adapter (unit) getNearestNodeModulesDirectory" name="accepts an options object with cwd" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
19
|
-
<testcase classname="adapter (unit) addPathToAdapterConfig" name="adds config.commitizen.path, preserving the detected indentation" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
20
|
-
<testcase classname="adapter (unit) addPathToAdapterConfig" name="falls back to a two-space indent when none can be detected" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
21
|
-
<testcase classname="adapter (unit) addPathToAdapterConfig" name="leaves package.json untouched when the bare adapter name is already configured" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
22
|
-
<testcase classname="adapter (unit) addPathToAdapterConfig" name="leaves package.json untouched when the ./node_modules adapter path is already configured" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
23
|
-
<testcase classname="commitizen cache" name="creates the cache file when setting a value for the first time" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
24
|
-
<testcase classname="commitizen cache" name="merges into an existing cache instead of clobbering it" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0
|
|
25
|
-
<testcase classname="commitizen cache" name="overwrites the value for a key that already exists" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0
|
|
26
|
-
<testcase classname="commitizen cache" name="reads a stored value back by key" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
27
|
-
<testcase classname="commitizen cache" name="returns undefined for a missing key" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0
|
|
17
|
+
<testcase classname="adapter (unit) getNearestNodeModulesDirectory" name="searches from the current directory when no options are given" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.032"/>
|
|
18
|
+
<testcase classname="adapter (unit) getNearestNodeModulesDirectory" name="accepts a directory string" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.023"/>
|
|
19
|
+
<testcase classname="adapter (unit) getNearestNodeModulesDirectory" name="accepts an options object with cwd" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.039"/>
|
|
20
|
+
<testcase classname="adapter (unit) addPathToAdapterConfig" name="adds config.commitizen.path, preserving the detected indentation" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.028"/>
|
|
21
|
+
<testcase classname="adapter (unit) addPathToAdapterConfig" name="falls back to a two-space indent when none can be detected" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.021"/>
|
|
22
|
+
<testcase classname="adapter (unit) addPathToAdapterConfig" name="leaves package.json untouched when the bare adapter name is already configured" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.02"/>
|
|
23
|
+
<testcase classname="adapter (unit) addPathToAdapterConfig" name="leaves package.json untouched when the ./node_modules adapter path is already configured" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.021"/>
|
|
24
|
+
<testcase classname="commitizen cache" name="creates the cache file when setting a value for the first time" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
25
|
+
<testcase classname="commitizen cache" name="merges into an existing cache instead of clobbering it" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
26
|
+
<testcase classname="commitizen cache" name="overwrites the value for a key that already exists" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
27
|
+
<testcase classname="commitizen cache" name="reads a stored value back by key" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
28
|
+
<testcase classname="commitizen cache" name="returns undefined for a missing key" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
28
29
|
<testcase classname="commitizen cache" name="returns undefined (rather than throwing) when the cache file does not exist" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
29
30
|
<testcase classname="commitizen cache" name="throws from readCacheSync when the cache file does not exist" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
30
31
|
<testcase classname="cli git-cz bootstrap when config is provided" name="passes config to useGitCzStrategy" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
31
32
|
<testcase classname="cli git-cz bootstrap when config is not provided and the config is returned from configLoader.load" name="uses config from configLoader.load()" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
32
33
|
<testcase classname="cli git-cz bootstrap when config is not provided and the config is not returned from configLoader.load" name="tells commitizen to use the git strategy" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
33
|
-
<testcase classname="cli git-cz bootstrap when argv is overridden" name="uses the overridden argv" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0
|
|
34
|
-
<testcase classname="cli git-cz bootstrap when called with no arguments" name="defaults environment to {} and argv to process.argv" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0
|
|
35
|
-
<testcase classname="cli commitizen" name="slices argv down to the raw git args before parsing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
36
|
-
<testcase classname="cli commitizen" name="defaults environment and argv when called with no arguments" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
34
|
+
<testcase classname="cli git-cz bootstrap when argv is overridden" name="uses the overridden argv" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
35
|
+
<testcase classname="cli git-cz bootstrap when called with no arguments" name="defaults environment to {} and argv to process.argv" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
36
|
+
<testcase classname="cli commitizen" name="slices argv down to the raw git args before parsing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
37
|
+
<testcase classname="cli commitizen" name="defaults environment and argv when called with no arguments" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
37
38
|
<testcase classname="cli commitizen init command" name="calls init() with cwd, the adapter name and the parsed args" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
38
|
-
<testcase classname="cli commitizen init command" name="logs, but does not throw, when init() fails" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
39
|
-
<testcase classname="cli commitizen init command" name="errors when no adapter name is provided" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
39
|
+
<testcase classname="cli commitizen init command" name="logs, but does not throw, when init() fails" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
40
|
+
<testcase classname="cli commitizen init command" name="errors when no adapter name is provided" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
40
41
|
<testcase classname="cli commitizen any other invocation" name="prints usage help and runs no command" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
41
42
|
<testcase classname="cli commitizen any other invocation" name="prints usage help for an unknown command" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
42
43
|
<testcase classname="cli strategies barrel" name="re-exports the git and git-cz strategies" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
43
44
|
<testcase classname="cli parsers barrel" name="re-exports the git-cz and commitizen parsers" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
44
|
-
<testcase classname="cli strategies/git" name="spawns "git commit" with the raw args and inherited stdio" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
45
|
-
<testcase classname="cli strategies/git" name="rethrows when the child process emits an error" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
45
|
+
<testcase classname="cli strategies/git" name="spawns "git commit" with the raw args and inherited stdio" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
46
|
+
<testcase classname="cli strategies/git" name="rethrows when the child process emits an error" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
46
47
|
<testcase classname="cli strategies/git" name="does not spawn git in debug mode, it just logs" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
47
|
-
<testcase classname="cli strategies/git-cz" name="delegates to the plain git strategy when --amend is present" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0
|
|
48
|
-
<testcase classname="cli strategies/git-cz" name="runs the commit flow, wiring the prompter and options through" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
48
|
+
<testcase classname="cli strategies/git-cz" name="delegates to the plain git strategy when --amend is present" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
49
|
+
<testcase classname="cli strategies/git-cz" name="runs the commit flow, wiring the prompter and options through" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.004"/>
|
|
49
50
|
<testcase classname="cli strategies/git-cz" name="flags retryLastCommit when the first arg is --retry" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
50
|
-
<testcase classname="cli strategies/git-cz" name="flags hookMode when --hook was parsed" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0
|
|
51
|
+
<testcase classname="cli strategies/git-cz" name="flags hookMode when --hook was parsed" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
51
52
|
<testcase classname="cli strategies/git-cz" name="stages all files when -a / --all is passed" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
52
|
-
<testcase classname="cli strategies/git-cz" name="throws when the staging area is clean and --allow-empty is absent" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
53
|
+
<testcase classname="cli strategies/git-cz" name="throws when the staging area is clean and --allow-empty is absent" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
53
54
|
<testcase classname="cli strategies/git-cz" name="proceeds when the staging area is clean but --allow-empty is present" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
54
55
|
<testcase classname="cli strategies/git-cz" name="rethrows an error from the staging check" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
55
|
-
<testcase classname="cli strategies/git-cz" name="rethrows an error surfaced by the commit callback" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
56
|
-
<testcase classname="cli strategies/git-cz" name="exits with code 0 when the commit succeeds" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
57
|
-
<testcase classname="commit" name="should commit simple messages" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="
|
|
58
|
-
<testcase classname="commit" name="should commit message with quotes" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.
|
|
59
|
-
<testcase classname="commit" name="should commit multiline messages" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="
|
|
60
|
-
<testcase classname="commit" name="should allow to override git commit options" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.
|
|
61
|
-
<testcase classname="commit" name="should respect original behavior of -a option" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.
|
|
62
|
-
<testcase classname="commit" name="should save directly to .git/COMMIT_EDITMSG with --hook option" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.
|
|
63
|
-
<testcase classname="commit" name="should throw error if staging area is empty" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.
|
|
64
|
-
<testcase classname="commitizen commit (unit)" name="logs and bails when the cache directory cannot be created" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
65
|
-
<testcase classname="commitizen commit (unit)" name="runs the prompter and commits the message it returns, caching the attempt" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
66
|
-
<testcase classname="commitizen commit (unit)" name="propagates an Error raised by the adapter prompter without committing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
67
|
-
<testcase classname="commitizen commit (unit)" name="replays the previous attempt from cache when retryLastCommit is set" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.
|
|
68
|
-
<testcase classname="
|
|
69
|
-
<testcase classname="
|
|
70
|
-
<testcase classname="
|
|
71
|
-
<testcase classname="
|
|
72
|
-
<testcase classname="
|
|
73
|
-
<testcase classname="
|
|
74
|
-
<testcase classname="
|
|
75
|
-
<testcase classname="
|
|
76
|
-
<testcase classname="
|
|
77
|
-
<testcase classname="
|
|
78
|
-
<testcase classname="
|
|
79
|
-
<testcase classname="
|
|
80
|
-
<testcase classname="
|
|
81
|
-
<testcase classname="
|
|
82
|
-
<testcase classname="
|
|
83
|
-
<testcase classname="
|
|
84
|
-
<testcase classname="
|
|
85
|
-
<testcase classname="
|
|
86
|
-
<testcase classname="
|
|
87
|
-
<testcase classname="
|
|
88
|
-
<testcase classname="
|
|
89
|
-
<testcase classname="
|
|
90
|
-
<testcase classname="
|
|
91
|
-
<testcase classname="
|
|
92
|
-
<testcase classname="
|
|
93
|
-
<testcase classname="
|
|
94
|
-
<testcase classname="
|
|
95
|
-
<testcase classname="
|
|
96
|
-
<testcase classname="
|
|
97
|
-
<testcase classname="
|
|
98
|
-
<testcase classname="
|
|
99
|
-
<testcase classname="
|
|
100
|
-
<testcase classname="init" name="installs an adapter
|
|
101
|
-
<testcase classname="init" name="installs an adapter with --
|
|
102
|
-
<testcase classname="init" name="
|
|
103
|
-
<testcase classname="init" name="
|
|
104
|
-
<testcase classname="init" name="installs
|
|
105
|
-
<testcase classname="init" name="
|
|
106
|
-
<testcase classname="init" name="installs
|
|
107
|
-
<testcase classname="init
|
|
108
|
-
<testcase classname="init
|
|
109
|
-
<testcase classname="init
|
|
110
|
-
<testcase classname="init alternative package managers: yarn" name="succeeds (with yarn) if force is true" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="3.319"/>
|
|
111
|
-
<testcase classname="init alternative package managers: yarn" name="installs (with yarn) an adapter without --save-exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.566"/>
|
|
112
|
-
<testcase classname="init alternative package managers: yarn" name="installs an adapter with yarn --exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.501"/>
|
|
113
|
-
<testcase classname="init alternative package managers: pnpm" name="installs an adapter with pnpm" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.4"/>
|
|
114
|
-
<testcase classname="init alternative package managers: pnpm" name="installs an adapter with pnpm --dev" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.12"/>
|
|
115
|
-
<testcase classname="init alternative package managers: pnpm" name="errors (with pnpm) on previously installed adapter" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.118"/>
|
|
116
|
-
<testcase classname="init alternative package managers: pnpm" name="succeeds (with pnpm) if force is true" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.333"/>
|
|
117
|
-
<testcase classname="init alternative package managers: pnpm" name="installs (with pnpm) an adapter without --save-exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.128"/>
|
|
118
|
-
<testcase classname="init alternative package managers: pnpm" name="installs an adapter with pnpm --exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.119"/>
|
|
119
|
-
<testcase classname="commitizen init (unit)" name="throws when the repo path or adapter name is missing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.012"/>
|
|
120
|
-
<testcase classname="commitizen init (unit)" name="swallows and logs an install failure instead of throwing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.022"/>
|
|
121
|
-
<testcase classname="commitizen init (unit)" name="also installs commitizen when includeCommitizen is set" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.009"/>
|
|
122
|
-
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="defaults to a dev install" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.01"/>
|
|
123
|
-
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="--save installs to dependencies, not devDependencies" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.01"/>
|
|
124
|
-
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="--save-dev --save-exact pins an exact dev install with npm" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.009"/>
|
|
125
|
-
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="--pnpm --save-dev --save-exact pins an exact dev install with pnpm" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.01"/>
|
|
126
|
-
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="--yarn --dev --exact pins an exact dev install with yarn" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.009"/>
|
|
56
|
+
<testcase classname="cli strategies/git-cz" name="rethrows an error surfaced by the commit callback" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.013"/>
|
|
57
|
+
<testcase classname="cli strategies/git-cz" name="exits with code 0 when the commit succeeds" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.017"/>
|
|
58
|
+
<testcase classname="commit" name="should commit simple messages" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="2.182"/>
|
|
59
|
+
<testcase classname="commit" name="should commit message with quotes" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.344"/>
|
|
60
|
+
<testcase classname="commit" name="should commit multiline messages" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="2.304"/>
|
|
61
|
+
<testcase classname="commit" name="should allow to override git commit options" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.365"/>
|
|
62
|
+
<testcase classname="commit" name="should respect original behavior of -a option" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.362"/>
|
|
63
|
+
<testcase classname="commit" name="should save directly to .git/COMMIT_EDITMSG with --hook option" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.357"/>
|
|
64
|
+
<testcase classname="commit" name="should throw error if staging area is empty" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.342"/>
|
|
65
|
+
<testcase classname="commitizen commit (unit)" name="logs and bails when the cache directory cannot be created" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.013"/>
|
|
66
|
+
<testcase classname="commitizen commit (unit)" name="runs the prompter and commits the message it returns, caching the attempt" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.015"/>
|
|
67
|
+
<testcase classname="commitizen commit (unit)" name="propagates an Error raised by the adapter prompter without committing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.022"/>
|
|
68
|
+
<testcase classname="commitizen commit (unit)" name="replays the previous attempt from cache when retryLastCommit is set" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.016"/>
|
|
69
|
+
<testcase classname="git helpers log" name="passes stdout to the callback on success" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.005"/>
|
|
70
|
+
<testcase classname="git helpers log" name="throws when git errors" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.005"/>
|
|
71
|
+
<testcase classname="git helpers whatChanged" name="passes stdout to the callback on success" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.005"/>
|
|
72
|
+
<testcase classname="git helpers whatChanged" name="throws when git errors" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.005"/>
|
|
73
|
+
<testcase classname="git helpers commit (non-hook mode)" name="spawns "git commit -m <message>" plus any extra args" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.011"/>
|
|
74
|
+
<testcase classname="git helpers commit (non-hook mode)" name="inherits stdio when not quiet" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.016"/>
|
|
75
|
+
<testcase classname="git helpers commit (non-hook mode)" name="reports child-process errors through the callback" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.011"/>
|
|
76
|
+
<testcase classname="git helpers commit (non-hook mode)" name="only calls the callback once even if error fires repeatedly and exit follows" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.011"/>
|
|
77
|
+
<testcase classname="git helpers commit (non-hook mode)" name="resolves with null on a zero exit code" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.01"/>
|
|
78
|
+
<testcase classname="git helpers commit (non-hook mode)" name="warns about git config and errors on exit code 128" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.011"/>
|
|
79
|
+
<testcase classname="git helpers commit (non-hook mode)" name="errors (without the config warning) on a non-128 non-zero exit code" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.011"/>
|
|
80
|
+
<testcase classname="git helpers commit (--hook mode)" name="writes the message to <git-dir>/COMMIT_EDITMSG" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.011"/>
|
|
81
|
+
<testcase classname="git helpers commit (--hook mode)" name="falls back to "r+" when the file cannot be opened for "w" (Windows hidden files)" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.011"/>
|
|
82
|
+
<testcase classname="git helpers commit (--hook mode)" name="reports the error (and still closes the fd) when the write fails" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.012"/>
|
|
83
|
+
<testcase classname="git helpers commit (--hook mode)" name="reports the error when even the "r+" fallback fails" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.011"/>
|
|
84
|
+
<testcase classname="init" name="installs an adapter with --save-dev" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="2.245"/>
|
|
85
|
+
<testcase classname="init" name="installs an adapter with --save" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="2.233"/>
|
|
86
|
+
<testcase classname="init" name="errors on previously installed adapter" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="2.285"/>
|
|
87
|
+
<testcase classname="init" name="succeeds if force is true" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="3.682"/>
|
|
88
|
+
<testcase classname="init" name="installs an adapter without --save-exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="2.304"/>
|
|
89
|
+
<testcase classname="init" name="installs an adapter with --save-exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="2.314"/>
|
|
90
|
+
<testcase classname="init" name="installs an commitizen with includeCommitizen" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="5.919"/>
|
|
91
|
+
<testcase classname="init alternative package managers: yarn" name="installs an adapter with yarn" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="3.962"/>
|
|
92
|
+
<testcase classname="init alternative package managers: yarn" name="installs an adapter with yarn --dev" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.613"/>
|
|
93
|
+
<testcase classname="init alternative package managers: yarn" name="errors (with yarn) on previously installed adapter" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.59"/>
|
|
94
|
+
<testcase classname="init alternative package managers: yarn" name="succeeds (with yarn) if force is true" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="4.302"/>
|
|
95
|
+
<testcase classname="init alternative package managers: yarn" name="installs (with yarn) an adapter without --save-exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.55"/>
|
|
96
|
+
<testcase classname="init alternative package managers: yarn" name="installs an adapter with yarn --exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="1.618"/>
|
|
97
|
+
<testcase classname="init alternative package managers: pnpm" name="installs an adapter with pnpm" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.532"/>
|
|
98
|
+
<testcase classname="init alternative package managers: pnpm" name="installs an adapter with pnpm --dev" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.202"/>
|
|
99
|
+
<testcase classname="init alternative package managers: pnpm" name="errors (with pnpm) on previously installed adapter" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.196"/>
|
|
100
|
+
<testcase classname="init alternative package managers: pnpm" name="succeeds (with pnpm) if force is true" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.536"/>
|
|
101
|
+
<testcase classname="init alternative package managers: pnpm" name="installs (with pnpm) an adapter without --save-exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.197"/>
|
|
102
|
+
<testcase classname="init alternative package managers: pnpm" name="installs an adapter with pnpm --exact" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.195"/>
|
|
103
|
+
<testcase classname="commitizen init (unit)" name="throws when the repo path or adapter name is missing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.015"/>
|
|
104
|
+
<testcase classname="commitizen init (unit)" name="swallows and logs an install failure instead of throwing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.029"/>
|
|
105
|
+
<testcase classname="commitizen init (unit)" name="also installs commitizen when includeCommitizen is set" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.015"/>
|
|
106
|
+
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="defaults to a dev install" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.016"/>
|
|
107
|
+
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="--save installs to dependencies, not devDependencies" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.015"/>
|
|
108
|
+
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="--save-dev --save-exact pins an exact dev install with npm" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.016"/>
|
|
109
|
+
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="--pnpm --save-dev --save-exact pins an exact dev install with pnpm" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.015"/>
|
|
110
|
+
<testcase classname="commitizen init (unit) install command built from real CLI arguments" name="--yarn --dev --exact pins an exact dev install with yarn" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.014"/>
|
|
127
111
|
<testcase classname="parsers git-cz" name="should parse --message "Hello, World!"" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
128
112
|
<testcase classname="parsers git-cz" name="should parse --message="Hello, World!"" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
129
113
|
<testcase classname="parsers git-cz" name="should parse -amwip" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
130
114
|
<testcase classname="parsers git-cz" name="should parse -am=wip" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
131
115
|
<testcase classname="parsers git-cz" name="should parse -am wip" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
132
|
-
<testcase classname="parsers git-cz" name="should parse -a -m wip -n" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
116
|
+
<testcase classname="parsers git-cz" name="should parse -a -m wip -n" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
133
117
|
<testcase classname="parsers git-cz" name="should parse -a -m=wip -n" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
134
|
-
<testcase classname="parsers commitizen" name="should parse out the --amend option" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
118
|
+
<testcase classname="parsers commitizen" name="should parse out the --amend option" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
135
119
|
<testcase classname="parsers commitizen" name="should parse out the --hook option" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
136
120
|
<testcase classname="parsers commitizen" name="should expose kebab-case init flags under the camelCase names init() reads" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
137
|
-
<testcase classname="
|
|
138
|
-
<testcase classname="
|
|
121
|
+
<testcase classname="adapter protocol getProtocolDeclaration" name="reads the declaration from the adapter package.json" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
122
|
+
<testcase classname="adapter protocol getProtocolDeclaration" name="returns undefined for a legacy adapter" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
123
|
+
<testcase classname="adapter protocol getProtocolDeclaration" name="returns undefined when there is no package.json" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
124
|
+
<testcase classname="adapter protocol getProtocolDeclaration" name="ignores a commitizenAdapter field that is not an object" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
125
|
+
<testcase classname="adapter protocol getProtocolDeclaration" name="throws for an invalid declaration" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
126
|
+
<testcase classname="adapter protocol getProtocolDeclaration" name="names the adapter by its directory when package.json has no name" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
127
|
+
<testcase classname="adapter protocol chooseProtocol" name="supports protocol 1" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
128
|
+
<testcase classname="adapter protocol chooseProtocol" name="picks the highest version both sides support" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
129
|
+
<testcase classname="adapter protocol chooseProtocol" name="throws when there is no shared version" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
130
|
+
<testcase classname="adapter protocol createProtocolPrompter" name="commits the message the adapter writes" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.69"/>
|
|
131
|
+
<testcase classname="adapter protocol createProtocolPrompter" name="passes the protocol version, git root and config, and cleans up" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.674"/>
|
|
132
|
+
<testcase classname="adapter protocol createProtocolPrompter" name="passes an empty config when there is none" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.674"/>
|
|
133
|
+
<testcase classname="adapter protocol createProtocolPrompter" name="commits nothing when the adapter writes no message" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.668"/>
|
|
134
|
+
<testcase classname="adapter protocol createProtocolPrompter" name="exits with the adapter exit status when it fails" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.7"/>
|
|
135
|
+
<testcase classname="adapter protocol createProtocolPrompter" name="exits with 1 when the adapter is killed by a signal" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
136
|
+
<testcase classname="adapter protocol createProtocolPrompter" name="reports an adapter that cannot be started, once" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
137
|
+
<testcase classname="adapter protocol createProtocolPrompter" name="throws for an adapter whose protocol commitizen does not support" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
138
|
+
<testcase classname="adapter protocol getPrompter" name="returns a protocol prompter for a protocol adapter" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.008"/>
|
|
139
|
+
<testcase classname="adapter protocol getPrompter" name="still loads legacy adapters with require()" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.008"/>
|
|
140
|
+
<testcase classname="adapter protocol committing through commitizen" name="makes a git commit with the adapter message" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.689"/>
|
|
141
|
+
<testcase classname="staging" name="should determine if a repo is clean" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.029"/>
|
|
142
|
+
<testcase classname="staging" name="should determine if --all flag adds files to staging area" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.016"/>
|
|
139
143
|
<testcase classname="common util" name="isFunction determines if a function is passed" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
140
|
-
<testcase classname="common util" name="
|
|
141
|
-
<testcase classname="common util getParsedJsonFromFile" name="parses the JSON contents of a file" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
144
|
+
<testcase classname="common util getParsedJsonFromFile" name="parses the JSON contents of a file" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
142
145
|
<testcase classname="common util getParsedJsonFromFile" name="logs and returns undefined when the file is missing" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
143
146
|
<testcase classname="common util getParsedJsonFromFile" name="logs and returns undefined when the file is not valid JSON" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
144
147
|
<testcase classname="common util getParsedJsonFromFile" name="getParsedPackageJsonFromPath reads package.json from a directory" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
@@ -148,5 +151,5 @@
|
|
|
148
151
|
<testcase classname="common util directory finders" name="findNearestNodeModules returns node_modules in the starting directory" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
149
152
|
<testcase classname="common util directory finders" name="findNearestNodeModules walks up and returns a path relative to the start" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
150
153
|
<testcase classname="common util directory finders" name="findNearestNodeModules defaults to the current working directory" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
151
|
-
<testcase classname="common util directory finders" name="findNearestNodeModules returns undefined when there is no node_modules" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0"/>
|
|
154
|
+
<testcase classname="common util directory finders" name="findNearestNodeModules returns undefined when there is no node_modules" file="/home/runner/work/cz-cli/cz-cli/test/tests/index.js" time="0.001"/>
|
|
152
155
|
</testsuite>
|