Skip to content

🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.

450 B
Raw Blame
import { describe, expect, it } from 'vitest';

import { isGoalPrompt } from './goalPrompt';

describe('isGoalPrompt', () => {
  it.each(['/goal ship it', '  /goal\nship it', '/GOAL ship it'])('matches %j', (prompt) => {
    expect(isGoalPrompt(prompt)).toBe(true);
  });

  it.each(['/goals ship it', 'please /goal ship it', '', undefined])(
    'does not match %j',
    (prompt) => {
      expect(isGoalPrompt(prompt)).toBe(false);
    },
  );
});