# -*- coding: utf-8 -*-

from .conftest import mock_urllib_request_urlopen
import json
import mock


def test_get_materials(client):
    with mock.patch('urllib.request.urlopen', new=mock_urllib_request_urlopen):
        response = client.get('/get-materials')
    data = json.loads(response.data)
    assert len(data['items']) == 50
    assert len(data['categories']) == 9

324893cb1953a509a446a71c80843be324c56cea
<mask token>

<mask token>


def test_get_materials(client):
    with mock.patch('urllib.request.urlopen', new=mock_urllib_request_urlopen):
        response = client.get('/get-materials')
    data = json.loads(response.data)
    assert len(data['items']) == 50
    assert len(data['categories']) == 9

from .conftest import mock_urllib_request_urlopen
import json
import mock


def test_get_materials(client):
    with mock.patch('urllib.request.urlopen', new=mock_urllib_request_urlopen):
        response = client.get('/get-materials')
    data = json.loads(response.data)
    assert len(data['items']) == 50
    assert len(data['categories']) == 9

# -*- coding: utf-8 -*-

from .conftest import mock_urllib_request_urlopen
import json
import mock


def test_get_materials(client):
    with mock.patch('urllib.request.urlopen', new=mock_urllib_request_urlopen):
        response = client.get('/get-materials')
    data = json.loads(response.data)
    assert len(data['items']) == 50
    assert len(data['categories']) == 9
