MCPcopy Create free account
hub / github.com/copier-org/copier / _encode

Function _encode

tests/test_settings.py:99–102  ·  view source on GitHub ↗
(data: str)

Source from the content-addressed store, hash-verified

97 settings_path: Path, monkeypatch: pytest.MonkeyPatch, encoding: str
98) -> None:
99 def _encode(data: str) -> bytes:
100 if encoding.startswith("utf-16"):
101 data = f"\ufeff{data}"
102 return data.encode(encoding)
103
104 defaults = {
105 "foo": "\u3053\u3093\u306b\u3061\u306f", # japanese hiragana

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected