def test_can_use_chardet_for_encoding(self): command = Command() command.set_encodings('chardet') command.set_source_patterns(self.pygount_folder) command.execute()
def test_can_set_encoding(self): command = Command() command.set_encodings('automatic;cp1252') self.assertEqual(command.default_encoding, 'automatic') self.assertEqual(command.fallback_encoding, 'cp1252')
def test_can_use_chardet_for_encoding(self): command = Command() command.set_encodings("chardet") command.set_source_patterns(_PYGOUNT_SOURCE_FOLDER) command.execute()
def test_can_set_encoding(self): command = Command() command.set_encodings("automatic;cp1252") assert command.default_encoding == "automatic" assert command.fallback_encoding == "cp1252"