public function testCreate() { $regex = new \MongoRegex('/abc/i'); $this->assertAttributeSame('abc', 'regex', $regex); $this->assertAttributeSame('i', 'flags', $regex); $this->assertSame('/abc/i', (string) $regex); return $regex; }