@@ -61,20 +61,22 @@ public static function generate_shared_fixtures( $factory ) {
6161 'post_date ' => '2008-06-02 00:00:00 ' ,
6262 )
6363 );
64- self :: $ post_ids [] = $ post_id = $ factory ->post ->create (
64+ $ post_id = $ factory ->post ->create (
6565 array (
6666 'post_title ' => 'post-format-test-gallery ' ,
6767 'post_date ' => '2008-06-10 00:00:00 ' ,
6868 )
6969 );
70- self ::$ post_ids [] = $ factory ->post ->create (
70+ self ::$ post_ids [] = $ post_id ;
71+ $ factory ->post ->create (
7172 array (
7273 'import_id ' => 611 ,
7374 'post_type ' => 'attachment ' ,
7475 'post_title ' => 'canola2 ' ,
7576 'post_parent ' => $ post_id ,
7677 )
7778 );
79+ self ::$ post_ids [] = $ post_id ;
7880
7981 self ::$ post_ids [] = $ factory ->post ->create (
8082 array (
@@ -84,13 +86,14 @@ public static function generate_shared_fixtures( $factory ) {
8486 )
8587 );
8688
87- self :: $ post_ids [] = $ post_id = $ factory ->post ->create (
89+ $ post_id = $ factory ->post ->create (
8890 array (
8991 'import_id ' => 149 ,
9092 'post_title ' => 'comment-test ' ,
9193 'post_date ' => '2008-03-03 00:00:00 ' ,
9294 )
9395 );
96+ self ::$ post_ids [] = $ post_id ;
9497 self ::$ comment_ids = $ factory ->comment ->create_post_comments ( $ post_id , 15 );
9598
9699 self ::$ post_ids [] = $ factory ->post ->create ( array ( 'post_date ' => '2008-09-05 00:00:00 ' ) );
@@ -111,12 +114,13 @@ public static function generate_shared_fixtures( $factory ) {
111114 'post_title ' => 'about ' ,
112115 )
113116 );
114- self :: $ post_ids [] = $ post_id = $ factory ->post ->create (
117+ $ post_id = $ factory ->post ->create (
115118 array (
116119 'post_type ' => 'page ' ,
117120 'post_title ' => 'parent-page ' ,
118121 )
119122 );
123+ self ::$ post_ids [] = $ post_id ;
120124 self ::$ post_ids [] = $ factory ->post ->create (
121125 array (
122126 'import_id ' => 144 ,
@@ -126,40 +130,45 @@ public static function generate_shared_fixtures( $factory ) {
126130 )
127131 );
128132
129- self :: $ post_ids [] = $ parent_id = $ factory ->post ->create (
133+ $ parent_id = $ factory ->post ->create (
130134 array (
131135 'post_name ' => 'parent ' ,
132136 'post_type ' => 'page ' ,
133137 )
134138 );
135- self ::$ post_ids [] = $ child_id_1 = $ factory ->post ->create (
139+ self ::$ post_ids [] = $ parent_id ;
140+ $ child_id_1 = $ factory ->post ->create (
136141 array (
137142 'post_name ' => 'child1 ' ,
138143 'post_type ' => 'page ' ,
139144 'post_parent ' => $ parent_id ,
140145 )
141146 );
142- self ::$ post_ids [] = $ child_id_2 = $ factory ->post ->create (
147+ self ::$ post_ids [] = $ child_id_1 ;
148+ $ child_id_2 = $ factory ->post ->create (
143149 array (
144150 'post_name ' => 'child2 ' ,
145151 'post_type ' => 'page ' ,
146152 'post_parent ' => $ parent_id ,
147153 )
148154 );
149- self ::$ post_ids [] = $ grandchild_id_1 = $ factory ->post ->create (
155+ self ::$ post_ids [] = $ child_id_2 ;
156+ $ grandchild_id_1 = $ factory ->post ->create (
150157 array (
151158 'post_name ' => 'grandchild ' ,
152159 'post_type ' => 'page ' ,
153160 'post_parent ' => $ child_id_1 ,
154161 )
155162 );
156- self ::$ post_ids [] = $ grandchild_id_2 = $ factory ->post ->create (
163+ self ::$ post_ids [] = $ grandchild_id_1 ;
164+ $ grandchild_id_2 = $ factory ->post ->create (
157165 array (
158166 'post_name ' => 'grandchild ' ,
159167 'post_type ' => 'page ' ,
160168 'post_parent ' => $ child_id_2 ,
161169 )
162170 );
171+ self ::$ post_ids [] = $ grandchild_id_2 ;
163172
164173 $ cat1 = $ factory ->term ->create (
165174 array (
0 commit comments