[GH-ISSUE #4780] Test a_candle_on_an_uneaten_cake_makes_a_candle_cake fails on main when vanilla data is in .local #1448

Closed
opened 2026-11-02 15:47:01 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @ludovic111 on GitHub (Oct 30, 2026).
Original GitHub issue: https://github.com/horizon-rust/horizon/issues/4780

🤖 Filed by Ludovic's AI agent (Claude), not by Ludovic himself.

The test added by #4277 (DUzzL) fails on main as soon as the vanilla data is present in .local/ (seen by own-prs-1 on the Mac mini, 2026-10-30). CI doesn't see it because its unit-test runners have no .local, so the test takes another path there.

To reproduce: with .local/horizon-client/26.3 prepared, run cargo test -p horizon-client --lib a_candle_on_an_uneaten_cake_makes_a_candle_cake.

@DUzzL, could your agent take a look? The candle-on-cake interaction should follow vanilla's CakeBlock.useItemOn with the real block data.

Originally created by @ludovic111 on GitHub (Oct 30, 2026). Original GitHub issue: https://github.com/horizon-rust/horizon/issues/4780 > 🤖 Filed by Ludovic's AI agent (Claude), not by Ludovic himself. The test added by #4277 (DUzzL) fails on main as soon as the vanilla data is present in `.local/` (seen by own-prs-1 on the Mac mini, 2026-10-30). CI doesn't see it because its unit-test runners have no `.local`, so the test takes another path there. To reproduce: with `.local/horizon-client/26.3` prepared, run `cargo test -p horizon-client --lib a_candle_on_an_uneaten_cake_makes_a_candle_cake`. @DUzzL, could your agent take a look? The candle-on-cake interaction should follow vanilla's `CakeBlock.useItemOn` with the real block data.
bsakaguchi 2026-11-02 15:47:01 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@reservedbytes commented on GitHub (Oct 31, 2026):

I opened #4863 before seeing this

I think the test is wrong, not the game... it uses stone on an uneaten cake and expects it to stay whole, but vanilla's CakeBlock.useItemOn only takes candles, any other item returns TRY_WITH_EMPTY_HAND, so useWithoutItem runs and eats the cake when player.canEat(false)

So asserting bites 1 there, or making the test player full, should fix it

<!-- gh-comment-id:6536992574 --> @reservedbytes commented on GitHub (Oct 31, 2026): I opened #4863 before seeing this I think the test is wrong, not the game... it uses stone on an uneaten cake and expects it to stay whole, but vanilla's `CakeBlock.useItemOn` only takes candles, any other item returns `TRY_WITH_EMPTY_HAND`, so `useWithoutItem` runs and eats the cake when `player.canEat(false)` So asserting `bites` 1 there, or making the test player full, should fix it
Author
Owner

@kacpherek commented on GitHub (Oct 31, 2026):

Fixed by #4962: the test now expects what vanilla does (any non-candle item falls to useWithoutItem and eats a slice), so it passes with vanilla data in .local. Please reopen with the test output if it still fails.

<!-- gh-comment-id:6541524053 --> @kacpherek commented on GitHub (Oct 31, 2026): Fixed by #4962: the test now expects what vanilla does (any non-candle item falls to useWithoutItem and eats a slice), so it passes with vanilla data in .local. Please reopen with the test output if it still fails.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#1448
No description provided.