Make WordPress Core

Changeset 44217


Ignore:
Timestamp:
12/16/2018 01:37:56 AM (8 years ago)
Author:
jeremyfelt
Message:

REST API: Regenerate fixure schema after introduction of new endpoints.

This fixture schema ensures wp-api-generated.js doesn't change when running tests in local dev environments.

Merges [43851] from the 5.0 branch to trunk. wp-api-generated.js generated based on current trunk.
Props danielbachhuber.
Fixes #45196.

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/tests/phpunit/tests/rest-api/rest-schema-setup.php

    r44150 r44217  
    477477                'Schema.routes./wp/v2/pages._links.self'           => 'http://example.org/index.php?rest_route=/wp/v2/pages',
    478478                'Schema.routes./wp/v2/media._links.self'           => 'http://example.org/index.php?rest_route=/wp/v2/media',
     479                'Schema.routes./wp/v2/blocks._links.self'          => 'http://example.org/index.php?rest_route=/wp/v2/blocks',
    479480                'Schema.routes./wp/v2/types._links.self'           => 'http://example.org/index.php?rest_route=/wp/v2/types',
    480481                'Schema.routes./wp/v2/statuses._links.self'        => 'http://example.org/index.php?rest_route=/wp/v2/statuses',
     
    485486                'Schema.routes./wp/v2/users/me._links.self'        => 'http://example.org/index.php?rest_route=/wp/v2/users/me',
    486487                'Schema.routes./wp/v2/comments._links.self'        => 'http://example.org/index.php?rest_route=/wp/v2/comments',
     488                'Schema.routes./wp/v2/search._links.self'          => 'http://example.org/index.php?rest_route=/wp/v2/search',
    487489                'Schema.routes./wp/v2/settings._links.self'        => 'http://example.org/index.php?rest_route=/wp/v2/settings',
     490                'Schema.routes./wp/v2/themes._links.self'          => 'http://example.org/index.php?rest_route=/wp/v2/themes',
    488491                'oembed.routes./oembed/1.0._links.self'            => 'http://example.org/index.php?rest_route=/oembed/1.0',
    489492                'oembed.routes./oembed/1.0/embed._links.self'      => 'http://example.org/index.php?rest_route=/oembed/1.0/embed',
     
    502505                'PostsCollection.0._links.replies.0.href'          => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4',
    503506                'PostsCollection.0._links.version-history.0.href'  => 'http://example.org/index.php?rest_route=/wp/v2/posts/4/revisions',
    504                 'PostsCollection.0._links.predecessor-version.0.id' => 5,
    505                 'PostsCollection.0._links.predecessor-version.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/posts/4/revisions/5',
     507                'PostsCollection.0._links.predecessor-version.0.id' => 6,
     508                'PostsCollection.0._links.predecessor-version.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/posts/4/revisions/6',
    506509                'PostsCollection.0._links.wp:attachment.0.href'    => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4',
    507510                'PostsCollection.0._links.wp:term.0.href'          => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4',
     
    511514                'PostModel.link'                                   => 'http://example.org/?p=4',
    512515                'postRevisions.0.author'                           => 2,
    513                 'postRevisions.0.id'                               => 5,
     516                'postRevisions.0.id'                               => 6,
    514517                'postRevisions.0.parent'                           => 4,
    515                 'postRevisions.0.slug'                             => '4-revision-v1',
    516                 'postRevisions.0.guid.rendered'                    => 'http://example.org/?p=5',
     518                'postRevisions.0.slug'                             => '4-autosave-v1',
     519                'postRevisions.0.guid.rendered'                    => 'http://example.org/?p=6',
    517520                'postRevisions.0._links.parent.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/posts/4',
     521                'postRevisions.1.author'                           => 2,
     522                'postRevisions.1.id'                               => 5,
     523                'postRevisions.1.parent'                           => 4,
     524                'postRevisions.1.slug'                             => '4-revision-v1',
     525                'postRevisions.1.guid.rendered'                    => 'http://example.org/?p=5',
     526                'postRevisions.1._links.parent.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/posts/4',
    518527                'revision.author'                                  => 2,
    519528                'revision.id'                                      => 5,
     
    521530                'revision.slug'                                    => '4-revision-v1',
    522531                'revision.guid.rendered'                           => 'http://example.org/?p=5',
    523                 'PagesCollection.0.id'                             => 6,
    524                 'PagesCollection.0.guid.rendered'                  => 'http://example.org/?page_id=6',
    525                 'PagesCollection.0.link'                           => 'http://example.org/?page_id=6',
    526                 'PagesCollection.0._links.self.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/pages/6',
     532                'postAutosaves.0.author'                           => 2,
     533                'postAutosaves.0.id'                               => 6,
     534                'postAutosaves.0.parent'                           => 4,
     535                'postAutosaves.0.slug'                             => '4-autosave-v1',
     536                'postAutosaves.0.guid.rendered'                    => 'http://example.org/?p=6',
     537                'postAutosaves.0._links.parent.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/posts/4',
     538                'autosave.author'                                  => 2,
     539                'autosave.id'                                      => 6,
     540                'autosave.parent'                                  => 4,
     541                'autosave.slug'                                    => '4-autosave-v1',
     542                'autosave.guid.rendered'                           => 'http://example.org/?p=6',
     543                'PagesCollection.0.id'                             => 7,
     544                'PagesCollection.0.guid.rendered'                  => 'http://example.org/?page_id=7',
     545                'PagesCollection.0.link'                           => 'http://example.org/?page_id=7',
     546                'PagesCollection.0._links.self.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/pages/7',
    527547                'PagesCollection.0._links.collection.0.href'       => 'http://example.org/index.php?rest_route=/wp/v2/pages',
    528548                'PagesCollection.0._links.about.0.href'            => 'http://example.org/index.php?rest_route=/wp/v2/types/page',
    529                 'PagesCollection.0._links.replies.0.href'          => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=6',
    530                 'PagesCollection.0._links.version-history.0.href'  => 'http://example.org/index.php?rest_route=/wp/v2/pages/6/revisions',
    531                 'PagesCollection.0._links.predecessor-version.0.id' => 7,
    532                 'PagesCollection.0._links.predecessor-version.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/pages/6/revisions/7',
    533                 'PagesCollection.0._links.wp:attachment.0.href'    => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=6',
    534                 'PageModel.id'                                     => 6,
    535                 'PageModel.guid.rendered'                          => 'http://example.org/?page_id=6',
    536                 'PageModel.link'                                   => 'http://example.org/?page_id=6',
     549                'PagesCollection.0._links.replies.0.href'          => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=7',
     550                'PagesCollection.0._links.version-history.0.href'  => 'http://example.org/index.php?rest_route=/wp/v2/pages/7/revisions',
     551                'PagesCollection.0._links.predecessor-version.0.id' => 9,
     552                'PagesCollection.0._links.predecessor-version.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/pages/7/revisions/9',
     553                'PagesCollection.0._links.wp:attachment.0.href'    => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=7',
     554                'PageModel.id'                                     => 7,
     555                'PageModel.guid.rendered'                          => 'http://example.org/?page_id=7',
     556                'PageModel.link'                                   => 'http://example.org/?page_id=7',
    537557                'pageRevisions.0.author'                           => 2,
    538                 'pageRevisions.0.id'                               => 7,
    539                 'pageRevisions.0.parent'                           => 6,
    540                 'pageRevisions.0.slug'                             => '6-revision-v1',
    541                 'pageRevisions.0.guid.rendered'                    => 'http://example.org/?p=7',
    542                 'pageRevisions.0._links.parent.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/pages/6',
     558                'pageRevisions.0.id'                               => 9,
     559                'pageRevisions.0.parent'                           => 7,
     560                'pageRevisions.0.slug'                             => '7-autosave-v1',
     561                'pageRevisions.0.guid.rendered'                    => 'http://example.org/?p=9',
     562                'pageRevisions.0._links.parent.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/pages/7',
     563                'pageRevisions.1.author'                           => 2,
     564                'pageRevisions.1.id'                               => 8,
     565                'pageRevisions.1.parent'                           => 7,
     566                'pageRevisions.1.slug'                             => '7-revision-v1',
     567                'pageRevisions.1.guid.rendered'                    => 'http://example.org/?p=8',
     568                'pageRevisions.1._links.parent.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/pages/7',
    543569                'pageRevision.author'                              => 2,
    544                 'pageRevision.id'                                  => 7,
    545                 'pageRevision.parent'                              => 6,
    546                 'pageRevision.slug'                                => '6-revision-v1',
    547                 'pageRevision.guid.rendered'                       => 'http://example.org/?p=7',
    548                 'MediaCollection.0.id'                             => 8,
    549                 'MediaCollection.0.guid.rendered'                  => 'http://example.org/?attachment_id=8',
    550                 'MediaCollection.0.link'                           => 'http://example.org/?attachment_id=8',
     570                'pageRevision.id'                                  => 8,
     571                'pageRevision.parent'                              => 7,
     572                'pageRevision.slug'                                => '7-revision-v1',
     573                'pageRevision.guid.rendered'                       => 'http://example.org/?p=8',
     574                'pageAutosaves.0.author'                           => 2,
     575                'pageAutosaves.0.id'                               => 9,
     576                'pageAutosaves.0.parent'                           => 7,
     577                'pageAutosaves.0.slug'                             => '7-autosave-v1',
     578                'pageAutosaves.0.guid.rendered'                    => 'http://example.org/?p=9',
     579                'pageAutosaves.0._links.parent.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/pages/7',
     580                'pageAutosave.author'                              => 2,
     581                'pageAutosave.id'                                  => 9,
     582                'pageAutosave.parent'                              => 7,
     583                'pageAutosave.slug'                                => '7-autosave-v1',
     584                'pageAutosave.guid.rendered'                       => 'http://example.org/?p=9',
     585                'MediaCollection.0.id'                             => 10,
     586                'MediaCollection.0.guid.rendered'                  => 'http://example.org/?attachment_id=10',
     587                'MediaCollection.0.link'                           => 'http://example.org/?attachment_id=10',
    551588                'MediaCollection.0.description.rendered'           => '<p class="attachment"><!-- <a...><img.../></a> --></p>',
    552589                'MediaCollection.0.source_url'                     => 'http://example.org/wp-content/uploads//tmp/canola.jpg',
    553                 'MediaCollection.0._links.self.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/media/8',
     590                'MediaCollection.0._links.self.0.href'             => 'http://example.org/index.php?rest_route=/wp/v2/media/10',
    554591                'MediaCollection.0._links.collection.0.href'       => 'http://example.org/index.php?rest_route=/wp/v2/media',
    555592                'MediaCollection.0._links.about.0.href'            => 'http://example.org/index.php?rest_route=/wp/v2/types/attachment',
    556                 'MediaCollection.0._links.replies.0.href'          => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=8',
    557                 'MediaModel.id'                                    => 8,
    558                 'MediaModel.guid.rendered'                         => 'http://example.org/?attachment_id=8',
    559                 'MediaModel.link'                                  => 'http://example.org/?attachment_id=8',
     593                'MediaCollection.0._links.replies.0.href'          => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=10',
     594                'MediaModel.id'                                    => 10,
     595                'MediaModel.guid.rendered'                         => 'http://example.org/?attachment_id=10',
     596                'MediaModel.link'                                  => 'http://example.org/?attachment_id=10',
    560597                'MediaModel.description.rendered'                  => '<p class="attachment"><!-- <a...><img.../></a> --></p>',
    561598                'MediaModel.source_url'                            => 'http://example.org/wp-content/uploads//tmp/canola.jpg',
     
    566603                'TypesCollection.attachment._links.collection.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/types',
    567604                'TypesCollection.attachment._links.wp:items.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/media',
     605                'TypesCollection.wp_block._links.collection.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/types',
     606                'TypesCollection.wp_block._links.wp:items.0.href'  => 'http://example.org/index.php?rest_route=/wp/v2/blocks',
    568607                'StatusesCollection.publish._links.archives.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/posts',
    569608                'StatusesCollection.future._links.archives.0.href' => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fposts&status=future',
     
    577616                'TaxonomiesCollection.post_tag._links.wp:items.0.href' => 'http://example.org/index.php?rest_route=/wp/v2/tags',
    578617                'CategoriesCollection.0.link'                      => 'http://example.org/?cat=1',
     618                'CategoriesCollection.0.meta.test_single'          => '',
     619                'CategoriesCollection.0.meta.test_multi'           => [],
     620                'CategoriesCollection.0.meta.test_cat_single'      => '',
     621                'CategoriesCollection.0.meta.test_cat_multi'       => [],
    579622                'CategoriesCollection.0._links.self.0.href'        => 'http://example.org/index.php?rest_route=/wp/v2/categories/1',
    580623                'CategoriesCollection.0._links.collection.0.href'  => 'http://example.org/index.php?rest_route=/wp/v2/categories',
     
    582625                'CategoriesCollection.0._links.wp:post_type.0.href' => 'http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fposts&categories=1',
    583626                'CategoryModel.link'                               => 'http://example.org/?cat=1',
     627                'CategoryModel.meta.test_single'                   => '',
     628                'CategoryModel.meta.test_multi'                    => [],
     629                'CategoryModel.meta.test_cat_single'               => '',
     630                'CategoryModel.meta.test_cat_multi'                => [],
    584631                'TagsCollection.0.id'                              => 2,
    585632                'TagsCollection.0.link'                            => 'http://example.org/?tag=restapi-client-fixture-tag',
     633                'TagsCollection.0.meta.test_single'                => '',
     634                'TagsCollection.0.meta.test_multi'                 => [],
     635                'TagsCollection.0.meta.test_tag_meta'              => '',
    586636                'TagsCollection.0._links.self.0.href'              => 'http://example.org/index.php?rest_route=/wp/v2/tags/2',
    587637                'TagsCollection.0._links.collection.0.href'        => 'http://example.org/index.php?rest_route=/wp/v2/tags',
     
    590640                'TagModel.id'                                      => 2,
    591641                'TagModel.link'                                    => 'http://example.org/?tag=restapi-client-fixture-tag',
     642                'TagModel.meta.test_single'                        => '',
     643                'TagModel.meta.test_multi'                         => [],
     644                'TagModel.meta.test_tag_meta'                      => '',
    592645                'UsersCollection.0.link'                           => 'http://example.org/?author=1',
    593646                'UsersCollection.0.avatar_urls.24'                 => 'http://0.gravatar.com/avatar/96614ec98aa0c0d2ee75796dced6df54?s=24&d=mm&r=g',
  • trunk/tests/qunit/fixtures/wp-api-generated.js

    r44166 r44217  
    49814981            "predecessor-version": [
    49824982                {
    4983                     "id": 5,
    4984                     "href": "http://example.org/index.php?rest_route=/wp/v2/posts/4/revisions/5"
     4983                    "id": 6,
     4984                    "href": "http://example.org/index.php?rest_route=/wp/v2/posts/4/revisions/6"
    49854985                }
    49864986            ],
     
    50585058        "date": "2017-02-14T00:00:00",
    50595059        "date_gmt": "2017-02-14T00:00:00",
     5060        "id": 6,
     5061        "modified": "2017-02-14T00:00:00",
     5062        "modified_gmt": "2017-02-14T00:00:00",
     5063        "parent": 4,
     5064        "slug": "4-autosave-v1",
     5065        "guid": {
     5066            "rendered": "http://example.org/?p=6"
     5067        },
     5068        "title": {
     5069            "rendered": ""
     5070        },
     5071        "content": {
     5072            "rendered": "<p>Autosave post content.</p>\n"
     5073        },
     5074        "excerpt": {
     5075            "rendered": ""
     5076        },
     5077        "_links": {
     5078            "parent": [
     5079                {
     5080                    "href": "http://example.org/index.php?rest_route=/wp/v2/posts/4"
     5081                }
     5082            ]
     5083        }
     5084    },
     5085    {
     5086        "author": 2,
     5087        "date": "2017-02-14T00:00:00",
     5088        "date_gmt": "2017-02-14T00:00:00",
    50605089        "id": 5,
    50615090        "modified": "2017-02-14T00:00:00",
     
    50675096        },
    50685097        "title": {
    5069             "rendered": ""
     5098            "rendered": "REST API Client Fixture: Post"
    50705099        },
    50715100        "content": {
    5072             "rendered": "<p>Autosave post content.</p>\n"
     5101            "rendered": "<p>Updated post content.</p>\n"
    50735102        },
    50745103        "excerpt": {
    5075             "rendered": ""
     5104            "rendered": "<p>REST API Client Fixture: Post</p>\n"
    50765105        },
    50775106        "_links": {
     
    50795108                {
    50805109                    "href": "http://example.org/index.php?rest_route=/wp/v2/posts/4"
    5081                 }
    5082             ]
    5083         }
    5084     },
    5085     {
    5086         "author": 376,
    5087         "date": "2017-02-14T00:00:00",
    5088         "date_gmt": "2017-02-14T00:00:00",
    5089         "id": 36744,
    5090         "modified": "2017-02-14T00:00:00",
    5091         "modified_gmt": "2017-02-14T00:00:00",
    5092         "parent": 36743,
    5093         "slug": "36743-revision-v1",
    5094         "guid": {
    5095             "rendered": "http://example.org/?p=36744"
    5096         },
    5097         "title": {
    5098             "rendered": "REST API Client Fixture: Post"
    5099         },
    5100         "content": {
    5101             "rendered": "<p>Updated post content.</p>\n"
    5102         },
    5103         "excerpt": {
    5104             "rendered": "<p>REST API Client Fixture: Post</p>\n"
    5105         },
    5106         "_links": {
    5107             "parent": [
    5108                 {
    5109                     "href": "http://example.org/index.php?rest_route=/wp/v2/posts/36743"
    51105110                }
    51115111            ]
     
    51395139mockedApiResponse.postAutosaves = [
    51405140    {
    5141         "author": 376,
     5141        "author": 2,
    51425142        "date": "2017-02-14T00:00:00",
    51435143        "date_gmt": "2017-02-14T00:00:00",
    5144         "id": 36745,
     5144        "id": 6,
    51455145        "modified": "2017-02-14T00:00:00",
    51465146        "modified_gmt": "2017-02-14T00:00:00",
    5147         "parent": 36743,
    5148         "slug": "36743-autosave-v1",
     5147        "parent": 4,
     5148        "slug": "4-autosave-v1",
    51495149        "guid": {
    5150             "rendered": "http://example.org/?p=36745"
     5150            "rendered": "http://example.org/?p=6"
    51515151        },
    51525152        "title": {
     
    51625162            "parent": [
    51635163                {
    5164                     "href": "http://example.org/index.php?rest_route=/wp/v2/posts/36743"
     5164                    "href": "http://example.org/index.php?rest_route=/wp/v2/posts/4"
    51655165                }
    51665166            ]
     
    51705170
    51715171mockedApiResponse.autosave = {
    5172     "author": 376,
     5172    "author": 2,
    51735173    "date": "2017-02-14T00:00:00",
    51745174    "date_gmt": "2017-02-14T00:00:00",
    5175     "id": 36745,
     5175    "id": 6,
    51765176    "modified": "2017-02-14T00:00:00",
    51775177    "modified_gmt": "2017-02-14T00:00:00",
    5178     "parent": 36743,
    5179     "slug": "36743-autosave-v1",
     5178    "parent": 4,
     5179    "slug": "4-autosave-v1",
    51805180    "guid": {
    5181         "rendered": "http://example.org/?p=36745"
     5181        "rendered": "http://example.org/?p=6"
    51825182    },
    51835183    "title": {
     
    51945194mockedApiResponse.PagesCollection = [
    51955195    {
    5196         "id": 6,
     5196        "id": 7,
    51975197        "date": "2017-02-14T00:00:00",
    51985198        "date_gmt": "2017-02-14T00:00:00",
    51995199        "guid": {
    5200             "rendered": "http://example.org/?page_id=6"
     5200            "rendered": "http://example.org/?page_id=7"
    52015201        },
    52025202        "modified": "2017-02-14T00:00:00",
     
    52055205        "status": "publish",
    52065206        "type": "page",
    5207         "link": "http://example.org/?page_id=6",
     5207        "link": "http://example.org/?page_id=7",
    52085208        "title": {
    52095209            "rendered": "REST API Client Fixture: Page"
     
    52305230            "self": [
    52315231                {
    5232                     "href": "http://example.org/index.php?rest_route=/wp/v2/pages/6"
     5232                    "href": "http://example.org/index.php?rest_route=/wp/v2/pages/7"
    52335233                }
    52345234            ],
     
    52465246                {
    52475247                    "embeddable": true,
    5248                     "href": "http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=6"
     5248                    "href": "http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=7"
    52495249                }
    52505250            ],
     
    52525252                {
    52535253                    "count": 2,
    5254                     "href": "http://example.org/index.php?rest_route=/wp/v2/pages/6/revisions"
     5254                    "href": "http://example.org/index.php?rest_route=/wp/v2/pages/7/revisions"
    52555255                }
    52565256            ],
    52575257            "predecessor-version": [
    52585258                {
    5259                     "id": 7,
    5260                     "href": "http://example.org/index.php?rest_route=/wp/v2/pages/6/revisions/7"
     5259                    "id": 9,
     5260                    "href": "http://example.org/index.php?rest_route=/wp/v2/pages/7/revisions/9"
    52615261                }
    52625262            ],
    52635263            "wp:attachment": [
    52645264                {
    5265                     "href": "http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=6"
     5265                    "href": "http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=7"
    52665266                }
    52675267            ],
     
    52785278
    52795279mockedApiResponse.PageModel = {
    5280     "id": 6,
     5280    "id": 7,
    52815281    "date": "2017-02-14T00:00:00",
    52825282    "date_gmt": "2017-02-14T00:00:00",
    52835283    "guid": {
    5284         "rendered": "http://example.org/?page_id=6"
     5284        "rendered": "http://example.org/?page_id=7"
    52855285    },
    52865286    "modified": "2017-02-14T00:00:00",
     
    52895289    "status": "publish",
    52905290    "type": "page",
    5291     "link": "http://example.org/?page_id=6",
     5291    "link": "http://example.org/?page_id=7",
    52925292    "title": {
    52935293        "rendered": "REST API Client Fixture: Page"
     
    53185318        "date": "2017-02-14T00:00:00",
    53195319        "date_gmt": "2017-02-14T00:00:00",
    5320         "id": 7,
     5320        "id": 9,
    53215321        "modified": "2017-02-14T00:00:00",
    53225322        "modified_gmt": "2017-02-14T00:00:00",
    5323         "parent": 6,
    5324         "slug": "6-revision-v1",
     5323        "parent": 7,
     5324        "slug": "7-autosave-v1",
    53255325        "guid": {
    5326             "rendered": "http://example.org/?p=7"
     5326            "rendered": "http://example.org/?p=9"
    53275327        },
    53285328        "title": {
     
    53385338            "parent": [
    53395339                {
    5340                     "href": "http://example.org/index.php?rest_route=/wp/v2/pages/6"
     5340                    "href": "http://example.org/index.php?rest_route=/wp/v2/pages/7"
    53415341                }
    53425342            ]
     
    53445344    },
    53455345    {
    5346         "author": 376,
     5346        "author": 2,
    53475347        "date": "2017-02-14T00:00:00",
    53485348        "date_gmt": "2017-02-14T00:00:00",
    5349         "id": 36747,
     5349        "id": 8,
    53505350        "modified": "2017-02-14T00:00:00",
    53515351        "modified_gmt": "2017-02-14T00:00:00",
    5352         "parent": 36746,
    5353         "slug": "36746-revision-v1",
     5352        "parent": 7,
     5353        "slug": "7-revision-v1",
    53545354        "guid": {
    5355             "rendered": "http://example.org/?p=36747"
     5355            "rendered": "http://example.org/?p=8"
    53565356        },
    53575357        "title": {
     
    53675367            "parent": [
    53685368                {
    5369                     "href": "http://example.org/index.php?rest_route=/wp/v2/pages/36746"
     5369                    "href": "http://example.org/index.php?rest_route=/wp/v2/pages/7"
    53705370                }
    53715371            ]
     
    53785378    "date": "2017-02-14T00:00:00",
    53795379    "date_gmt": "2017-02-14T00:00:00",
    5380     "id": 7,
     5380    "id": 8,
    53815381    "modified": "2017-02-14T00:00:00",
    53825382    "modified_gmt": "2017-02-14T00:00:00",
    5383     "parent": 6,
    5384     "slug": "6-revision-v1",
     5383    "parent": 7,
     5384    "slug": "7-revision-v1",
    53855385    "guid": {
    5386         "rendered": "http://example.org/?p=7"
     5386        "rendered": "http://example.org/?p=8"
    53875387    },
    53885388    "title": {
     
    53995399mockedApiResponse.pageAutosaves = [
    54005400    {
    5401         "author": 376,
     5401        "author": 2,
    54025402        "date": "2017-02-14T00:00:00",
    54035403        "date_gmt": "2017-02-14T00:00:00",
    5404         "id": 36748,
     5404        "id": 9,
    54055405        "modified": "2017-02-14T00:00:00",
    54065406        "modified_gmt": "2017-02-14T00:00:00",
    5407         "parent": 36746,
    5408         "slug": "36746-autosave-v1",
     5407        "parent": 7,
     5408        "slug": "7-autosave-v1",
    54095409        "guid": {
    5410             "rendered": "http://example.org/?p=36748"
     5410            "rendered": "http://example.org/?p=9"
    54115411        },
    54125412        "title": {
     
    54225422            "parent": [
    54235423                {
    5424                     "href": "http://example.org/index.php?rest_route=/wp/v2/pages/36746"
     5424                    "href": "http://example.org/index.php?rest_route=/wp/v2/pages/7"
    54255425                }
    54265426            ]
     
    54305430
    54315431mockedApiResponse.pageAutosave = {
    5432     "author": 376,
     5432    "author": 2,
    54335433    "date": "2017-02-14T00:00:00",
    54345434    "date_gmt": "2017-02-14T00:00:00",
    5435     "id": 36748,
     5435    "id": 9,
    54365436    "modified": "2017-02-14T00:00:00",
    54375437    "modified_gmt": "2017-02-14T00:00:00",
    5438     "parent": 36746,
    5439     "slug": "36746-autosave-v1",
     5438    "parent": 7,
     5439    "slug": "7-autosave-v1",
    54405440    "guid": {
    5441         "rendered": "http://example.org/?p=36748"
     5441        "rendered": "http://example.org/?p=9"
    54425442    },
    54435443    "title": {
     
    54545454mockedApiResponse.MediaCollection = [
    54555455    {
    5456         "id": 8,
     5456        "id": 10,
    54575457        "date": "2017-02-14T00:00:00",
    54585458        "date_gmt": "2017-02-14T00:00:00",
    54595459        "guid": {
    5460             "rendered": "http://example.org/?attachment_id=8"
     5460            "rendered": "http://example.org/?attachment_id=10"
    54615461        },
    54625462        "modified": "2017-02-14T00:00:00",
     
    54655465        "status": "inherit",
    54665466        "type": "attachment",
    5467         "link": "http://example.org/?attachment_id=8",
     5467        "link": "http://example.org/?attachment_id=10",
    54685468        "title": {
    54695469            "rendered": "REST API Client Fixture: Attachment"
     
    54915491            "self": [
    54925492                {
    5493                     "href": "http://example.org/index.php?rest_route=/wp/v2/media/8"
     5493                    "href": "http://example.org/index.php?rest_route=/wp/v2/media/10"
    54945494                }
    54955495            ],
     
    55075507                {
    55085508                    "embeddable": true,
    5509                     "href": "http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=8"
     5509                    "href": "http://example.org/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=10"
    55105510                }
    55115511            ]
     
    55155515
    55165516mockedApiResponse.MediaModel = {
    5517     "id": 8,
     5517    "id": 10,
    55185518    "date": "2017-02-14T00:00:00",
    55195519    "date_gmt": "2017-02-14T00:00:00",
    55205520    "guid": {
    5521         "rendered": "http://example.org/?attachment_id=8"
     5521        "rendered": "http://example.org/?attachment_id=10"
    55225522    },
    55235523    "modified": "2017-02-14T00:00:00",
     
    55265526    "status": "inherit",
    55275527    "type": "attachment",
    5528     "link": "http://example.org/?attachment_id=8",
     5528    "link": "http://example.org/?attachment_id=10",
    55295529    "title": {
    55305530        "rendered": "REST API Client Fixture: Attachment"
Note: See TracChangeset for help on using the changeset viewer.