def METHOD_NAME(self):
    # training data
    d = {"col1": ["a", "a", "c"]}
    df = pd.DataFrame(data=d)
    # fit encoder
    le = LabelEncoder()
    le.fit(df["col1"])
    # test data
    d_test = {"col2": ["c", "c", "a"]}
    df_test = pd.DataFrame(data=d_test)
    # transform
    y = le.transform(df_test["col2"])
    self.assertEqual(y[0], 1)
    self.assertEqual(y[1], 1)
    self.assertEqual(y[2], 0)