()
| 555 | |
| 556 | #[test] |
| 557 | fn validate_entities_field_missing() { |
| 558 | let json_data = json!( |
| 559 | { |
| 560 | "entities":[ |
| 561 | { |
| 562 | "uid": { |
| 563 | "type": "PhotoApp::User", |
| 564 | "id": "alice" |
| 565 | }, |
| 566 | "attrs": { |
| 567 | "userId": "897345789237492878" |
| 568 | }, |
| 569 | "parents": [ |
| 570 | { |
| 571 | "type": "PhotoApp::UserGroup", |
| 572 | "id": "alice_friends" |
| 573 | }, |
| 574 | { |
| 575 | "type": "PhotoApp::UserGroup", |
| 576 | "id": "AVTeam" |
| 577 | } |
| 578 | ] |
| 579 | }, |
| 580 | { |
| 581 | "uid": { |
| 582 | "type": "PhotoApp::Photo", |
| 583 | "id": "vacationPhoto.jpg" |
| 584 | }, |
| 585 | "attrs": { |
| 586 | "private": false, |
| 587 | "account": { |
| 588 | "__entity": { |
| 589 | "type": "PhotoApp::Account", |
| 590 | "id": "ahmad" |
| 591 | } |
| 592 | } |
| 593 | }, |
| 594 | "parents": [] |
| 595 | }, |
| 596 | { |
| 597 | "uid": { |
| 598 | "type": "PhotoApp::UserGroup", |
| 599 | "id": "alice_friends" |
| 600 | }, |
| 601 | "attrs": {}, |
| 602 | "parents": [] |
| 603 | }, |
| 604 | { |
| 605 | "uid": { |
| 606 | "type": "PhotoApp::UserGroup", |
| 607 | "id": "AVTeam" |
| 608 | }, |
| 609 | "attrs": {}, |
| 610 | "parents": [] |
| 611 | } |
| 612 | ], |
| 613 | "schema":{ |
| 614 | "PhotoApp": { |
nothing calls this directly
no test coverage detected