hyperjson 0.2.4

A hyper-fast Python module for reading/writing JSON data
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import pytest
import json
import hyperjson
import io


def test_load():
    obj = io.StringIO(u'["streaming API"]')
    assert json.load(obj) == hyperjson.load(obj)


def test_load_invalid_reader():
    with pytest.raises(TypeError):
        hyperjson.load("{}", '')