diff options
author | nyamatongwe <devnull@localhost> | 2011-02-10 23:28:29 +1100 |
---|---|---|
committer | nyamatongwe <devnull@localhost> | 2011-02-10 23:28:29 +1100 |
commit | 73ab73b08eb3f5523d05a3a0dd55701a19168498 (patch) | |
tree | 05450a7c8fa0fb770ef03d6a6ec4600d3857002d /test/unit/testSparseState.cxx | |
parent | 24b684b8df2786ac97ddc01f5f670b4003c59428 (diff) | |
download | scintilla-mirror-73ab73b08eb3f5523d05a3a0dd55701a19168498.tar.gz |
Only append a state if the value differs from the last current value.
Diffstat (limited to 'test/unit/testSparseState.cxx')
-rw-r--r-- | test/unit/testSparseState.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/unit/testSparseState.cxx b/test/unit/testSparseState.cxx index f16f829d4..74f1032b2 100644 --- a/test/unit/testSparseState.cxx +++ b/test/unit/testSparseState.cxx @@ -95,6 +95,13 @@ TEST_F(SparseStateTest, ReplaceLast) { EXPECT_EQ(32, pss->ValueAt(3)); } +TEST_F(SparseStateTest, CheckOnlyChangeAppended) { + pss->Set(0, 30); + pss->Set(2, 31); + pss->Set(3, 31); + EXPECT_EQ(2u, pss->size()); +} + class SparseStateStringTest : public ::testing::Test { protected: virtual void SetUp() { |