chore: scrub personal names, maintainer URLs and local paths (P2.2)
Sample data in tests, prompts and UI placeholders uses Alex Morgan instead of the maintainer's name; decision attributions say "owner". Personal details in two test fixtures are replaced. Local paths (D:/Projects/...) and paths into the maintainer's planning repository are reworded. Clone and install URLs in CONTRIBUTING.md and the getting started guide use placeholders until the public repository location is decided (Q9). The Benchmarks page no longer names the maintainer's hive-mind repository, and the upstream fixes log names the main Waggle repository instead of an internal git host.
This commit is contained in:
@@ -23,7 +23,7 @@ describe('listWindowsDrives', () => {
|
||||
expect(drives[0]).toEqual({ name: 'C:', path: 'C:\\', type: 'directory' });
|
||||
});
|
||||
|
||||
it('returns both C: and D: on a dual-drive machine like Marko\'s', () => {
|
||||
it('returns both C: and D: on a dual-drive machine like Alex\'s', () => {
|
||||
const drives = listWindowsDrives((p) => p === 'C:\\' || p === 'D:\\');
|
||||
expect(drives).toHaveLength(2);
|
||||
expect(drives.map((d) => d.name)).toEqual(['C:', 'D:']);
|
||||
|
||||
@@ -106,12 +106,12 @@ describe('DiscordAdapter gateway', () => {
|
||||
handshake(ws);
|
||||
ws.serverSend({
|
||||
op: 0, t: 'MESSAGE_CREATE', s: 2,
|
||||
d: { id: 'm1', channel_id: 'c1', content: 'hello', author: { id: 'u1', username: 'marko' } },
|
||||
d: { id: 'm1', channel_id: 'c1', content: 'hello', author: { id: 'u1', username: 'alex' } },
|
||||
});
|
||||
await tick();
|
||||
expect(ctx.received[0]).toEqual({
|
||||
platform: 'discord', chatId: 'c1', senderId: 'u1',
|
||||
senderName: 'marko', text: 'hello', messageId: 'm1',
|
||||
senderName: 'alex', text: 'hello', messageId: 'm1',
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ describe('PairingStore codes', () => {
|
||||
it('consumes a valid code exactly once and pairs the sender', () => {
|
||||
const store = new PairingStore(dir);
|
||||
const { code } = store.generateCode('telegram');
|
||||
expect(store.consumeCode('telegram', code, 'user-1', 'marko')).toBe(true);
|
||||
expect(store.consumeCode('telegram', code, 'user-1', 'alex')).toBe(true);
|
||||
expect(store.isPaired('telegram', 'user-1')).toBe(true);
|
||||
// Single-use: second redemption fails.
|
||||
expect(store.consumeCode('telegram', code, 'user-2')).toBe(false);
|
||||
@@ -70,11 +70,11 @@ describe('PairingStore persistence', () => {
|
||||
it('persists allowlist across store instances (channels.json)', () => {
|
||||
const a = new PairingStore(dir);
|
||||
const { code } = a.generateCode('telegram');
|
||||
a.consumeCode('telegram', code, 'user-1', 'marko');
|
||||
a.consumeCode('telegram', code, 'user-1', 'alex');
|
||||
|
||||
const b = new PairingStore(dir);
|
||||
expect(b.isPaired('telegram', 'user-1')).toBe(true);
|
||||
expect(b.listPaired().telegram?.[0]?.senderName).toBe('marko');
|
||||
expect(b.listPaired().telegram?.[0]?.senderName).toBe('alex');
|
||||
});
|
||||
|
||||
it('does NOT persist pending codes (in-memory only)', () => {
|
||||
|
||||
@@ -36,7 +36,7 @@ function makeFetchScript(updateBatches: unknown[][]) {
|
||||
return { fetchImpl, calls };
|
||||
}
|
||||
|
||||
function telegramUpdate(id: number, text: string, from = { id: 42, username: 'marko' }) {
|
||||
function telegramUpdate(id: number, text: string, from = { id: 42, username: 'alex' }) {
|
||||
return { update_id: id, message: { message_id: id, text, chat: { id: -100 }, from } };
|
||||
}
|
||||
|
||||
@@ -75,7 +75,7 @@ describe('TelegramAdapter polling', () => {
|
||||
platform: 'telegram',
|
||||
chatId: '-100',
|
||||
senderId: '42',
|
||||
senderName: 'marko',
|
||||
senderName: 'alex',
|
||||
text: 'hello',
|
||||
messageId: '7',
|
||||
});
|
||||
|
||||
@@ -105,7 +105,7 @@ function textMessage(overrides: Partial<WaMessageLike> = {}): WaMessageLike {
|
||||
body: 'zdravo',
|
||||
type: 'chat',
|
||||
id: { _serialized: 'false_3816x@c.us_m1' },
|
||||
_data: { notifyName: 'Marko' },
|
||||
_data: { notifyName: 'Alex' },
|
||||
...overrides,
|
||||
};
|
||||
}
|
||||
@@ -253,7 +253,7 @@ describe('WhatsAppAdapter inbound', () => {
|
||||
platform: 'whatsapp',
|
||||
chatId: '3816x@c.us',
|
||||
senderId: '3816x@c.us',
|
||||
senderName: 'Marko',
|
||||
senderName: 'Alex',
|
||||
text: 'zdravo',
|
||||
messageId: 'false_3816x@c.us_m1',
|
||||
});
|
||||
|
||||
@@ -74,13 +74,13 @@ const card = (id: string, pendingCount: number, rankTs: number): { card: RecentW
|
||||
|
||||
describe('personalizeGreeting (P2 — B8 name in greeting)', () => {
|
||||
it('splices the name before the first sentence break', () => {
|
||||
expect(personalizeGreeting("Good morning. Here's your day", 'Marko'))
|
||||
.toBe("Good morning, Marko. Here's your day");
|
||||
expect(personalizeGreeting("Good morning. Here's your day", 'Alex'))
|
||||
.toBe("Good morning, Alex. Here's your day");
|
||||
});
|
||||
|
||||
it('handles the em-dash fresh-state greeting', () => {
|
||||
expect(personalizeGreeting('Welcome — anything you discuss here will be remembered.', 'Marko'))
|
||||
.toBe('Welcome, Marko — anything you discuss here will be remembered.');
|
||||
expect(personalizeGreeting('Welcome — anything you discuss here will be remembered.', 'Alex'))
|
||||
.toBe('Welcome, Alex — anything you discuss here will be remembered.');
|
||||
});
|
||||
|
||||
it('passes through without a name', () => {
|
||||
@@ -89,7 +89,7 @@ describe('personalizeGreeting (P2 — B8 name in greeting)', () => {
|
||||
});
|
||||
|
||||
it('passes through greetings with no sentence break', () => {
|
||||
expect(personalizeGreeting('Hello there', 'Marko')).toBe('Hello there');
|
||||
expect(personalizeGreeting('Hello there', 'Alex')).toBe('Hello there');
|
||||
});
|
||||
});
|
||||
|
||||
@@ -180,14 +180,14 @@ describe('GET /api/home/briefing (P2 — J08 needsReviewCount + greeting)', () =
|
||||
it('greets by name when identity is seeded (B8)', async () => {
|
||||
boot([{ id: 'w1', name: 'Alpha', group: 'Personal', created: new Date().toISOString() }]);
|
||||
new IdentityLayer(server.waggleDb).create({
|
||||
name: 'Marko', role: 'Founder', department: 'Egzakta',
|
||||
name: 'Alex', role: 'Founder', department: 'Egzakta',
|
||||
personality: '', capabilities: '', system_prompt: '',
|
||||
});
|
||||
const res = await server.inject({ method: 'GET', url: '/api/home/briefing' });
|
||||
expect(res.statusCode).toBe(200);
|
||||
const briefing = res.json();
|
||||
expect(briefing.userName).toBe('Marko');
|
||||
expect(briefing.greeting).toContain(', Marko');
|
||||
expect(briefing.userName).toBe('Alex');
|
||||
expect(briefing.greeting).toContain(', Alex');
|
||||
});
|
||||
|
||||
it('greeting stays name-free when no identity exists', async () => {
|
||||
|
||||
@@ -31,7 +31,7 @@ describe('POST /api/identity — merge-on-update', () => {
|
||||
boot();
|
||||
const first = await server.inject({
|
||||
method: 'POST', url: '/api/identity',
|
||||
payload: { name: 'Marko', role: 'Founder', department: 'Egzakta' },
|
||||
payload: { name: 'Alex', role: 'Founder', department: 'Egzakta' },
|
||||
});
|
||||
expect(first.statusCode).toBe(200);
|
||||
|
||||
@@ -39,11 +39,11 @@ describe('POST /api/identity — merge-on-update', () => {
|
||||
// survive (the old `body.x ?? ''` semantics silently wiped them).
|
||||
const partial = await server.inject({
|
||||
method: 'POST', url: '/api/identity',
|
||||
payload: { name: 'Marko M.' },
|
||||
payload: { name: 'Alex M.' },
|
||||
});
|
||||
expect(partial.statusCode).toBe(200);
|
||||
const body = partial.json();
|
||||
expect(body.name).toBe('Marko M.');
|
||||
expect(body.name).toBe('Alex M.');
|
||||
expect(body.role).toBe('Founder');
|
||||
expect(body.department).toBe('Egzakta');
|
||||
});
|
||||
@@ -52,14 +52,14 @@ describe('POST /api/identity — merge-on-update', () => {
|
||||
boot();
|
||||
await server.inject({
|
||||
method: 'POST', url: '/api/identity',
|
||||
payload: { name: 'Marko', role: 'Founder' },
|
||||
payload: { name: 'Alex', role: 'Founder' },
|
||||
});
|
||||
const cleared = await server.inject({
|
||||
method: 'POST', url: '/api/identity',
|
||||
payload: { role: '' },
|
||||
});
|
||||
expect(cleared.json().role).toBe('');
|
||||
expect(cleared.json().name).toBe('Marko');
|
||||
expect(cleared.json().name).toBe('Alex');
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
@@ -87,10 +87,10 @@ describe('SignalBus', () => {
|
||||
|
||||
it('filters by teamId', () => {
|
||||
const bus = new SignalBus(10);
|
||||
bus.record(makeSignal({ id: 'p1', teamId: 'personal::marko' }));
|
||||
bus.record(makeSignal({ id: 'p1', teamId: 'personal::alex' }));
|
||||
bus.record(makeSignal({ id: 't1', teamId: 'team-egzakta' }));
|
||||
bus.record(makeSignal({ id: 'p2', teamId: 'personal::marko' }));
|
||||
const personal = bus.query({ teamId: 'personal::marko' });
|
||||
bus.record(makeSignal({ id: 'p2', teamId: 'personal::alex' }));
|
||||
const personal = bus.query({ teamId: 'personal::alex' });
|
||||
expect(personal.map((s) => s.id)).toEqual(['p2', 'p1']);
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user