Add dedicated GraniteMoe adapter tests (#1302)#1524
Merged
jlarson4 merged 1 commit intoJul 20, 2026
Conversation
granite_moe had substantive test coverage, but embedded inside test_granite_adapter.py rather than in its own file — inconsistent with every other architecture listed in TransformerLensOrg#1302 (including granite_moe_hybrid), which each get a dedicated test_<name>_adapter.py. Moves that coverage into test_granite_moe_adapter.py and adds the one piece that was missing: an explicit config-flag test class (GraniteMoe doesn't override config setup, so it inherits dense Granite's flags, but nothing asserted that directly before). test_granite_adapter.py goes back to covering only GraniteArchitectureAdapter, matching its own docstring.
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.
Closes part of #1302.
granite_moealready had substantive test coverage, but it wasembedded inside
test_granite_adapter.pyrather than living in itsown file — inconsistent with every other architecture from #1302
(including
granite_moe_hybrid), each of which gets a dedicatedtest_<name>_adapter.py.This moves that coverage into
test_granite_moe_adapter.pyand addsthe one piece that was missing: an explicit config-flag test class.
GraniteMoeArchitectureAdapterdoesn't override config setup, so itinherits dense Granite's flags, but nothing asserted that directly
before.
test_granite_adapter.pygoes back to covering onlyGraniteArchitectureAdapter, matching its own docstring.Verified:
broke
granite_moe.py's MoE bridge name and watchedtest_moe_hf_pathfail, then reverted.tests/unit/model_bridge/supported_architectures/suite passes(2070/2070) with these changes in place.