コード例 #1
0
ファイル: StoreMapTest.php プロジェクト: php-riak/riak-client
 public function testBuildCommand()
 {
     $counter = new CounterUpdate();
     $builder = StoreMap::builder($this->location, [])->withLocation($this->location)->withContext('context-hash')->removeMap('map_key_remove')->removeSet('set_key_remove')->removeFlag('flag_key_remove')->removeCounter('map_counter_remove')->removeRegister('map_register_remove')->updateMap('map_key', MapUpdate::create())->updateSet('set_key', SetUpdate::create())->updateRegister('map_register', 'foo')->updateCounter('map_counter', 1)->updateFlag('flag_key', true)->withContext('context-hash')->withReturnBody(true)->withDw(1)->withPw(2)->withW(3);
     $counter->withDelta(1);
     $builder->updateCounter('other_counter', $counter);
     $this->assertInstanceOf('Riak\\Client\\Command\\DataType\\StoreMap', $builder->build());
 }