public function testBuildDimensionWithDefaultScope()
 {
     $name = 'scope';
     $value = \Magento\Framework\App\ScopeInterface::SCOPE_DEFAULT;
     $scopeId = -123456;
     $this->dimension->expects($this->once())->method('getName')->will($this->returnValue($name));
     $this->dimension->expects($this->once())->method('getValue')->will($this->returnValue($value));
     $this->scope->expects($this->once())->method('getId')->will($this->returnValue($scopeId));
     $this->scopeResolver->expects($this->once())->method('getScope')->with($value)->will($this->returnValue($this->scope));
     $query = $this->builder->build($this->dimension);
     $this->assertEquals(sprintf('`%s` = `%s`', \Magento\Framework\Search\Adapter\Mysql\Dimensions::STORE_FIELD_NAME, $scopeId), $query);
 }