示例#1
0
 /**
  * Test footer.
  */
 public function testBuildSDKFooter()
 {
     $params = $this->getParams();
     $_SERVER['HTTP_USER_AGENT'] = "google";
     $base = new Base($params);
     $access_method = 'getContent';
     $msg = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit,' . ' sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.';
     $base->start_time = "500";
     $bvFooter = new BVFooter($base, $access_method, $msg);
     $res = $bvFooter->buildSDKFooter();
     $this->assertContains('li data-bvseo="ms">bvseo-msg:', $res);
     $this->assertContains('data-bvseo="sdk">bvseo_sdk, p_sdk,', $res);
     $this->assertContains('<li data-bvseo="sp_mt">CLOUD, getContent,', $res);
     $this->assertContains('<li data-bvseo="ct_st">PRODUCT, CATEGORY</li>', $res);
 }
示例#2
0
 /**
  * Return hidden metadata for adding to SEO content.
  */
 private function _buildComment($access_method)
 {
     $bvf = new BVFooter($this, $access_method, $this->msg);
     $footer = $bvf->buildSDKFooter();
     $reveal = $this->_getBVReveal();
     if ($reveal) {
         $footer .= $bvf->buildSDKDebugFooter();
     }
     return $footer;
 }