Test generating a structure with arrays.
()
| 40 | |
| 41 | |
| 42 | def test_generate_array_structure(): |
| 43 | """Test generating a structure with arrays.""" |
| 44 | schema = { |
| 45 | "users": [{ |
| 46 | "id": "user id", |
| 47 | "name": "user name", |
| 48 | "email": "user email" |
| 49 | }] |
| 50 | } |
| 51 | |
| 52 | result = generate_structure(schema) |
| 53 | |
| 54 | assert "users[N]{id,name,email}:" in result |
| 55 | assert "<user id>" in result |
| 56 | assert "<user name>" in result |
| 57 | assert "<user email>" in result |
| 58 | assert "..." in result |
| 59 | |
| 60 | |
| 61 | def test_generate_root_array_structure(): |
nothing calls this directly
no test coverage detected
searching dependent graphs…