code: def test_invariant(self):
      enc = encoders.RankHotEncoder(
          cols=["invariant"], drop_invariant=True
      )
      enc.fit(X)
      self.assertFalse(
          any(
              [
                  c.startswith("invariant")
                  for c in enc.feature_names_out_
              ]
          )
      )
      self.assertTrue(
          any([c.startswith("invariant") for c in enc.invariant_cols])
      )
  
file_path: category_encoders/tests/test_rankhot.py
imports: import pandas
  from unittest import TestCase
  import tests.helpers
  import numpy
  import category_encoders
label_desc: Use image node_id 5 for calling the TestRankHotEncoder obj's underlying member method code with example usage: obj.test_invariant() without return types