"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const util_1 = require("../../src/redteam/util");
describe('removePrefix', () => {
    it('should remove a simple prefix', () => {
        expect((0, util_1.removePrefix)('Prompt: Hello world', 'Prompt')).toBe('Hello world');
    });
    it('should be case insensitive', () => {
        expect((0, util_1.removePrefix)('PROMPT: Hello world', 'prompt')).toBe('Hello world');
    });
    it('should remove asterisks from the prefix', () => {
        expect((0, util_1.removePrefix)('**Prompt:** Hello world', 'Prompt')).toBe('Hello world');
    });
    it('should handle multiple asterisks', () => {
        expect((0, util_1.removePrefix)('***Prompt:*** Hello world', 'Prompt')).toBe('Hello world');
    });
    it('should return the same string if prefix is not found', () => {
        expect((0, util_1.removePrefix)('Hello world', 'Prefix')).toBe('Hello world');
    });
    it('should handle empty strings', () => {
        expect((0, util_1.removePrefix)('', 'Prefix')).toBe('');
    });
    it('should handle prefix that is the entire string', () => {
        expect((0, util_1.removePrefix)('Prompt:', 'Prompt')).toBe('');
    });
});
//# sourceMappingURL=util.test.js.map