Add unit tests for wxGrid::Deselect{Row,Col}()

These functions got broken by the changes of cdf3187fe5 (Improve rows,
columns and cells deselection in wxGrid, 2020-03-26), but this went
unnoticed because they were not covered by the unit tests, so add the
tests for them to prevent this from happening again in the future.
This commit is contained in:
Vadim Zeitlin
2020-08-14 12:33:40 +02:00
parent 9be1f86ca0
commit 4475df8264

View File

@@ -565,6 +565,13 @@ TEST_CASE_METHOD(GridTestCase, "Grid::Selection", "[grid]")
CHECK(m_grid->IsInSelection(4, 0));
CHECK(m_grid->IsInSelection(4, 1));
CHECK(!m_grid->IsInSelection(3, 0));
m_grid->DeselectRow(4);
CHECK(!m_grid->IsInSelection(4, 0));
CHECK(!m_grid->IsInSelection(4, 1));
m_grid->DeselectCol(1);
CHECK(!m_grid->IsInSelection(0, 1));
}
TEST_CASE_METHOD(GridTestCase, "Grid::SelectionRange", "[grid]")