Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Tests
on: [push, pull_request]
permissions:
contents: read
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
lua: ['5.1', '5.2']
defaults:
run:
working-directory: addon
steps:
- uses: actions/checkout@v4
with:
path: addon
- uses: actions/checkout@v4
with:
repository: AlexAllocated/libchev
ref: 445c0cf5b3dd40d36461f6e0b9adc2feb8dfb16b
path: library
- run: sudo apt-get update && sudo apt-get install -y lua${{ matrix.lua }}
- run: lua${{ matrix.lua }} scripts/test.lua
- run: lua${{ matrix.lua }} scripts/test.lua . reverse
- run: python3 ../library/scripts/vendor.py . --check
- run: find . -name '*.lua' -exec luac${{ matrix.lua }} -p {} \;
- run: bash -n scripts/bump_version.sh && git diff --check
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 1.2.0 — 2026-09-24

Declare current Classic client support and add six-client checks for category borders, native settings and cleanup. Keep Blizzard in control of native styles; all clients use the same guarded border implementation.

Validation: 117 tests pass in both orders on Lua 5.1 and 5.2, with six client profiles, Lua parsing and exact private-library vendor checks. NoPoizen client smoke checks and package verification also pass. Live validation of the new adapters remains pending.

See [CLIENT_COMPATIBILITY.md](CLIENT_COMPATIBILITY.md) for source evidence, scope and validation limits.

## 1.1.1 — 2026-09-24

Keep overlapping debug consoles and their controls in one native stacking group through private libchev 1.1.3. Category menus stay with their owning console.
Expand Down
20 changes: 20 additions & 0 deletions CLIENT_COMPATIBILITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# PvPTogether client compatibility

One source tree supports these current client families. Interface metadata permits loading; API capabilities still decide which adapter can run. PTR/beta builds in the same family use those adapters when their contracts match. This does not claim support for arbitrary historical/private-server clients.

