def METHOD_NAME(self):
    refs = ["were wolf"]
    preds = ["werewolf"]
    # S = 0, D = 0, I = 1, N = 9, CER = 1 / 9
    char_error_rate = cer.compute(predictions=preds, references=refs)
    self.assertTrue(abs(char_error_rate - 0.1111111) < 1e-6)
    refs = ["werewolf"]
    preds = ["weae     wolf"]
    # S = 1, D = 1, I = 0, N = 8, CER = 0.25
    char_error_rate = cer.compute(predictions=preds, references=refs)
    self.assertTrue(abs(char_error_rate - 0.25) < 1e-6)
    # consecutive whitespaces case 1
    refs = ["were wolf"]
    preds = ["were               wolf"]
    # S = 0, D = 0, I = 0, N = 9, CER = 0
    char_error_rate = cer.compute(predictions=preds, references=refs)
    self.assertTrue(abs(char_error_rate - 0.0) < 1e-6)
    # consecutive whitespaces case 2
    refs = ["were   wolf"]
    preds = ["were               wolf"]
    # S = 0, D = 0, I = 0, N = 9, CER = 0
    char_error_rate = cer.compute(predictions=preds, references=refs)
    self.assertTrue(abs(char_error_rate - 0.0) < 1e-6)