mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-03-05 05:18:44 -05:00
fix: ignore block order for all upcoming blocks (#55546)
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
"isUpcomingChange": false,
|
||||
"usesMultifileEditor": true,
|
||||
"dashedName": "build-a-polygon-area-calculator-project",
|
||||
"order": 15,
|
||||
"order": 16,
|
||||
"superBlock": "scientific-computing-with-python",
|
||||
"challengeOrder": [
|
||||
{
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
"isUpcomingChange": false,
|
||||
"usesMultifileEditor": true,
|
||||
"dashedName": "build-a-probability-calculator-project",
|
||||
"order": 17,
|
||||
"order": 18,
|
||||
"superBlock": "scientific-computing-with-python",
|
||||
"challengeOrder": [
|
||||
{
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
"usesMultifileEditor": true,
|
||||
"hasEditableBoundaries": true,
|
||||
"dashedName": "learn-encapsulation-by-building-a-projectile-trajectory-calculator",
|
||||
"order": 16,
|
||||
"order": 17,
|
||||
"superBlock": "scientific-computing-with-python",
|
||||
"challengeOrder": [
|
||||
{
|
||||
|
||||
@@ -282,16 +282,8 @@ function populateTestsForLang({ lang, challenges, meta, superBlocks }) {
|
||||
|
||||
if (!process.env.FCC_BLOCK && !process.env.FCC_CHALLENGE_ID) {
|
||||
describe('Assert meta order', function () {
|
||||
/** This array can be used to skip a superblock - we'll use this
|
||||
* when we are working on the new project-based curriculum for
|
||||
* a superblock (because keeping those challenges in order is
|
||||
* tricky and needs cleaning up before deploying).
|
||||
*/
|
||||
const superBlocksUnderDevelopment = ['scientific-computing-with-python'];
|
||||
const superBlocks = new Set([
|
||||
...Object.values(meta)
|
||||
.map(el => el.superBlock)
|
||||
.filter(el => !superBlocksUnderDevelopment.includes(el))
|
||||
...Object.values(meta).map(el => el.superBlock)
|
||||
]);
|
||||
superBlocks.forEach(superBlock => {
|
||||
const filteredMeta = Object.values(meta)
|
||||
@@ -316,9 +308,12 @@ function populateTestsForLang({ lang, challenges, meta, superBlocks }) {
|
||||
);
|
||||
});
|
||||
filteredMeta.forEach((meta, index) => {
|
||||
it(`${meta.superBlock} ${meta.name} must be in order`, function () {
|
||||
assert.equal(meta.order, index);
|
||||
});
|
||||
// ignore block order for upcoming blocks
|
||||
if (!meta.isUpcomingChange) {
|
||||
it(`${meta.superBlock} ${meta.name} must be in order`, function () {
|
||||
assert.equal(meta.order, index);
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user