public Map<String, Integer> getJavaScriptConfig() {
// For now this is a simple mapping from {testName to bucketValue}
final Map<String, Integer> groups = Maps.newHashMapWithExpectedSize(proctorResult.getBuckets().size());
for (final Entry<String, TestBucket> entry : proctorResult.getBuckets().entrySet()) {
final String testName = entry.getKey();
final TestBucket testBucket = entry.getValue();
// mirrors appendTestGroups method by skipping *inactive* tests
if (testBucket.getValue() < 0) {
continue;
}
groups.put(testName, testBucket.getValue());
}
return groups;
}