@netlify/build 29.37.0 → 29.37.2
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.
|
@@ -112,6 +112,35 @@ test('`getExpectedVersion` should retrieve the plugin based on conditions and fe
|
|
|
112
112
|
});
|
|
113
113
|
expect(version3).toBe('5.0.0-beta.1');
|
|
114
114
|
});
|
|
115
|
+
test('`getExpectedVersion` should work with rc versions inside the siteDependencies constraints', async () => {
|
|
116
|
+
const versions = [
|
|
117
|
+
{
|
|
118
|
+
version: '5.0.0-beta.1',
|
|
119
|
+
conditions: [
|
|
120
|
+
{ type: 'nodeVersion', condition: '>= 18.0.0' },
|
|
121
|
+
{ type: 'siteDependencies', condition: { next: '>=13.5.0' } },
|
|
122
|
+
],
|
|
123
|
+
overridePinnedVersion: '>=4.0.0',
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
version: '4.42.0',
|
|
127
|
+
conditions: [{ type: 'siteDependencies', condition: { next: '>=10.0.9' } }],
|
|
128
|
+
},
|
|
129
|
+
{ version: '4.41.2', conditions: [] },
|
|
130
|
+
{
|
|
131
|
+
version: '3.9.2',
|
|
132
|
+
conditions: [{ type: 'siteDependencies', condition: { next: '<10.0.9' } }],
|
|
133
|
+
},
|
|
134
|
+
];
|
|
135
|
+
const { version } = await getExpectedVersion({
|
|
136
|
+
versions,
|
|
137
|
+
nodeVersion: '18.19.0',
|
|
138
|
+
packageJson: { dependencies: { next: '14.1.1-canary.36' } },
|
|
139
|
+
buildDir: '/some/path',
|
|
140
|
+
pinnedVersion: '4',
|
|
141
|
+
});
|
|
142
|
+
expect(version).toBe('5.0.0-beta.1');
|
|
143
|
+
});
|
|
115
144
|
test('`getExpectedVersion` should retrieve the plugin based on conditions and feature flag due to pinned version', async () => {
|
|
116
145
|
const versions = [
|
|
117
146
|
{
|
|
@@ -34,7 +34,7 @@ const siteDependencyTest = async function ({ dependencyName, allowedVersion, sit
|
|
|
34
34
|
}
|
|
35
35
|
// if this is a valid version we can apply the rule directly
|
|
36
36
|
if (semver.clean(siteDependency) !== null) {
|
|
37
|
-
return semver.satisfies(siteDependency, allowedVersion);
|
|
37
|
+
return semver.satisfies(siteDependency, allowedVersion, { includePrerelease: true });
|
|
38
38
|
}
|
|
39
39
|
try {
|
|
40
40
|
// if this is a range we need to get the exact version
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@netlify/build",
|
|
3
|
-
"version": "29.37.
|
|
3
|
+
"version": "29.37.2",
|
|
4
4
|
"description": "Netlify build module",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": "./lib/index.js",
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
"@netlify/functions-utils": "^5.2.51",
|
|
77
77
|
"@netlify/git-utils": "^5.1.1",
|
|
78
78
|
"@netlify/opentelemetry-utils": "^1.1.0",
|
|
79
|
-
"@netlify/plugins-list": "^6.
|
|
79
|
+
"@netlify/plugins-list": "^6.77.0",
|
|
80
80
|
"@netlify/run-utils": "^5.1.1",
|
|
81
81
|
"@netlify/zip-it-and-ship-it": "9.29.2",
|
|
82
82
|
"@sindresorhus/slugify": "^2.0.0",
|
|
@@ -164,5 +164,5 @@
|
|
|
164
164
|
"engines": {
|
|
165
165
|
"node": "^14.16.0 || >=16.0.0"
|
|
166
166
|
},
|
|
167
|
-
"gitHead": "
|
|
167
|
+
"gitHead": "5532a6654b3b644da7b7f348a7b71ed2f7285494"
|
|
168
168
|
}
|