Skip to content

Mobile test setup: Android emulator and iPhone simulator in one step - #221

Merged
ChefControl merged 1 commit into
mainfrom
claude/mobile-test-setup
Oct 28, 2026
Merged

ChefControl merged 1 commit into
mainfrom
claude/mobile-test-setup

Conversation

@ChefControl

Copy link
Copy Markdown
Owner

A one-step way to open the game on phones on the Mac, so player reports from iPhones and Android Chrome can be reproduced. Claude Code can screenshot, tap and read console errors on both.

What's in it

  • .claude/skills/mobile-test/ (repo skill): android.sh [url] opens a page in Chrome on the floe-pixel9 emulator (Pixel 9, Android 17 Google APIs, 4 GB) and connects Chrome's DevTools on 127.0.0.1:9333. ios.sh [url] opens it in Safari on the iPhone 17 simulator and streams Safari's console to $TMPDIR/floe-mobile/ios-console.log. The default url is the demo build on localhost:5177; the live game works too.
  • .mcp.json: Google's chrome-devtools-mcp, pinned at 1.11.0, with usage statistics and CrUX off. Pointed at the emulator's Chrome, it reads the console and network, runs JS and takes screenshots. Claude Code asks once before it starts a project MCP server.
  • docs/mobile-testing.md: the how-to for people.

Findings

  • iOS needs no extra install. Two Safari settings in the simulator (WebKitLogsPageMessagesToSystemConsoleEnabled and its Debug twin, both needed) copy every console message into the simulator's log.
  • Android: localhost reaches the Mac through adb reverse, so a dev server that only listens on [::1] works, and the page stays a secure context. 10.0.2.2 gets neither.
  • The emulator has to use a software GPU. With the Mac's GPU, Chrome's WebGL on Android 17 shows a blank world (its GPU process dies every second). With GuestAngle it shows "Error creating WebGL context", the same text as the casino crash report. Both look like game bugs but aren't.

Checked on the Pixel 9 emulator and the iPhone 17 simulator, with the live game (stage 1) and the demo build (stage 2): screenshots of each, and console errors read on both, including test errors to show they come through.

Not in the repo: Android Studio and the SDK (Homebrew casks android-studio and android-commandlinetools), and the emulator in ~/.android/avd. Legal checks don't apply: nothing here ships in the game.

🤖 Generated with Claude Code

- .claude/skills/mobile-test: android.sh opens a page in Chrome on the floe-pixel9 emulator (Pixel 9, Android 17)
  and connects Chrome's DevTools on 127.0.0.1:9333; ios.sh opens it in Safari on the iPhone 17 simulator and streams
  Safari's console to a file. SKILL.md says how Claude Code screenshots, taps and reads errors on each.
- .mcp.json: Google's chrome-devtools-mcp 1.11.0, pinned, usage statistics and CrUX off, for the emulator's Chrome.
- docs/mobile-testing.md: the how-to for people.

The emulator uses a software GPU: with the Mac's GPU, Chrome's WebGL on Android 17 shows a blank world or
"Error creating WebGL context", which looks like a game bug but isn't.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ChefControl
ChefControl added this pull request to stack #222 October 28, 2026 16:04
@ChefControl
ChefControl merged commit 24793c7 into main Oct 28, 2026
7 checks passed
@ChefControl
ChefControl deleted the claude/mobile-test-setup branch October 28, 2026 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant