Conversation
|
| App Name | WordPress | |
| Configuration | Release-Alpha | |
| Build Number | 30987 | |
| Version | PR #25242 | |
| Bundle ID | org.wordpress.alpha | |
| Commit | 7cfc3ca | |
| Installation URL | 7hr8vm5s8a7kg |
|
| App Name | Jetpack | |
| Configuration | Release-Alpha | |
| Build Number | 30987 | |
| Version | PR #25242 | |
| Bundle ID | com.jetpack.alpha | |
| Commit | 7cfc3ca | |
| Installation URL | 2b42rm39t477g |
🤖 Build Failure AnalysisThis build has failures. Claude has analyzed them - check the build annotations for details. |
|
|
||
| ### Building and Testing | ||
|
|
||
| Use the `test` Fastlane lane for local testing. |
There was a problem hiding this comment.
This might change soon with Xcode 26.3, I haven't had a chance to install the RC yet.
| desc "Build #{XCODE_SCHEME}" | ||
| task build: [:dependencies] do | ||
| xcodebuild(:build) | ||
| end |
There was a problem hiding this comment.
Given we have Fastlane and/or the upcoming Xcode 26.3 MCP, these are redundant and confusing for the agent to have.
They were the first it picked up when I tried and wasted a bunch of time on them.
CLAUDE.md with info for the build-test loop
|
@kean @crazytonyli sorry for the spam. This is not reayd for review yet. I mean, I'm always appreciative of your feedback, but I'm not done yet. |
66d7da1 to
a903cbf
Compare
CLAUDE.md with info for the build-test loopa903cbf to
ae6d1ed
Compare
fastlane/lanes/build.rb
Outdated
| # bundle exec fastlane test clean:true | ||
| # | ||
| desc 'Run tests locally' | ||
| lane :test do |scheme: 'WordPress', device: 'iPhone 16', ios_version: nil, only_testing: nil, clean: false| |
There was a problem hiding this comment.
Using 'iPhone 17' is probably more inline with the Xcode version used in the project
| 1. **Lint** — `rake lint` (fast, catches style and localization errors) | ||
| 2. **Build** — `xcodebuild build ...` (catches type errors without running tests) | ||
| 3. **Test** — `bundle exec fastlane test only_testing:TargetName/Class/method` | ||
|
|
There was a problem hiding this comment.
I don't think we need to be so prescriptive. LLM is already smart enough to know most of these: the xcodebuild build, the simctl command, and the test filter format. They may not know what rake tasks and fastlane lanes we have, so I guess it might be valuable to include them explicitly.
I think most of the time, LLM is smart enough to know which tools to use and how to use them during the job, which usually works out better than telling them what to do (via Claude.md in this case) before the job starts. In general, I'm leaning more towards cutting down the context, rather than adding more.
Please note, I'm not really against adding these instructions here. We can see how they work in practice after this PR is merged.
There was a problem hiding this comment.
I don't like being prescriptive either, but every time I ask the model to generate this kind of stuff, it always opts for being verbose and prescriptive.
I don't like it, because it seems like a maintenance nightmare.
In fact, I had to push back on it enumerating all the module-tests pairs, and force it to track the naming convention instead.
I asked why and the reason it gave, which I know is not to be trusted but made sense to me, is that being prescriptive means it has less files to parse when needing to find the answer to which command to run for what.
| import Foundation | ||
|
|
||
| extension Bundle { | ||
| public class var designSystemBundle: Bundle { |
There was a problem hiding this comment.
This function probably does not need to be public?
CI uses Fastlane exclusively; these local wrappers around `xcodebuild` were obsolete and hardcoded a stale simulator. --- Generated with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Lets agents run lint, build, test, and simulator queries without prompting. Other A8C repos (e.g. woocommerce.com) use the same pattern. --- Generated with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Skips CI prerequisites (env files, signing, toolkit checks) and reuses DerivedData for incremental builds. Supports only_testing, scheme, device, and clean options. --- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Ideally, this would build faster than the rest and allow focused testing. The blocker is that since the Modules don't build with `swift build` we can test with `swift test`. Plus, auto-generated schemes allow building but not testing!
--- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
--- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
--- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
--- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The file was in a `WordPressUITests` directory with no matching SPM target, so it was never compiled or run. Updated its import from `WordPress` to `WordPressUI`. --- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
--- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Applies the same test-bundle workaround already used elsewhere in WordPressUI so the storyboard loads in SPM test context. --- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The test calendar used `.eastern` but the service used `.current`, so date interval keys never aligned. --- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The test crashes when DesignSystem is built as a dynamic library, which happens because WordPressAuthenticator (also in the plan) depends on it transitively. --- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Use `Bundle.designSystemBundle` instead of `.module` so resources resolve when Xcode builds the module as a dynamic library (same workaround as WordPressUI). --- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Its targets are a subset of WordPressUnitTests.xctestplan, which is already the default test plan in the WordPress scheme. --- Generate with the help of Claude Code, https://code.claude.com Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
ae6d1ed to
3d2d225
Compare
|
| @@ -1 +1,214 @@ | |||
| <<<<<<< HEAD | |||
There was a problem hiding this comment.
Looks like a merge conflict token.












Summary
Refines
CLAUDE.mdand the project's test infrastructure so AI agents can build, lint, and run focused tests autonomously.CLAUDE.md(Fastlanetestlane,xcodebuild build,rake lint,only_testing:syntax, available test targets)WordPressUIUnitTestsexceptionWordPressUnitTests.xctestplan) so agents can select any of them for focused runsAllModulesUnitTeststest plan (subset of the default plan)testFastlane lane that skips CI prerequisites and reusesDerivedData/DesignSystemresource bundle resolution in the test runner (Bundle.designSystemBundleinstead of.module)MockStatsServiceTestsWordPressUIUnitTeststargetNote
I haven't set up Xcode 26.3 yet, which promises to be faster than using Fastlane/
xcodebuild. Still, I don't think it hurts to have this infra available even if it won't be used much on dev machines. It'd be interesting to see what can be done in CI without spinning up Xcode.Testing instructions
No user-facing changes.
Verify the test plan and scheme changes work by running:
Generated with Claude Opus 4.6