public function run() { $this->checkQueryResult(r\binary("abcdefg"), "abcdefg"); $this->checkQueryResult(r\binary("abcdefgfoo"), "abcdefgfoo"); $this->checkQueryResult(r\binary("abcdefg"), "abcdefg", array("binaryFormat" => "native")); $this->checkQueryResult(r\binary("abcdefg"), array('$reql_type$' => 'BINARY', 'data' => 'YWJjZGVmZw=='), array("binaryFormat" => "raw")); }
public function testBinaryRaw() { $this->assertEquals(array('$reql_type$' => 'BINARY', 'data' => 'YWJjZGVmZw=='), (array) \r\binary('abcdefg')->run($this->conn, array('binaryFormat' => 'raw'))); }