Fix coverage with several contract classes; table annotation and file path checks; clean task dir on write

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014aUaQeLnwbb1zTpN7kHeat
This commit is contained in:
Kral
2026-10-03 08:44:35 +02:00
parent fb576b0954
commit 03ab36149e
388 changed files with 28620 additions and 339 deletions

View File

@@ -0,0 +1,37 @@
# 1. Goal
Give the charge of each phone call. A billing program will read the charges, so the
calculation must be in the database, in a CDS view.
# 2. Open questions
None.
# 3. Context
- Table {{P}}CALLS (phone calls), package $TMP. Key: CALL_ID (CHAR 10).
Fields: CUSTOMER (CHAR 10), CALL_DATE (DATS), START_TIME (TIMS), DURATION_SEC (INT4),
DEST_TYPE (CHAR 1).
# 4. Contract
- Create the CDS view entity {{P}}I_CALL_CHARGE in package $TMP.
- Elements, with these names: CALL_ID (key), CUSTOMER, BILLABLE_MIN, RATE, CHARGE.
- No authorization check (#NOT_REQUIRED).
# 5. Business rules
1. Show one row for each call.
2. BILLABLE_MIN is the duration in minutes, rounded up to the next full minute. A call
of 1 second counts as 1 minute.
3. RATE is the price per minute for the destination type:
- 'N' (national): 0.09
- 'I' (international): 0.25
- any other value: 0.15
4. Calls longer than 1800 seconds get a 10% discount on the charge.
5. CHARGE is BILLABLE_MIN multiplied by RATE, with the discount applied, rounded to 2
decimals.
# 6. Constraints
- Release target: 8.16.
- Out of scope: do not change {{P}}CALLS.
# 7. Acceptance
- The view is active and has no syntax error.
- The hidden tests pass.
- Write ABAP Unit tests with CL_CDS_TEST_ENVIRONMENT in a global test class.