| Client family | Source snapshot | Interface targets |
| --- | --- | --- |
| Retail | Installed 12.1.0.69933 UI export | 120100 (existing older Retail targets retained) |
| Forever | Installed 1.60.1.69977 UI export; 1.60.1.70009 spell data | 16001 |
| Era / Hardcore / Season of Discovery | [1.15.9.69722](https://github.com/Gethe/wow-ui-source/tree/33e177d9bf38d76d5c6c6e05d5da78db1899659a) | 11509 |
| Anniversary / Burning Crusade | [2.5.6.69795](https://github.com/Gethe/wow-ui-source/tree/1463c686270b6c64e2c5c228f447c4597c0f8ba6) | 20506 |
| Mists Classic | [5.5.4.69934](https://github.com/Gethe/wow-ui-source/tree/cde55d0033e89b246381385b2f063cd6c6047ef8) | 50504 |
| Titan Reforged (China) | [3.80.2.69874](https://github.com/Gethe/wow-ui-source/tree/84ef503f0d2617494db84cc9c7e7b530e976f6e7) | 38001, 38002 |

The Classic references are mirrored Blizzard UI/API source. Source inspection and offline fixtures establish expected contracts, not engine-level taint safety, rendering or gameplay validation. The user requested source-backed implementation without waiting to level a Forever rogue. Live poison application, expiry, charge exhaustion and audio checks remain pending; no live test result is inferred from these fixtures. No SavedVariables were changed externally.

Every inspected client loads the common `Blizzard_NamePlates.xml` health bar at `UnitFrame.HealthBarsContainer.healthBar`, exposes `NamePlateBaseMixin:GetUnit()`, and registers `Settings.NAMEPLATE_OPTIONS_CATEGORY_ID`. No client-specific native style override is needed or restored.

The same implementation attaches addon-owned category borders to permitted native health bars. It leaves native layout and CVars with Blizzard, guards secrets/forbidden/protected frames, rechecks recycled identities, and retains deferred cleanup. The settings shortcut opens each client's own global nameplate settings. Missing capabilities remain explicit rather than selecting behavior from interface number alone.

Run `lua scripts/test.lua` and `lua scripts/test.lua . reverse` under Lua 5.1/5.2. `tests/clients.lua` covers each current family through border creation, friendly classification, native-settings navigation and disable cleanup, asserting no foreign-field writes, native geometry mutations, hooks or CVar writes. The existing suite covers restriction transitions, recycling, secret values and the shared console.
2 changes: 1 addition & 1 deletion CURSEFORGE_DESCRIPTION.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Open **Options → AddOns → PvPTogether** or use `/pt`. Each category has a bo
- `/pt test` runs fifteen checks on detached private values and opens current results in the same debug console, with chat fallback when the window is unavailable. It does not exercise live nameplates or certify taint safety.
- `/pvptogether` is an alias for `/pt`.

The same capability-driven implementation targets Retail and Forever. Borders use addon-owned textures attached to accessible native health bars. Protected or inaccessible regions wait until the client permits updates; cleanup retries when restrictions end.
The same capability-driven implementation targets Retail, Forever, Era/Hardcore/SoD, Anniversary/TBC, Mists Classic and Titan Reforged. Borders use addon-owned textures attached to accessible native health bars. Protected or inaccessible regions wait until the client permits updates; cleanup retries when restrictions end.

Per-category style overrides have been retired. Old saved style preferences are preserved but ignored. Reload the UI after updating to let Blizzard rebuild its native layout.

Expand Down
8 changes: 6 additions & 2 deletions PvPTogether.toc
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
## Interface: 120100, 16001
## Interface: 120100, 16001, 11509, 20506, 50504, 38001, 38002
## Interface-Vanilla: 11509
## Interface-TBC: 20506
## Interface-Mists: 50504
## Interface-Titan: 38001, 38002
## Interface-Mainline: 120100
## Interface-Camelot: 16001
## Title: PvPTogether
## Version: 1.1.1
## Version: 1.2.0
## Notes: Custom party, friendly, and enemy player nameplate borders.
## SavedVariablesPerCharacter: PvPTogetherDBChar
## Author: Chev
Expand Down
2 changes: 1 addition & 1 deletion scripts/test.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
-- runtime test patches a real Blizzard global, frame, mixin, or saved variable.
local root = arg[1] or "."
local harness = assert(loadfile(root .. "/tests/harness.lua"))()(root)
for _, suite in ipairs({ "core", "nameplates", "integration" }) do
for _, suite in ipairs({ "core", "nameplates", "integration", "clients" }) do
assert(loadfile(root .. "/tests/" .. suite .. ".lua"))()(harness)
end

Expand Down
39 changes: 39 additions & 0 deletions tests/clients.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
return function(H)
-- The inspected Classic XML uses the same health container and base GetUnit
-- contract as Retail/Forever. Test the complete border and settings path for
-- each current family, including old globals being absent.
for client, version in pairs({
retail = "12.1.0",
forever = "1.60.1",
era = "1.15.9",
tbc = "2.5.6",
mists = "5.5.4",
titan = "3.80.2",
}) do
H.test("client " .. client .. " borders, settings and cleanup", function()
local addon, state, env = H.new({
options = true,
configure = function(e)
e.GetBuildInfo = function()
return version, "fixture", "", 0
end
e.NamePlateSetupOptions, e.NamePlateConstants, e.NameplatesOverrides = nil, nil, nil
e.Settings.NAMEPLATE_OPTIONS_CATEGORY_ID = 37
Comment on lines +17 to +21

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Model each client's API shape in compatibility tests

Each purported client profile inherits the same Retail-oriented fixture globals and changes only GetBuildInfo plus three explicitly removed legacy globals; GetBuildInfo is used only for diagnostics, so the border/settings path is identical in all six cases. If a supported Classic family differs in Settings, C_NamePlate, restriction APIs, constants, or frame shape, every profile will still pass, leaving the release's advertised cross-client compatibility check ineffective. Configure the actual capability/API shape for each family rather than varying only its version string.

AGENTS.md reference: AGENTS.md:L9-L9

Useful? React with 👍 / 👎.

end,
})
local base, unit = state:plate("nameplate1", { guid = "Player-1", isPlayer = true, isFriend = true })
addon.isEnabled, addon.db.friendlyPlayerBorderEnabled = true, true
addon:EnsureNameplateEventFrame()
H.truthy(addon:RefreshNameplateFrame(base))
H.truthy(addon.nameplateBorderTintByUnitFrame[unit].visible)
H.truthy(addon:OpenBlizzardNameplateSettings())
H.equal(state.openCategory, 37)
addon:Disable()
H.falsy(addon.nameplateBorderTintByUnitFrame[unit].visible)
H.equal(state.foreignWrites, 0)
H.equal(state.nativeMutationAttempts, 0)
H.equal(#state.hooks, 0)
H.equal(#state.cvarWrites, 0)
end)
end
end
Loading