Skip to content

Commit 3d56534

Browse files
authored
test: add unit tests for RhythmBlocks.js (#4965)
- Add module.exports to RhythmBlocks.js with proper check - Create tests for all 24 registered rhythm blocks - Verify NewSwing2Block default behaviors on error - Ensure 100% test coverage for flow logic Closes #4970
1 parent ec22350 commit 3d56534

File tree

2 files changed

+457
-0
lines changed

2 files changed

+457
-0
lines changed

js/blocks/RhythmBlocks.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1251,3 +1251,7 @@ function setupRhythmBlocks(activity) {
12511251
new DefineFrequencyBlock().setup(activity);
12521252
new OctaveSpaceBlock().setup(activity);
12531253
}
1254+
1255+
if (typeof module !== "undefined" && module.exports) {
1256+
module.exports = { setupRhythmBlocks };
1257+
}

0 commit comments

Comments
 (0)