test(selftest): pin the top-tab underline invariant
TopTabBar had no observability at all -- no counter, no self-test reaching it. It now exposes LastRenderedUnderlineCount and MainWindow hands the component out the same way it already does for the sidebar. Three cases: one of two tabs active draws exactly one underline, a null active tab draws zero, and an active tab that is not in the list also draws zero. The last one matters because the strip skips popped-out tabs, so the active tab legitimately need not be among the drawn ones.
This commit is contained in:
@@ -204,6 +204,8 @@ internal sealed class MainWindow : Window, IFocusableChatWindow
|
||||
|
||||
internal Components.MessageList GetMessageListForSelfTest() => _messages;
|
||||
|
||||
internal Components.TopTabBar GetTopTabsForSelfTest() => _topTabs;
|
||||
|
||||
public override bool DrawConditions() => !_userHidden;
|
||||
|
||||
internal void UserHide() => _userHidden = true;
|
||||
|
||||
Reference in New Issue
Block a user