(ko_tokenizer)
| 6 | |
| 7 | |
| 8 | def test_ko_tokenizer_serialize(ko_tokenizer): |
| 9 | tokenizer_bytes = ko_tokenizer.to_bytes() |
| 10 | nlp = Korean() |
| 11 | nlp.tokenizer.from_bytes(tokenizer_bytes) |
| 12 | assert tokenizer_bytes == nlp.tokenizer.to_bytes() |
| 13 | |
| 14 | with make_tempdir() as d: |
| 15 | file_path = d / "tokenizer" |
| 16 | ko_tokenizer.to_disk(file_path) |
| 17 | nlp = Korean() |
| 18 | nlp.tokenizer.from_disk(file_path) |
| 19 | assert tokenizer_bytes == nlp.tokenizer.to_bytes() |
| 20 | |
| 21 | |
| 22 | def test_ko_tokenizer_pickle(ko_tokenizer): |
nothing calls this directly
no test coverage detected
searching dependent graphs…