File: test_write_file.py

package info (click to toggle)
python-dom-toml 2.0.1-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,936 kB
  • sloc: python: 1,360; makefile: 7
file content (9 lines) | stat: -rw-r--r-- 224 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
# this package
import dom_toml


def test_dump(tmp_path):
	toml_obj = {"testing": "test\ntest"}
	path = tmp_path / "test.toml"
	dom_toml.dump(toml_obj, path)
	assert path.read_bytes().decode() == 'testing = "test\\ntest"\n'