# Untested Code Analysis Report (modified lines only)

**Generated**: 2026-06-22 11:14:41

---

## 📄 src/backend/commands/explain.c

**File coverage**: 180/190 lines (94.7%)

### Function: `deparse_rpr_node` (lines 3029-3090)

**Function coverage**: 37/38 lines (97.4%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/commands/explain.c:3073`

### Function: `rpr_match_end` (lines 3097-3110)

**Function coverage**: 7/8 lines (87.5%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/commands/explain.c:3109`

### Function: `show_window_def` (lines 3157-3284)

**Function coverage**: 26/34 lines (76.5%)

#### 🔴 Untested lines (4 ranges)

- [ ] `src/backend/commands/explain.c:3251-3252`
- [ ] `src/backend/commands/explain.c:3261-3262`
- [ ] `src/backend/commands/explain.c:3265-3266`
- [ ] `src/backend/commands/explain.c:3277-3278`

---

## 📄 src/backend/executor/execExprInterp.c

**File coverage**: 80/88 lines (90.9%)

### Function: `ExecEvalRPRNavSet` (lines 6053-6220)

**Function coverage**: 52/60 lines (86.7%)

#### 🔴 Untested lines (7 ranges)

- [ ] `src/backend/executor/execExprInterp.c:6102`
- [ ] `src/backend/executor/execExprInterp.c:6106`
- [ ] `src/backend/executor/execExprInterp.c:6148`
- [ ] `src/backend/executor/execExprInterp.c:6153`
- [ ] `src/backend/executor/execExprInterp.c:6183`
- [ ] `src/backend/executor/execExprInterp.c:6188`
- [ ] `src/backend/executor/execExprInterp.c:6192-6193`

---

## 📄 src/backend/executor/execRPR.c

**File coverage**: 584/588 lines (99.3%)

### Function: `nfa_advance_end` (lines 1133-1307)

**Function coverage**: 58/62 lines (93.5%)

#### 🔴 Untested lines (3 ranges)

- [ ] `src/backend/executor/execRPR.c:1186-1187`
- [ ] `src/backend/executor/execRPR.c:1195`
- [ ] `src/backend/executor/execRPR.c:1213`

---

## 📄 src/backend/executor/nodeWindowAgg.c

**File coverage**: 441/471 lines (93.6%)

### Function: `WinCheckAndInitializeNullTreatment` (lines 4932-4950)

**Function coverage**: 9/10 lines (90.0%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/executor/nodeWindowAgg.c:4942`

### Function: `WinGetSlotInFrame` (lines 4706-4916)

**Function coverage**: 85/101 lines (84.2%)

#### 🔴 Untested lines (12 ranges)

- [ ] `src/backend/executor/nodeWindowAgg.c:4720-4721`
- [ ] `src/backend/executor/nodeWindowAgg.c:4727`
- [ ] `src/backend/executor/nodeWindowAgg.c:4776`
- [ ] `src/backend/executor/nodeWindowAgg.c:4779-4780`
- [ ] `src/backend/executor/nodeWindowAgg.c:4795`
- [ ] `src/backend/executor/nodeWindowAgg.c:4856`
- [ ] `src/backend/executor/nodeWindowAgg.c:4860`
- [ ] `src/backend/executor/nodeWindowAgg.c:4863-4864`
- [ ] `src/backend/executor/nodeWindowAgg.c:4877`
- [ ] `src/backend/executor/nodeWindowAgg.c:4882-4883`
- [ ] `src/backend/executor/nodeWindowAgg.c:4896`
- [ ] `src/backend/executor/nodeWindowAgg.c:4913`

### Function: `eval_define_offsets` (lines 4166-4212)

**Function coverage**: 26/27 lines (96.3%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/executor/nodeWindowAgg.c:4208`

### Function: `eval_nav_offset_helper` (lines 3999-4022)

**Function coverage**: 13/14 lines (92.9%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/executor/nodeWindowAgg.c:4019`

### Function: `ignorenulls_getfuncarginframe` (lines 3680-3856)

**Function coverage**: 15/16 lines (93.8%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/executor/nodeWindowAgg.c:3766`

### Function: `row_is_in_reduced_frame` (lines 4243-4291)

**Function coverage**: 18/20 lines (90.0%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/executor/nodeWindowAgg.c:4284-4285`

### Function: `visit_nav_exec` (lines 4054-4150)

**Function coverage**: 28/35 lines (80.0%)

#### 🔴 Untested lines (6 ranges)

- [ ] `src/backend/executor/nodeWindowAgg.c:4082`
- [ ] `src/backend/executor/nodeWindowAgg.c:4103-4104`
- [ ] `src/backend/executor/nodeWindowAgg.c:4115`
- [ ] `src/backend/executor/nodeWindowAgg.c:4117`
- [ ] `src/backend/executor/nodeWindowAgg.c:4119`
- [ ] `src/backend/executor/nodeWindowAgg.c:4136`

### Function: `window_gettupleslot` (lines 3555-3639)

**Function coverage**: 0/1 lines (0.0%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/executor/nodeWindowAgg.c:3574`

---

## 📄 src/backend/nodes/equalfuncs.c

**File coverage**: 0/13 lines (0.0%)

### Function: `_equalRPRPattern` (lines 154-185)

**Function coverage**: 0/13 lines (0.0%)

#### 🔴 Untested lines (10 ranges)

- [ ] `src/backend/nodes/equalfuncs.c:154`
- [ ] `src/backend/nodes/equalfuncs.c:156-158`
- [ ] `src/backend/nodes/equalfuncs.c:161`
- [ ] `src/backend/nodes/equalfuncs.c:163`
- [ ] `src/backend/nodes/equalfuncs.c:165`
- [ ] `src/backend/nodes/equalfuncs.c:167`
- [ ] `src/backend/nodes/equalfuncs.c:173`
- [ ] `src/backend/nodes/equalfuncs.c:175`
- [ ] `src/backend/nodes/equalfuncs.c:177-178`
- [ ] `src/backend/nodes/equalfuncs.c:182`

---

## 📄 src/backend/nodes/nodeFuncs.c

**File coverage**: 37/48 lines (77.1%)

### Function: `exprCollation` (lines 832-1092)

**Function coverage**: 0/3 lines (0.0%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/nodes/nodeFuncs.c:862-864`

### Function: `exprTypmod` (lines 307-554)

**Function coverage**: 0/2 lines (0.0%)

#### 🔴 Untested lines (2 ranges)

- [ ] `src/backend/nodes/nodeFuncs.c:395`
- [ ] `src/backend/nodes/nodeFuncs.c:397`

### Function: `expression_tree_mutator_impl` (lines 3052-3911)

**Function coverage**: 9/10 lines (90.0%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/nodes/nodeFuncs.c:3619`

### Function: `expression_tree_walker_impl` (lines 2129-2772)

**Function coverage**: 6/8 lines (75.0%)

#### 🔴 Untested lines (2 ranges)

- [ ] `src/backend/nodes/nodeFuncs.c:2229`
- [ ] `src/backend/nodes/nodeFuncs.c:2466`

### Function: `raw_expression_tree_walker_impl` (lines 4163-4931)

**Function coverage**: 8/11 lines (72.7%)

#### 🔴 Untested lines (3 ranges)

- [ ] `src/backend/nodes/nodeFuncs.c:4651`
- [ ] `src/backend/nodes/nodeFuncs.c:4914`
- [ ] `src/backend/nodes/nodeFuncs.c:4922`

---

## 📄 src/backend/nodes/outfuncs.c

**File coverage**: 28/30 lines (93.3%)

### Function: `_outRPRPattern` (lines 732-779)

**Function coverage**: 28/30 lines (93.3%)

#### 🔴 Untested lines (2 ranges)

- [ ] `src/backend/nodes/outfuncs.c:754`
- [ ] `src/backend/nodes/outfuncs.c:776`

---

## 📄 src/backend/nodes/readfuncs.c

**File coverage**: 46/48 lines (95.8%)

### Function: `_readRPRPattern` (lines 572-653)

**Function coverage**: 46/48 lines (95.8%)

#### 🔴 Untested lines (2 ranges)

- [ ] `src/backend/nodes/readfuncs.c:595`
- [ ] `src/backend/nodes/readfuncs.c:647`

---

## 📄 src/backend/optimizer/plan/createplan.c

**File coverage**: 126/127 lines (99.2%)

### Function: `visit_nav_plan` (lines 2555-2711)

**Function coverage**: 56/57 lines (98.2%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/optimizer/plan/createplan.c:2608`

---

## 📄 src/backend/optimizer/plan/rpr.c

**File coverage**: 569/575 lines (99.0%)

### Function: `fillRPRPattern` (lines 1396-1427)

**Function coverage**: 14/15 lines (93.3%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/optimizer/plan/rpr.c:1425`

### Function: `getVarIdFromPattern` (lines 1162-1173)

**Function coverage**: 4/5 lines (80.0%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/optimizer/plan/rpr.c:1171`

### Function: `optimizeRPRPattern` (lines 949-970)

**Function coverage**: 10/11 lines (90.9%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/optimizer/plan/rpr.c:968`

### Function: `reject_volatile_in_define_walker` (lines 1861-1876)

**Function coverage**: 6/7 lines (85.7%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/optimizer/plan/rpr.c:1871`

### Function: `rprPatternEqual` (lines 105-131)

**Function coverage**: 10/11 lines (90.9%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/optimizer/plan/rpr.c:129`

### Function: `scanRPRPattern` (lines 1102-1118)

**Function coverage**: 7/8 lines (87.5%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/optimizer/plan/rpr.c:1113`

---

## 📄 src/backend/parser/parse_func.c

**File coverage**: 55/57 lines (96.5%)

### Function: `ParseRPRNavCall` (lines 2102-2226)

**Function coverage**: 37/39 lines (94.9%)

#### 🔴 Untested lines (2 ranges)

- [ ] `src/backend/parser/parse_func.c:2136`
- [ ] `src/backend/parser/parse_func.c:2208`

---

## 📄 src/backend/utils/adt/ruleutils.c

**File coverage**: 145/150 lines (96.7%)

### Function: `generate_function_name` (lines 14184-14295)

**Function coverage**: 3/6 lines (50.0%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/utils/adt/ruleutils.c:14232-14234`

### Function: `get_rule_expr` (lines 10002-11477)

**Function coverage**: 38/40 lines (95.0%)

#### 🔴 Untested lines (1 ranges)

- [ ] `src/backend/utils/adt/ruleutils.c:10163-10164`

---

## 📊 Summary Statistics

- **Files**: 12/25 files contain untested code
- **Functions**: 172/173 functions covered (99.4%)
  - Untested: 1 functions
- **Lines**: 2608/2702 lines covered (96.5%) - **modified lines only**
  - Untested: 94 lines

---

## 💡 Usage Guide

1. Change `- [ ]` at the front of each item to `- [x]` to mark work as done
2. The `path:line` or `path:start-end` format lets you identify the exact location
3. Provide this file to Claude Code and request test cases
   - e.g. "Write whitebox tests for the lines in untested.md"
4. **Note**: This report only includes modified lines (not full-file coverage)
