Socials Test Suite
Run comprehensive tests on all Socials tools to verify the extension and MCP server are working correctly.
Mode Selection
IMPORTANT: Before running any tests, ask the user which mode they want:
Which test mode would you like to run?
1. **Dry Run** (safe) - Tests read-only tools only. Will NOT post, reply, or engage.
2. **Full Test** (destructive) - Tests ALL tools including posting and engagement.
WARNING: This will create real posts, replies, likes, and connection requests!
Enter 1 or 2:
Wait for user response before proceeding. Default to Dry Run if unclear.
Test Execution
Run tests in this order, reporting results as you go:
1. Connection & Access Tests
Test: socials_check_access
Expected: connected=true, canUseMcp=true
If this fails, run the RECOVERY FLOW before stopping:
RECOVERY FLOW:
1. socials_refresh_auth → try to restore auth
2. If still fails: socials_restart_bridge → restart WS bridge
3. Ask user to refresh Socials extension in browser
4. Retry socials_check_access
5. If still fails after recovery, stop and report the issue
Test: socials_health_check
Expected: is_healthy=true, connected=true
Test: socials_diagnostics
Expected: status=ok, extension_connected=true
2. Browser Control Tests
Test: socials_get_active_tab
Expected: Returns current tab info (tabId, url, title)
Test: socials_get_agent_tab
Expected: Returns agent tab info or null if not set
If no agent tab is set:
Test: socials_open_tab (url: "https://x.com/home", focus: false)
Expected: success=true, agentTabPinned=true
Test: socials_get_agent_tab (verify it's now set)
Expected: Returns the tab we just opened
Test: socials_set_agent_tab (tabId: <current agent tab id>)
Expected: success=true (re-pins the same tab)
Test: socials_focus_agent_tab
Expected: success=true, agent tab receives focus
Test: socials_refresh_auth
Expected: Returns auth status (validates device auth flow)
Test: socials_reload_tab
Expected: success=true, agent tab reloaded
Optional (only if testing recovery):
Test: socials_restart_bridge
Expected: success=true, message includes "listening on 127.0.0.1:9847"
Note: After this, user must refresh browser extension before continuing
3. X (Twitter) Tests - Read Only
Ensure agent tab is on X (https://x.com/home):
Test: socials_get_feed (platform: "x", count: 5)
Expected: Returns array of posts with id, author, content
Test: socials_get_page_content
Expected: Returns posts from current page
Test: socials_scroll (direction: "down", amount: 400)
Expected: success=true
Test: socials_x_search (query: "test")
Expected: success=true, navigates to search results (default mode: top)
Test: socials_x_search (query: "startup", mode: "latest")
Expected: success=true, navigates to Latest tab (f=live)
Test: socials_x_search (query: "AI", from: "elonmusk", min_faves: 100)
Expected: query="AI from:elonmusk min_faves:100"
Note: Tests user filter + engagement threshold
Test: socials_x_search (query: "tech", filter: "media", is_retweet: false, lang: "en")
Expected: query="tech filter:media -is:retweet lang:en"
Note: Tests content filter + exclusion + language
Test: socials_x_search (query: "news", since: "2026-01-01", until: "2026-03-01")
Expected: query="news since:2026-01-01 until:2026-03-01"
Note: Tests date range (YYYY-MM-DD format)
Test: socials_x_search (query: "#buildinpublic", has: ["media", "links"], min_retweets: 5)
Expected: query="#buildinpublic has:media has:links min_retweets:5"
Note: Tests hashtag + has filters + engagement
Test: socials_x_search (query: "conference", near: "San Francisco", place_country: "US")
Expected: query="conference near:\"San Francisco\" place_country:US"
Note: Tests location filters
Test: socials_x_search (query: "thread", is_reply: false, mode: "latest")
Expected: query="thread -is:reply", mode=latest
Note: Tests reply exclusion for finding original posts
After search results load, test post context:
Test: socials_get_feed (platform: "x", count: 1)
Expected: Returns at least one post with an id
Test: socials_get_post_context (tweet_id: <id from previous feed>)
Expected: Returns context around the post (replies, parent thread)
Navigate to notifications for notification tests:
Test: socials_navigate (url: "https://x.com/notifications")
Expected: success=true
Wait 2 seconds, then:
Test: socials_x_notifications (count: 5)
Expected: Returns array of notifications with:
- type: "like", "follow", "repost", "reply", "quote", "mention", or "unknown"
- user: { name, handle, avatarUrl, isVerified }
- timestamp: ISO datetime string
- relatedContent: truncated text of the liked/mentioned tweet (if applicable)
- tweetUrl: URL to the tweet (for tweets)
- tweetId: Tweet ID for use with socials_engage_post / socials_quick_reply
Note: Must be on https://x.com/notifications page
Note: If fewer notifications than requested, will auto-scroll up to 3 times
Test notification engagement workflow (if tweet notification found with tweetId):
Test: socials_engage_post (tweet_id: <tweetId from notification>, like: true, bookmark: true)
Expected: success=true, likes and bookmarks the tweet directly from notifications page
Note: No navigation needed - engage_post works on current page
Test: socials_quick_reply (tweet_id: <tweetId from notification>, reply: "Thanks for the engagement! [timestamp]")
Expected: success=true, replies to the notification tweet directly
Note: Opens reply modal on the notification tweet and posts - no navigation needed
4. X (Twitter) Tests - Destructive [FULL MODE ONLY]
Skip this section in Dry Run mode.
Before running, confirm with user:
About to test X engagement tools. This will:
- Create a test post on your X account
- Like and bookmark a post
- Reply to a post
Continue? (yes/no)
If confirmed:
Test: socials_create_post (content: "Test post from Socials MCP - please ignore [timestamp]", platform: "x")
Expected: success=true, returns post URL
Action: Note the post URL to delete manually later
Test: socials_create_post (content: "Testing newlines:\n\nLine 1\nLine 2\nLine 3\n\n[timestamp]", platform: "x")
Expected: success=true, post should display with proper line breaks
Action: Note the post URL to delete manually later
Note: Tests newline (\n) support in X compose box
Test: socials_create_post with video (content: "Testing video upload [timestamp]", platform: "x", media: [video file])
Expected: success=true, waits for upload progress to reach 100% before posting
Action: Note the post URL to delete manually later
Note: Tests video upload progress detection (waits for "Processing X%" to complete)
Test: socials_engage_post (tweet_id: <id from feed>, like: true, bookmark: true)
Expected: success=true
Note: This will like and bookmark a real post
Test: socials_quick_reply (tweet_id: <id from feed>, reply: "Test reply from Socials MCP [timestamp]")
Expected: success=true, returns reply URL
Action: Note the reply URL to delete manually later
After tests, remind user:
Destructive X tests complete. Please manually delete:
- Test post: [URL]
- Test reply: [URL]
- Undo like/bookmark if desired
5. LinkedIn Tests - Read Only
Navigate to LinkedIn:
Test: socials_navigate (url: "https://www.linkedin.com/feed/")
Expected: success=true
Wait 2-3 seconds for page load, then:
Test: socials_get_feed (platform: "linkedin", count: 5)
Expected: Returns array of LinkedIn posts
Test: socials_linkedin_posts_search (query: "startup")
Expected: success=true
Test: socials_linkedin_people_search (query: "software engineer")
Expected: success=true
Test: socials_linkedin_get_people (count: 3)
Expected: Return