release: v2.33.1 - Production build and packaging

This commit is contained in:
g1nation
2026-05-01 18:04:56 +09:00
parent c366a041c5
commit 250c998293
5 changed files with 258 additions and 44 deletions
+17
View File
@@ -33,6 +33,23 @@ describe('DataProcessor Algorithm & Performance Validation', () => {
expect(result[0].key).toBe('X');
});
test('Should reject unsafe or malformed key paths', () => {
expect(() => DataProcessor.aggregate([{ a: 1 }], '')).toThrow(TypeError);
expect(() => DataProcessor.aggregate([{ a: 1 }], 'a..b')).toThrow(TypeError);
expect(() => DataProcessor.aggregate([{ a: 1 }], '__proto__.polluted')).toThrow(TypeError);
});
test('Should support aggregation without retaining source values', () => {
const result = DataProcessor.aggregate([
{ category: 'A', value: 10 },
{ category: 'A', value: 20 },
], 'category', { collectValues: false });
expect(result).toHaveLength(1);
expect(result[0].count).toBe(2);
expect(result[0].values).toEqual([]);
});
// 3. 성능 벤치마크 (O(N) vs O(N^2) 검증)
test('O(N) Efficiency Benchmark', () => {
const generateData = (n: number) => {