diff options
| author | Ioannis Tzavaras <tzavaras.jannis@gmail.com> | 2026-04-05 16:47:58 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-04-05 14:47:58 +0100 |
| commit | d7edc50eb441b0f90198c431f76030ebb90cc04d (patch) | |
| tree | c6b13075662278f06cc84a2805195e0784607e1a /src/protocols | |
| parent | 3af9b108909ee1e138cb8b3b6659563ab763e038 (diff) | |
tests: add unit tests for CDamageRing (#13995)
Adds GTest unit tests for CDamageRing in src/helpers/DamageRing.hpp.
Covers:
- setSize: initial full damage, same-size no-op, resize re-damage, zero-size
- damage: in-bounds accept, empty/out-of-bounds reject, partial clip
- damageEntire: normal path and zero-size no-op
- rotate: clears current, preserves as previous, wraps beyond ring length
- getBufferDamage: age<=0 and age>ring return full screen, age=1 current only,
age=2 accumulates previous, full ring accumulation, coalescing fallback,
empty ring returns empty
- hasChanged: false initially, true after damage/damageEntire, false after
rotate, false for out-of-bounds damage
27 new test cases, all passing.
Diffstat (limited to 'src/protocols')
0 files changed, 0 insertions, 0 deletions
