Monorepo for Aesthetic.Computer aesthetic.computer
4
fork

Configure Feed

Select the types of activity you want to include in your feed.

at main 43 lines 1.2 kB view raw
1#!/usr/bin/env node 2// test-jump.mjs - Test jumping to different pieces using CDP 3 4import Artery from './artery.mjs'; 5 6console.log('🧪 Testing piece navigation...\n'); 7 8const client = new Artery(); 9await client.connect(); 10console.log('✅ Connected to AC\n'); 11 12// Get current piece 13const currentPiece = await client.getCurrentPiece(); 14console.log(`📍 Current piece: ${currentPiece || '(none)'}`); 15 16// Jump to a different piece 17const testPiece = 'line'; 18console.log(`\n🎯 Jumping to: ${testPiece}...`); 19await client.jump(testPiece); 20 21// Wait a moment for navigation 22await new Promise(r => setTimeout(r, 1000)); 23 24// Verify we jumped 25const newPiece = await client.getCurrentPiece(); 26console.log(`📍 New piece: ${newPiece}`); 27 28if (newPiece && newPiece.includes(testPiece)) { 29 console.log('✅ Jump successful!\n'); 30} else { 31 console.log('⚠️ Jump may have failed\n'); 32} 33 34// Jump back to prompt 35console.log('🔙 Jumping back to prompt...'); 36await client.jump('prompt'); 37await new Promise(r => setTimeout(r, 1000)); 38 39const finalPiece = await client.getCurrentPiece(); 40console.log(`📍 Final piece: ${finalPiece}`); 41console.log('✅ Navigation test complete\n'); 42 43client.close();