Skip to content

Accept Symbol property names in Fbe.overwrite - #1327

Open
Titanism0v0 wants to merge 1 commit into
zerocracy:masterfrom
Titanism0v0:agent/issue-1243-overwrite-symbol
Open

Titanism0v0 wants to merge 1 commit into
zerocracy:masterfrom
Titanism0v0:agent/issue-1243-overwrite-symbol

Conversation

@Titanism0v0

Copy link
Copy Markdown
Contributor

Closes #1243.

The single-property form of Fbe.overwrite rejected a Symbol property name before reading or writing the fact, while its Hash form accepts Symbol keys. This change converts a Symbol name to a String before the existing String check. String inputs retain their behavior, and unsupported names such as Integer and nil retain their existing errors.

Validation:

  • Ruby 4.0.5, Bundler 2.5.16; locked dependencies satisfied.
  • RED: the new missing-property and existing-property Symbol tests each raised the original Fbe::Error on the unmodified code.
  • GREEN: bundle _2.5.16_ exec ruby -Itest test/fbe/test_overwrite.rb -- --no-cov passed (37 tests, 92 assertions); the non-String/non-Symbol compatibility test passed (1 test, 4 assertions).
  • bundle _2.5.16_ exec rubocop lib/fbe/overwrite.rb test/fbe/test_overwrite.rb passed (2 files, no offenses); bundle _2.5.16_ exec rake yard passed.
  • The full bundle _2.5.16_ exec rake remains red on both zero-patch and changed snapshots. Both reproduce the existing fake PR judges-action#193: add compare to Fbe::FakeOctokit #95 fixture mismatch, the root-only unwritable-directory test, and the award fixture returning 5 instead of 4. The changed snapshot reports 603 tests, 1637 assertions, 2 failures, 1 error, and 9 skips. The recorded baseline run reports 600 tests, 1627 assertions, 3 failures, 1 error, and 9 skips; its third failure was a one-off TestConsider#test_processes_fact_when_slot_fits_the_timeout timing failure.
  • The isolated baseline rerun and the changed full run passed that timing test. The full rake is not reported as green.
  • The full test suite passed after excluding only the three deterministic baseline failures (600 tests, 1631 assertions, 0 failures/errors, 9 skips). rake picks and full RuboCop also retain their separately confirmed baseline failures.

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.

The single-property form of Fbe.overwrite refuses a Symbol name, while its Hash form and the siblings accept one

1 participant