<commit_before>import * as fs from "fs";
import * as path from "path";
import * as vscode from "vscode";

export default class Helper {
    public static resolveTestFilePath(fileName: string) {
        return path.join(path.resolve(__dirname, "..", "..", "test"), fileName);
    }

    public static readTestFileSync(fileName: string) {
        const filePath = Helper.resolveTestFilePath(fileName);
        return fs.readFileSync(filePath).toString();
    }

    public static isExtensionActivated() {
        const extension = vscode.extensions.getExtension("DAXaholic.vscode-edifact");
        return extension && extension.isActive;
    }

    public static waitForExtensionActivation(timeout: number = 500) {
        return new Promise((resolve, reject) => {
            const start = Date.now();
            const scheduledCheck = () => {
                if (this.isExtensionActivated()) {
                    resolve();
                }<commit_msg>Explicitly specify void promise<commit_after>import * as fs from "fs";
import * as path from "path";
import * as vscode from "vscode";

export default class Helper {
    public static resolveTestFilePath(fileName: string) {
        return path.join(path.resolve(__dirname, "..", "..", "test"), fileName);
    }

    public static readTestFileSync(fileName: string) {
        const filePath = Helper.resolveTestFilePath(fileName);
        return fs.readFileSync(filePath).toString();
    }

    public static isExtensionActivated() {
        const extension = vscode.extensions.getExtension("DAXaholic.vscode-edifact");
        return extension && extension.isActive;
    }

    public static waitForExtensionActivation(timeout: number = 500) {
        return new Promise<void>((resolve, reject) => {
            const start = Date.now();
            const scheduledCheck = () => {
                if (this.isExtensionActivated()) {
                    resolve();
                }
{'fraction_non_alphanumeric': 0.11466942148760331, 'fraction_numerical': 0.0030991735537190084, 'mean_word_length': 2.710727969348659, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2704632', 'n_tokens_mistral': 521, 'n_tokens_neox': 505, 'n_words': 127}