@wordpress/env 10.15.0 → 10.16.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.
|
@@ -144,7 +144,7 @@ async function parseConfig( configDirectoryPath, cacheDirectoryPath ) {
|
|
|
144
144
|
} );
|
|
145
145
|
|
|
146
146
|
// Users can provide overrides in environment
|
|
147
|
-
// variables that
|
|
147
|
+
// variables that supersede all other options.
|
|
148
148
|
const environmentVarOverrides =
|
|
149
149
|
getEnvironmentVarOverrides( cacheDirectoryPath );
|
|
150
150
|
|
|
@@ -129,7 +129,7 @@ function appendPortToWPConfigs( config ) {
|
|
|
129
129
|
*/
|
|
130
130
|
function validatePortUniqueness( config ) {
|
|
131
131
|
// We're going to build a map of the environments and their port
|
|
132
|
-
// so we can
|
|
132
|
+
// so we can accommodate root-level config options more easily.
|
|
133
133
|
const environmentPorts = {};
|
|
134
134
|
|
|
135
135
|
// Add all of the environments to the map. This will
|
|
@@ -179,7 +179,7 @@ function validate( config ) {
|
|
|
179
179
|
* @return {WPRootConfig} A deep copy of the root config object.
|
|
180
180
|
*/
|
|
181
181
|
function deepCopyRootOptions( config ) {
|
|
182
|
-
// Create a shallow clone of the object first so we can operate on it
|
|
182
|
+
// Create a shallow clone of the object first so we can operate on it safely.
|
|
183
183
|
const rootConfig = Object.assign( {}, config );
|
|
184
184
|
|
|
185
185
|
// Since we're only dealing with the root options we don't want the environments.
|
|
@@ -306,7 +306,7 @@ describe( 'validate-config', () => {
|
|
|
306
306
|
} );
|
|
307
307
|
|
|
308
308
|
describe( 'checkValidURL', () => {
|
|
309
|
-
it( 'throws for
|
|
309
|
+
it( 'throws for invalid URLs', () => {
|
|
310
310
|
expect( () =>
|
|
311
311
|
checkValidURL( 'test.json', 'test', 'localhost' )
|
|
312
312
|
).toThrow(
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wordpress/env",
|
|
3
|
-
"version": "10.
|
|
3
|
+
"version": "10.16.0",
|
|
4
4
|
"description": "A zero-config, self contained local WordPress environment for development and testing.",
|
|
5
5
|
"author": "The WordPress Contributors",
|
|
6
6
|
"license": "GPL-2.0-or-later",
|
|
@@ -55,5 +55,5 @@
|
|
|
55
55
|
"scripts": {
|
|
56
56
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
|
57
57
|
},
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "f48b9f56629e400891abb5ae491504de475237ff"
|
|
59
59
|
}
|