@@ -2104,3 +2104,52 @@ def test_focus_mode_on_focusable_read_only_lists():
21042104 ]),
21052105 message = "focus mode - focus list item and turn on focus mode"
21062106 )
2107+
2108+
2109+ def test_i10890 ():
2110+ """
2111+ Ensure that sort state is announced on a column header when changed with inner button
2112+ """
2113+ spy = _NvdaLib .getSpyLib ()
2114+ # Chrome sometimes exposes tables as clickable, sometimes not.
2115+ # This test does not need to know, so disable reporting of clickables.
2116+ spy .set_configValue (["documentFormatting" , "reportClickable" ], False )
2117+ testFile = os .path .join (ARIAExamplesDir , "grid" , "datagrids.html" )
2118+ _chrome .prepareChrome (
2119+ f"""
2120+ <iframe src="{ testFile } "></iframe>
2121+ """
2122+ )
2123+ # Jump to the Example 2 heading
2124+ _chrome .getSpeechAfterKey ("3" )
2125+ actualSpeech = _chrome .getSpeechAfterKey ("3" )
2126+ _asserts .strings_match (
2127+ actualSpeech ,
2128+ SPEECH_SEP .join ([
2129+ "Example 2: Sortable Data Grid With Editable Cells" ,
2130+ "heading" ,
2131+ "level 3" ,
2132+ ])
2133+ )
2134+ # Jump to the table
2135+ actualSpeech = _chrome .getSpeechAfterKey ("t" )
2136+ _asserts .strings_match (
2137+ actualSpeech ,
2138+ SPEECH_SEP .join ([
2139+ "Transactions January 1 through January 7" ,
2140+ "table" ,
2141+ "with 8 rows and 6 columns" ,
2142+ "row 1" ,
2143+ "column 1" ,
2144+ "sorted ascending" ,
2145+ "Date" ,
2146+ "button" ,
2147+ ])
2148+ )
2149+ # Press the button
2150+ actualSpeech = _chrome .getSpeechAfterKey ("space" )
2151+ # and ensure that the new sort state is spoken.
2152+ _asserts .strings_match (
2153+ actualSpeech ,
2154+ "sorted descending" ,
2155+ )
0 commit comments