Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/Textualize/rich
/ test_print_json_data_with_default
Function
test_print_json_data_with_default
tests/test_json.py:5–8 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
3
4
5
def
test_print_json_data_with_default():
6
date = datetime.date(2021, 1, 1)
7
json = JSON.from_data({
"date"
: date}, default=
lambda
d: d.isoformat())
8
assert str(json.text) ==
'{\n "date": "2021-01-01"\n}'
Callers
nothing calls this directly
Calls
1
from_data
Method · 0.80
Tested by
no test coverage detected