Index: tests/phpunit/tests/query/setupPostdata.php
===================================================================
--- tests/phpunit/tests/query/setupPostdata.php	(revision 31834)
+++ tests/phpunit/tests/query/setupPostdata.php	(working copy)
@@ -46,6 +46,22 @@
 		$this->assertSame( $p->ID, $GLOBALS['id'] );
 	}
 
+	public function test_setup_by_id() {
+		$p = $this->factory->post->create_and_get();
+		setup_postdata( $p->ID );
+
+		$this->assertNotEmpty( $p->ID );
+		$this->assertSame( $p->ID, $GLOBALS['id'] );
+	}
+
+	public function test_fake_post() {
+
+		$fake = new stdClass;
+		$fake->ID = 100;
+
+		$this->assertNotSame( $fake->ID, $GLOBALS['id'] );
+	}
+
 	public function test_authordata() {
 		$u = $this->factory->user->create_and_get();
 		$p = $this->factory->post->create_and_get( array(
