@platformatic/generators 1.13.2 → 1.13.4
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/lib/base-generator.js +2 -0
- package/package.json +1 -1
- package/test/base-generator.test.js +27 -0
package/lib/base-generator.js
CHANGED
package/package.json
CHANGED
|
@@ -143,6 +143,33 @@ test('setConfig', async (t) => {
|
|
|
143
143
|
envPrefix: '',
|
|
144
144
|
tests: false
|
|
145
145
|
})
|
|
146
|
+
|
|
147
|
+
// update only some fields
|
|
148
|
+
bg.setConfig({
|
|
149
|
+
hostname: '123.123.123.123',
|
|
150
|
+
port: 3000
|
|
151
|
+
})
|
|
152
|
+
|
|
153
|
+
bg.setConfig({
|
|
154
|
+
port: 1234
|
|
155
|
+
})
|
|
156
|
+
|
|
157
|
+
assert.deepEqual(bg.config, {
|
|
158
|
+
port: 1234,
|
|
159
|
+
hostname: '123.123.123.123',
|
|
160
|
+
plugin: false,
|
|
161
|
+
typescript: false,
|
|
162
|
+
initGitRepository: false,
|
|
163
|
+
staticWorkspaceGitHubActions: false,
|
|
164
|
+
dynamicWorkspaceGitHubActions: false,
|
|
165
|
+
env: {},
|
|
166
|
+
dependencies: {},
|
|
167
|
+
devDependencies: {},
|
|
168
|
+
isRuntimeContext: false,
|
|
169
|
+
serviceName: '',
|
|
170
|
+
envPrefix: '',
|
|
171
|
+
tests: false
|
|
172
|
+
})
|
|
146
173
|
})
|
|
147
174
|
|
|
148
175
|
test('should append env values', async (t) => {
|