cassandra-pr mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dineshjoshi <...@git.apache.org>
Subject [GitHub] cassandra-dtest pull request #41: 14421
Date Tue, 08 Jan 2019 00:59:14 GMT
Github user dineshjoshi commented on a diff in the pull request:

    https://github.com/apache/cassandra-dtest/pull/41#discussion_r245846879
  
    --- Diff: sstable_generation_loading_test.py ---
    @@ -27,45 +28,68 @@ def fixture_add_additional_log_patterns(self, fixture_dtest_setup):
             fixture_dtest_setup.allow_log_errors = True
     
         upgrade_from = None
    -    compact = False
    +    test_compact = False
    +
    +    def compact(self):
    +        return self.fixture_dtest_setup.cluster.version() < MAJOR_VERSION_4 and self.test_compact
     
         def create_schema(self, session, ks, compression):
             create_ks(session, ks, rf=2)
    -        create_cf(session, "standard1", compression=compression, compact_storage=self.compact)
    +        create_cf(session, "standard1", compression=compression, compact_storage=self.compact())
             create_cf(session, "counter1", compression=compression, columns={'v': 'counter'},
    -                  compact_storage=self.compact)
    +                  compact_storage=self.compact())
     
         def test_sstableloader_compression_none_to_none(self):
    +        if self.__class__.__name__ != 'TestBasedSSTableLoader' and self.upgrade_from
is None:
    --- End diff --
    
    Since these two lines are redundant. Perhaps refactor this into a small method and reuse?


---

---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@cassandra.apache.org
For additional commands, e-mail: pr-help@cassandra.apache.org


Mime
View raw message