Update test framework: fix run_tests.py to support all test files, add auto-import-check for test files

This commit is contained in:
qiaoxinjiu
2026-05-09 15:11:30 +08:00
parent eb053a347f
commit eaba8328da
21739 changed files with 2236758 additions and 719 deletions

31
node_modules/prom-client/lib/bucketGenerators.js generated vendored Normal file
View File

@@ -0,0 +1,31 @@
'use strict';
exports.linearBuckets = (start, width, count) => {
if (count < 1) {
throw new Error('Linear buckets needs a positive count');
}
const buckets = new Array(count);
for (let i = 0; i < count; i++) {
buckets[i] = start + i * width;
}
return buckets;
};
exports.exponentialBuckets = (start, factor, count) => {
if (start <= 0) {
throw new Error('Exponential buckets needs a positive start');
}
if (count < 1) {
throw new Error('Exponential buckets needs a positive count');
}
if (factor <= 1) {
throw new Error('Exponential buckets needs a factor greater than 1');
}
const buckets = new Array(count);
for (let i = 0; i < count; i++) {
buckets[i] = start;
start *= factor;
}
return buckets;
};