Repository navigation
fixed #13 割引率 1(100% 引き)の明細で明細金額の計算が例外になる誤りを直す - #14
Merged
Merged
Conversation
入力の検証の境界を HLD/Common.md の VAL-NUMERIC(単価 >= 0、割引 0〜1)に戻した。 割引率 1 を範囲外として拒否していた(Discount >= 1)。同じ型の誤りで単価 0 も 拒否していた(UnitPrice <= 0)ので、併せて直した。回帰テストを 6 件足した(境界の値と、その直外)。 Found-By: user-report Found-By: type-review (#13 の横展開:UnitPrice の境界) Tested-with: unit Reviewed-with: opentouryo-change-reviewer (claude-sonnet-5-5) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fixed #13
人が必ず見る箇所(品質マップ:
src/OrderCalc=リスク「高」)OrderAmount.Validateの境界:UnitPrice < 0・Discount < 0 || Discount > 1(HLD/Common.md VAL-NUMERIC:単価 >= 0、割引 0〜1)変更
Discount >= 1)のを、仕様どおり 1 を含むように直したUnitPrice <= 0)ので、横展開として併せて直した確かめたこと
dotnet test tests/OrderCalc.Tests/OrderCalc.Tests.csproj:15 件合格opentouryo-change-reviewer(claude-sonnet-5-5。主は claude-opus-5-5=別モデル)Discountが NaN だと検証を通り、(decimal)のキャストでOverflowExceptionになる(変更前から)🤖 Generated with Claude Code