Skip to content

Commit dafb734

Browse files
fix: copilot review
1 parent 8926fb4 commit dafb734

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

.github/workflows/scripts/__tests__/format.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ describe('format utils', () => {
99

1010
it('should format size in MB when greater than or equal to 1024 bytes', () => {
1111
const size = 2.5 * 1024; // 2.5 KB -> will be shown in MB
12-
expect(formatSize(size)).toBe('0.00 MB');
12+
expect(formatSize(size)).toBe('2.50 KB');
1313
});
1414

1515
it('should handle small sizes', () => {

.github/workflows/scripts/utils/format.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* @returns {string} Formatted size string with units
55
*/
66
function formatSize(sizeInBytes) {
7-
const MB_THRESHOLD = 1024;
7+
const MB_THRESHOLD = 10 * 1024;
88
if (sizeInBytes >= MB_THRESHOLD) {
99
return `${(sizeInBytes / (1024 * 1024)).toFixed(2)} MB`;
1010
}

0 commit comments

Comments
 (0)