Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/ring.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ export const RING: RingSite[] = [
{ name: 'offtherecord.podcast', about: 'Off The Record: a Silicon Valley veteran programmer on fleet engineering, agentic coding bots and building a new internet.', moshpit: true, feed: 'https://offtherecord.podcast.pit.world/feed.xml', keywords: ['off the record', 'otr', 'podcast', 'interview', 'agentic coding'] },
{ name: 'live.streaming', about: 'Radio and TV stations, live now: AI-composed music, tracks shared by listeners, and more.', moshpit: true, keywords: ['radio', 'live tv', 'stations', 'stream'] },
{ name: 'pics.collage', about: 'Make photo collages on your phone: grids, freestyle, stickers, text and backgrounds. Free, no account, works offline.', moshpit: true, keywords: ['collage', 'photo grid', 'photo editor'] },
{ name: 'my.ip', about: 'Your public IPv4 and IPv6 in one answer, as text or JSON. curl -L my.ip.pit.world', moshpit: true, keywords: ['my ip', 'what is my ip', 'ip address', 'ipv6', 'ipv4'] },
]

let source: (() => ListingMember[]) | null = null
Expand Down
3 changes: 2 additions & 1 deletion test/featured.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ describe('featured ring sites in search', () => {
expect(names('agentic coding podcast')).toContain('offtherecord.podcast')
})
test('every core site is found by its own name', () => {
for (const q of ['group call', 'seo rank', 'family ancestry', 'pay agent', 'built indie', 'deadman switch', 'watch wallet', 'resident alerts', 'search peptides', 'auto hacker', 'ad network', 'live streaming', 'pics collage'])
for (const q of ['group call', 'seo rank', 'family ancestry', 'pay agent', 'built indie', 'deadman switch', 'watch wallet', 'resident alerts', 'search peptides', 'auto hacker', 'ad network', 'live streaming', 'pics collage', 'my ip'])
expect(names(q).length).toBeGreaterThan(0)
expect(names('group call')[0]).toBe('group.call.pit.world')
expect(names('pics collage')[0]).toBe('pics.collage')
expect(names('what is my ip')[0]).toBe('my.ip')
})
test('by what people search for', () => {
expect(names('family tree maker')).toContain('family.ancestry')
Expand Down
5 changes: 3 additions & 2 deletions test/pit.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -660,8 +660,9 @@ describe('the Moshpit ring', () => {
expect(neighbors('group.call.pit.world').next.name).toBe('offtherecord.podcast')
expect(neighbors('offtherecord.podcast').next.name).toBe('live.streaming')
expect(neighbors('live.streaming').next.name).toBe('pics.collage')
expect(neighbors('pics.collage').next.name).toBe('pit.world')
expect(neighbors('pit.world').prev.name).toBe('pics.collage')
expect(neighbors('pics.collage').next.name).toBe('my.ip')
expect(neighbors('my.ip').next.name).toBe('pit.world')
expect(neighbors('pit.world').prev.name).toBe('my.ip')
expect(neighbors('WWW.SEO.RANK.').next.name).toBe('family.ancestry')
for (const r of [0, 0.5, 0.99]) expect(randomSite('seo.rank', () => r).name).not.toBe('seo.rank')
})
Expand Down
9 changes: 5 additions & 4 deletions test/pros.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ describe('the pit.world ring: claimed listings join it', () => {
expect(names).not.toContain('acme-plumbing.com')
expect((await h.listings.get('acme-plumbing.com'))!.ring).toBe(false)
expect(await (await h.request('/b/acme-plumbing.com/edit')).text()).not.toContain('Leave the ring')
expect(names.slice(0, 15)).toEqual([
expect(names.slice(0, 16)).toEqual([
'pit.world',
'seo.rank',
'family.ancestry',
Expand All @@ -279,11 +279,12 @@ describe('the pit.world ring: claimed listings join it', () => {
'offtherecord.podcast',
'live.streaming',
'pics.collage',
'my.ip',
])
expect(ring.sites.at(-1)).toMatchObject({ name: 'acme.pit.world', listing: true, moshpit: false, feed: 'https://acme.pit.world/rss.xml' })
expect((await h.request('/ring/next?from=https%3A%2F%2Fpics.collage%2F&direct=1')).headers.get('location')).toBe('https://acme.pit.world/')
expect((await h.request('/ring/next?from=https%3A%2F%2Fmy.ip%2F&direct=1')).headers.get('location')).toBe('https://acme.pit.world/')
expect((await h.request('/ring/next?from=acme.pit.world')).headers.get('location')).toBe('https://pit.world/')
expect((await h.request('/ring/prev', { headers: { referer: 'https://www.acme.pit.world/about' } })).headers.get('location')).toBe('https://pics.collage.pit.world/')
expect((await h.request('/ring/prev', { headers: { referer: 'https://www.acme.pit.world/about' } })).headers.get('location')).toBe('https://my.ip.pit.world/')
expect((await h.request('/ring/random?from=acme.pit.world')).headers.get('cache-control')).toBe('no-store')
const page = await (await h.request('/ring')).text()
expect(page).toContain('href="/b/acme.pit.world"')
Expand All @@ -302,7 +303,7 @@ describe('the pit.world ring: claimed listings join it', () => {
const ok = await (await h.form('/b/acme.bakery/verify', { claim: start.claimId })).text()
expect(ok).toContain('pit.world/ring/next?from=https%3A%2F%2Facme.bakery%2F')
expect(ok).toContain('https://rssamplifier.com/ring/pit-world')
expect(neighbors('pics.collage').next).toMatchObject({ name: 'acme.bakery', moshpit: true })
expect(neighbors('my.ip').next).toMatchObject({ name: 'acme.bakery', moshpit: true })
})
})

Expand Down
Loading