-
Notifications
You must be signed in to change notification settings - Fork 0
/
spider_info_test.go
23 lines (19 loc) · 32.6 KB
/
spider_info_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
package main
import "testing"
var webBody = `<!DOCTYPE html> <html> <head> <title>【剧理力争·剧本体验馆】电话,地址,价格,营业时间(图) - 上海休闲娱乐 - 大众点评网</title> <link rel="icon" type="image/x-icon" href="//www.dpfile.com/app/pc-common/dp_favicon.a4af753914321c8e82e402e2b4be01d7.ico"> <link rel="shortcut icon" type="image/x-icon" href="//www.dpfile.com/app/pc-common/dp_favicon.a4af753914321c8e82e402e2b4be01d7.ico" > <link rel="apple-touch-icon" href="//www.dpfile.com/s/res/app-touch-icon.89213f53ed66e1693e4b6aeedd355349.png"> <link rel="apple-touch-icon" sizes="76x76" href="//www.dpfile.com/s/res/app-touch-icon-76x76.6399ce382f3e0584a6b07599cbeb3bcb.png"> <link rel="apple-touch-icon" sizes="120x120" href="//www.dpfile.com/s/res/app-touch-icon-120x120.067844b8518f076b154dcf793a46a0a5.png"> <link rel="apple-touch-icon" sizes="152x152" href="//www.dpfile.com/s/res/app-touch-icon-152x152.ee6d0c24fc2de0f9a62b6cc9e6720393.png"> <link rel="canonical" href="http://www.dianping.com/shop/ERJA8HGYyWNr9yuh"/> <link rel="alternate" media="only screen and (max-width: 640px)" href="//m.dianping.com/shop/ERJA8HGYyWNr9yuh" > <meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=0, viewport-fit=cover" /> <meta charset="UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=edge"/> <meta name="Keywords" content="剧理力争·剧本体验馆, 剧理力争·剧本体验馆点评, 剧理力争·剧本体验馆团购"/> <meta name="Description" content="为您提供剧理力争·剧本体验馆的人均消费、品牌简介、店铺图片、折扣优惠、用户口碑、娱乐中心会所信息、夜生活指南、KTV茶馆酒吧电玩推荐等信息,剧理力争·剧本体验馆好不好,闵行区剧本杀选择剧理力争·剧本体验馆怎么样?快来看看大家如何点评吧!"/> <meta name="location" content="province=上海;city=上海;"> <meta itemprop="name" content="剧理力争·剧本体验馆"> <meta itemprop="description" content="剧理力争·剧本体验馆"> <meta itemprop="image" content="https://p0.meituan.net/merchantpic/faeda8b38bf3e07ce4f13a81b848a6bc636336.jpg%40300w_225h_1e_1c_1l%7Cwatermark%3D1%26%26r%3D1%26p%3D9%26x%3D2%26y%3D2%26relative%3D1%26o%3D20"> <meta name="robots" content="noarchive"> <meta content="no-transform" http-equiv="Cache-Control"/> <meta content="no-siteapp" http-equiv="Cache-Control"/> <meta http-equiv="mobile-agent" content="format=html5; url=http://m.dianping.com/shop/ERJA8HGYyWNr9yuh"> <script> document.documentElement.className = location.hash ? 'J_H' : ''; var G_rtop = +new Date, _gaq = [ ['_setAccount', 'UA-464026-1'], ['_addOrganic', 'soso', 'w'], ['_addOrganic', 'sogou', 'query'], ['_addOrganic', 'yodao', 'q'], ['_addOrganic', 'bing', 'q'], ['_addOrganic', '360', 'q'], ['_addOrganic', 'gougou', 'search'], ['_setDomainName', ''] , ['_setAllowHash', false] ], dpga = function (key) { _gaq.push(['_trackPageview', key || '']) }, pageTracker = {_trackPageview: dpga}, _hip = [ ['_setPageId', 12], ['_setCityId', ], ['_setShopType', ], ['_setPVInitData', {p_render:+(new Date)-G_rtop}] ]; </script> <link rel="stylesheet" type="text/css" href="//www.dpfile.com/app/pc-common/index.min.a77ed6b2d125089a497ce8978cecc46b.css"> <script type="text/javascript" src="//www.dpfile.com/app/pc-common/index.min.7d164b78c00bdf53d69c6e8fb3259600.js"></script> <script type="text/javascript"> window._DP_HeaderData = { 'cityId': '1', 'cityChName': '上海', 'cityEnName': 'shanghai', 'pageType': 'channel', 'userId': '912301448', 'userName':'兰陵笑笑生', 'channelId': '30', } </script> <link rel="stylesheet" type="text/css" href="//s3plus.meituan.net/v1/mss_0a06a471f9514fc79c981b5466f56b91/svgtextcss/208cd2f184eb242837856d853a29a085.css"> <link rel="stylesheet" href="//www.dpfile.com/app/app-pc-main/static/main-shop.min.639818b259a07012e6bae15460111569.css" type="text/css" /> <meta name="lx:category" content="dianping_nova"> <meta name="lx:appnm" content="dp_pc"> <meta name="lx:cid" content="dp12"> <meta name="lx:autopv" content="off"/> <link rel="dns-prefetch" href="//analytics.meituan.net"/> <link rel="dns-prefetch" href="//wreport.meituan.net"/> <link rel="dns-prefetch" href="//report.meituan.net"/> <script type="text/javascript"> !(function (win, doc, ns) { var cacheFunName = '_MeiTuanALogObject'; win[cacheFunName] = ns; if (!win[ns]) { var _LX = function () { _LX.q.push(arguments); return _LX; }; _LX.q = _LX.q || []; _LX.l = +new Date(); win[ns] = _LX; } })(window, document, 'LXAnalytics'); ;(function () { var environment = { cityid: '1' }; var valLab = { cat0_id: '30', cat1_id: '50035', poi_id: 'ERJA8HGYyWNr9yuh', shopuuid: 'ERJA8HGYyWNr9yuh' }; var cid = 'dp12'; var _LXAnalytics = window.LXAnalytics; LXAnalytics = function LXAnalytics() { var METHOD = {PV: 'pageView',MC: 'moduleClick',MV: 'moduleView'}; try { var checkUuid = function checkUuid(valLab) { var _valLab = valLab; var custom = _valLab&&_valLab.custom; var poi_id = _valLab && (_valLab.shopid || _valLab.shopId || _valLab.poi_id); if (poi_id) _valLab = Object.assign({}, valLab, {shopuuid: poi_id}); if (custom) _valLab.custom = checkUuid(custom); return _valLab || null; }; var args = Array.prototype.slice.call(arguments); var method = args[0]; var valLab = args[1]; var environment = args[2]; var cid = args[3]; if (method === METHOD.PV) { var _valLab = checkUuid(valLab); var _environment = environment || null; _LXAnalytics(method, _valLab, _environment, cid); } else if (method === METHOD.MC || method === METHOD.MV) { var _valBid = valLab; var _valLab2 = environment?checkUuid(environment):null; var options = cid || {}; _LXAnalytics(method, _valBid, _valLab2, options); } else { _LXAnalytics.apply(null, args); } } catch (e) { console.log('LXAnalytics hooks error', e); } }; Object.keys(_LXAnalytics).forEach(function (key) { LXAnalytics[key] = _LXAnalytics[key]; }); LXAnalytics('pageView', valLab, environment, cid); })(); </script> <script src="//analytics.meituan.net/analytics.js" type="text/javascript" charset="utf-8"></script> <script type="text/javascript">(function(){var c="www.dianping.com"===window.location.host||"w.51ping.com"===window.location.host,f="m.dianping.com"===window.location.host||"m.51ping.com"===window.location.host,a="iPhone;Android;Windows Phone;SymbianOS;iPad;iPod".split(";"),g=window.location.pathname,b=window.location.search,h=window.screen.width,e=-1!==location.href.indexOf("51ping")?"test":"prod",k="test"===e?"//w.51ping.com":"//www.dianping.com";e="test"===e?"//m.51ping.com":"//m.dianping.com";var d=!1;if(c){for(c=0;c<a.length;c++)if(d= a[c],-1!=navigator.userAgent.indexOf(d)&&640>=h){d=!0;break}else d=!1;d&&(a="source=pc_jump",b=b?b+"&"+a:b+"?"+a,a=setTimeout,location.href=e+(g+b),a(void 0,500))}f&&640<h&&(a="source=m_jump",f=setTimeout,location.href=k+(g+(b?b+"&"+a:b+"?"+a)),f(void 0,500))})();</script> <script> var rohrdata = ""; var Rohr_Opt = new Object; Rohr_Opt.Flag = 100041; Rohr_Opt.LogVal = "rohrdata"; </script> <script src="//www.dpfile.com/app/rohr/rohr.min.js"></script> <script type="text/javascript"> "use strict";!function(){var a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"_Owl_",i=window,t={page:!0,resource:!0,js:!0};i[a]||(i[a]={isRunning:!1,isReady:!1,preTasks:[],config:t,dataSet:[],use:function(a,t){this.isReady&&i.Owl&&i.Owl[a](t),this.preTasks.push({api:a,data:[t]})},add:function(a){this.dataSet.push(a)},run:function(a){var t=this;if(!this.isRunning){this.isRunning=!0;var e=a||this.config;if(!1!==e.js){var n=i.onerror;i.onerror=function(){this.isReady||this.add({type:"jsError",data:arguments}),n&&n.apply(i,arguments)}.bind(this)}var r=i.addEventListener||i.attachEvent;!1!==e.page&&r("load",function(){if(!t.isReady){var a=i.performance&&i.performance.timing;t.add({type:"pageTime",data:[a]})}}),!1!==e.resource&&(r("error",function(a){t.isReady||t.add({type:"resError",data:[a]})},!0),r("load",function(a){t.isReady||t.add({type:"resTime",data:[a]})}))}}})}(); _Owl_.run({ page: true, js: true, resource: true }) </script> </head> <body id="top"> <div class="header-container"> <div id="top-nav" class="top-nav"> <div class="top-nav-container clearfix"> <div class="group J-city-select"> <!--城市选择--> <a target="_blank" class="city J-city"><span class="map-icon"></span><span class="J-current-city">上海</span><span class="J-city-change">[更换]</span></a> <div class="city-list J-city-list Hide"> <div class="group clearfix"> <h3 class="title">国内城市</h3> <div> <a href="//www.dianping.com/shanghai" class="city-item">上海</a> <a href="//www.dianping.com/beijing" class="city-item">北京</a> <a href="//www.dianping.com/guangzhou" class="city-item">广州</a> <a href="//www.dianping.com/shenzhen" class="city-item">深圳</a> <a href="//www.dianping.com/tianjin" class="city-item">天津</a> <a href="//www.dianping.com/hangzhou" class="city-item">杭州</a> <a href="//www.dianping.com/nanjing" class="city-item">南京</a> <a href="//www.dianping.com/suzhou" class="city-item">苏州</a> <a href="//www.dianping.com/chengdu" class="city-item">成都</a> <a href="//www.dianping.com/wuhan" class="city-item">武汉</a> <a href="//www.dianping.com/chongqing" class="city-item">重庆</a> <a href="//www.dianping.com/xian" class="city-item">西安</a> </div> </div> <div class="group clearfix"> <h3 class="title">国外城市</h3> <div> <a href="//www.dianping.com/tokyo" class="city-item">东京</a> <a href="//www.dianping.com/seoul" class="city-item">首尔</a> <a href="//www.dianping.com/bangkok" class="city-item">曼谷</a> <a href="//www.dianping.com/paris" class="city-item">巴黎</a> </div> </div> <a class="all" href="//www.dianping.com/citylist">更多城市 ></a> </div> </div> <div class="group quick-menu "> <span class="login-container J-login-container"> <a rel="nofollow" class="item " href="http://account.dianping.com/login" data-click-name="login">你好,请登录</a> <a rel="nofollow" class="item login" href="https://account.dianping.com/reg" data-click-name="reg">免费注册</a> </span> <span class="seprate">|</span> <a rel="nofollow" href="https://www.dianping.com/member/myinfo" class="item J-my-center-trigger">个人中心<i class="icon i-arrow"></i></a> <span class="seprate">|</span> <a target="_blank" class="item J-shop-serve-trigger">商户服务<i class="icon i-arrow"></i></a> <span class="seprate">|</span> <a target="_blank" class="item J-help-trigger">帮助中心<i class="icon i-arrow"></i></a> </div> <div class="panel my-center J-my-center-target Hide"> </div> <div class="panel my-center J-shop-serve-target Hide"> <a rel="nofollow" target="_blank" href="https://e.dianping.com/" data-click-name="shop-center">商户中心</a> <a rel="nofollow" target="_blank" href="https://e.dianping.com/claimcpc/page/index?source=dp" data-click-name="shop-coop">商户合作</a> <a rel="nofollow" target="_blank" href="https://daili.meituan.com/?comeFrom=dpwebMenu" data-click-name="daili">招募餐饮代理</a> <a rel="nofollow" target="_blank" href="https://daili.meituan.com/dz-zhaoshang" data-click-name="apollo">招募非餐饮代理</a> <a rel="nofollow" target="_blank" href="http://b.meituan.com/canyin/PC">餐饮商户中心</a> </div> <div class="panel my-center J-help-target Hide"> <a rel="nofollow" target="_blank" href="https://rules-center.meituan.com?from=dianpingPC" data-click-name="useragreement">平台规则</a> <a rel="nofollow" target="_blank" href="http://kf.dianping.com" data-click-name="kf">联系客服</a> </div> </div> </div> <div id="logo-input" class="logo-input life-conf"> <div class="logo-input-container clearfix"> <a title="大众点评网" href="/" class="logo logo-life"></a> <div class="search-box"> <div class="search-bar "> <span class="search-container clearfix"> <i class="i-search"></i> <span> <input id="J-search-input" class="J-search-input" x-webkit-speech="" x-webkit-grammar="builtin:translate" data-s-pattern="https://www.dianping.com/search/keyword/{0}/{1}_" data-s-epattern="https://www.dianping.com/shanghai/{0}" data-s-cateid="0" data-s-cityid="1" type="text" placeholder="搜索商户名、地址、菜名、外卖等" autocomplete="off" /> </span> <span class="search-bnt-panel"> <a target="_blank" class="search-btn search-channel-bnt J-search-btn" id="J-channel-bnt" data-s-chanid="30">频道搜索</a> <a target="_blank" class="search-btn search-all-bnt J-search-btn platform-btn" id="J-all-btn" data-s-chanid="0">全站搜索</a> </span> </span> <p class="hot-search J-hot-search"> </p> </div> </div> </div> </div> <div id="cate-channel" class="cate-container channel-cate-container life-conf"> <div class="nav-header"> <div class="navbar"> <span class="cate-item all-cate J-all-cate">全部休闲娱乐分类 <i class="primary-more"></i> </span> </div> </div> <div class="gradient"></div> <div id="cate-index" class="cate-index"> <div class="navwrap"> <div id="nav" > <div class="cate-nav J-cate-nav Hidden"> <ul class="first-cate J-primary-menu"> <li class="first-item"> <div class="primary-container"> <span class="span-container"> <a target="_blank" class="index-title">足疗洗浴</a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g141" data-category="life.zuliao" data-click-title="second" data-click-name="g141"><span>足疗按摩</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g140" data-category="life.zuliao" data-click-title="second" data-click-name="g140"><span>洗浴/汗蒸</span></a> </span> </div> <div class="sec-cate Hide" data-category="cate.life.zuliao" > <div class="groups"> <div class="group"> <div class="sec-title"> <span class="channel-title" href="">足疗洗浴</span> </div> <div class="sec-items"> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g141" data-category="life.zuliao" data-click-name="g141">足疗按摩</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g140" data-category="life.zuliao" data-click-name="g140">洗浴/汗蒸</a> </div> </div> </div> </div> </li> <li class="first-item"> <div class="primary-container"> <span class="span-container"> <a target="_blank" class="index-title">玩乐</a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch15/g135" data-category="life.wanle" data-click-title="second" data-click-name="g135"><span>KTV</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g133" data-category="life.wanle" data-click-title="second" data-click-name="g133"><span>酒吧</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g2754" data-category="life.wanle" data-click-title="second" data-click-name="g2754"><span>密室逃脱</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g20040" data-category="life.wanle" data-click-title="second" data-click-name="g20040"><span>轰趴馆</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g20041" data-category="life.wanle" data-click-title="second" data-click-name="g20041"><span>私人影院</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g137" data-category="life.wanle" data-click-title="second" data-click-name="g137"><span>游乐游艺</span></a> </span> </div> <div class="sec-cate Hide" data-category="cate.life.wanle" > <div class="groups"> <div class="group"> <div class="sec-title"> <span class="channel-title" href="">玩乐High</span> </div> <div class="sec-items"> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch15/g135" data-category="life.wanle" data-click-name="g135">KTV</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g133" data-category="life.wanle" data-click-name="g133">酒吧</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g2754" data-category="life.wanle" data-click-name="g2754">密室逃脱</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g20040" data-category="life.wanle" data-click-name="g20040">轰趴馆</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g20041" data-category="life.wanle" data-click-name="g20041">私人影院</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g137" data-category="life.wanle" data-click-name="g137">游乐游艺</a> </div> </div> </div> </div> </li> <li class="first-item"> <div class="primary-container"> <span class="span-container"> <a target="_blank" class="index-title">休闲活动</a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g134" data-category="life.xiuxianhd" data-click-title="second" data-click-name="g134"><span>茶馆</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g20042" data-category="life.xiuxianhd" data-click-title="second" data-click-name="g20042"><span>网吧网咖</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g144" data-category="life.xiuxianhd" data-click-title="second" data-click-name="g144"><span>DIY手工坊</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g20038" data-category="life.xiuxianhd" data-click-title="second" data-click-name="g20038"><span>采摘/农家乐</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g142" data-category="life.xiuxianhd" data-click-title="second" data-click-name="g142"><span>文化艺术</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g6694" data-category="life.xiuxianhd" data-click-title="second" data-click-name="g6694"><span>桌游</span></a> </span> </div> <div class="sec-cate Hide" data-category="cate.life.xiuxianhd" > <div class="groups"> <div class="group"> <div class="sec-title"> <span class="channel-title" href="">休闲活动</span> </div> <div class="sec-items"> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g134" data-category="life.xiuxianhd" data-click-name="g134">茶馆</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g20042" data-category="life.xiuxianhd" data-click-name="g20042">网吧网咖</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g144" data-category="life.xiuxianhd" data-click-name="g144">DIY手工坊</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g20038" data-category="life.xiuxianhd" data-click-name="g20038">采摘/农家乐</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g142" data-category="life.xiuxianhd" data-click-name="g142">文化艺术</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g6694" data-category="life.xiuxianhd" data-click-name="g6694">桌游</a> </div> </div> </div> </div> </li> <li class="first-item"> <div class="primary-container"> <span class="span-container"> <a target="_blank" class="index-title">其他休闲娱乐</a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g33857" data-category="life.qitaxxyl" data-click-title="second" data-click-name="g33857"><span>VR</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g34089" data-category="life.qitaxxyl" data-click-title="second" data-click-name="g34089"><span>团建拓展</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g32732" data-category="life.qitaxxyl" data-click-title="second" data-click-name="g32732"><span>棋牌室</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g156" data-category="life.qitaxxyl" data-click-title="second" data-click-name="g156"><span>桌球馆</span></a> <a target="_blank" class="index-item" href="http://www.dianping.com/shanghai/ch30/g156" data-category="life.qitaxxyl" data-click-title="second" data-click-name="g156"><span>更多</span></a> </span> </div> <div class="sec-cate Hide" data-category="cate.life.qitaxxyl" > <div class="groups"> <div class="group"> <div class="sec-title"> <span class="channel-title" href="">其他休闲娱乐</span> </div> <div class="sec-items"> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g33857" data-category="life.qitaxxyl" data-click-name="g33857">VR</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g20039" data-category="life.qitaxxyl" data-click-name="g20039">真人CS</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g32732" data-category="life.qitaxxyl" data-click-name="g32732">棋牌室</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g156" data-category="life.qitaxxyl" data-click-name="g156">桌球馆</a> <a target="_blank" class="second-item" href="http://www.dianping.com/shanghai/ch30/g156" data-category="life.qitaxxyl" data-click-name="g156">更多休闲娱乐</a> </div> </div> </div> </div> </li> </ul> </div> </div> </div> </div> </div> </div> <div id="body" class="body shop-body"> <div class="body-content clearfix"> <div class="breadcrumb"> <a href="//www.dianping.com/shanghai/ch30" itemprop="url"> 上海休闲娱乐 </a> > <a href="//www.dianping.com/shanghai/ch30/g50035" itemprop="url"> 剧本杀 </a> > <a href="//www.dianping.com/shanghai/ch30/r12" itemprop="url"> 闵行区 </a> > <a href="//www.dianping.com/shanghai/ch30/r848" itemprop="url"> 七宝 </a> > <span>剧理力争·剧本体验馆</span> </div> <div class="main"> <div id="basic-info" class="basic-info default nug_shop_ab_pv-a"> <s class="cover J_cover"></s> <h1 class="shop-name"> 剧<e class="address">理</e><e class="address">力</e>争·剧<e class="address">庄</e><e class="address">体</e>验<e class="address">馆</e> <a class="qr-contrainer" href="//www.dianping.com/events/m/index.htm" data-click-name="手机买单" rel="nofollow" onclick="_hip.push(['mv', { module: 'shopinfo_hoverQR', action: 'click'}])"> <div class="phone-qr"> <span class="arrow"></span> 手机扫码 优惠买单 </div> <div class="qr-code"> <div id="qrcode" class="code"> <div class="code-img"></div> </div> </div> </a> </h1> <div class="brief-info"> <span title="40" class="mid-rank-stars mid-str40"></span> <span id="reviewCount" class="item"> <d class="num">2</d><d class="num">4</d> 条评价 </span> <div class="star-from-desc J-star-from-desc Hide">星级来自业内综合评估<i class="icon"></i></div> <span id="avgPriceTitle" class="item">人均:-</span> <span id="comment_score"> <span class="item">剧本: <d class="num">7</d>.<d class="num">7</d> </span> <span class="item">主持人: <d class="num">7</d>.<d class="num">9</d> </span> <span class="item">环境: <d class="num">7</d>.<d class="num">8</d> </span> </span> </div> <div class="expand-info address" itemprop="street-address">
<span class="info-name">地址:</span>
<div id="J_map-show" class="map_address" >
<span class="item" itemprop="street-address" id="address"> 漕<e class="address">宝</e><e class="address">路</e><d class="num">3</d><d class="num">4</d><d class="num">8</d><d class="num">9</d><e class="address">计</e><e class="address">汇</e><e class="address">宝</e><e class="address">处</e><e class="address">非</e><e class="address">中</e><e class="address">心</e><e class="address">汇</e><e class="address">恒</e><e class="address">商</e><e class="address">室</e><e class="address">起</e><e class="address">厦</e>A<e class="address">座</e><d class="num">7</d><e class="address">楼</e>
</span>
<div class="addressIcon"></div> </div> </div> <p class="expand-info tel">
<span class="info-name">电话:</span> 1<d class="num">9</d><d class="num">8</d><d class="num">2</d>1<d class="num">9</d>1<d class="num">3</d>1<d class="num">3</d><d class="num">3</d> 1<d class="num">3</d><d class="num">5</d><d class="num">6</d><d class="num">4</d><d class="num">8</d><d class="num">4</d><d class="num">5</d><d class="num">0</d><d class="num">7</d><d class="num">2</d> </p>
<div class="promosearch-wrapper"></div> <a class="J-unfold unfold" data-click-name="更多信息">更多信息<i class="icon"></i></a> <div class="other J-other Hide"> <p class="info info-indent">
<span class="info-name">营业时间:</span> <span class="item"> <svgmtsi class="shopdesc">周</svgmtsi><svgmtsi class="shopdesc">一</svgmtsi>至<svgmtsi class="shopdesc">周</svgmtsi><svgmtsi class="shopdesc">轩</svgmtsi> 1<svgmtsi class="hours">2</svgmtsi>:<svgmtsi class="hours">0</svgmtsi><svgmtsi class="hours">0</svgmtsi>-<svgmtsi class="hours">2</svgmtsi><svgmtsi class="hours">4</svgmtsi>:<svgmtsi class="hours">0</svgmtsi><svgmtsi class="hours">0</svgmtsi> </span> <a class="item-gray" href="//www.dianping.com/shop/ERJA8HGYyWNr9yuh/edit" target="_blank" rel="nofollow" data-click-name="修改/添加营业时间"> 修改 </a> </p> <div id="license-wrappper"></div> <p class="info J-feature Hide"></p> <p id="park" class="info info-indent J-park Hide"></p> <div id="tips-wrapper"></div> </div> <div class="action"> <a class="write left-action" href="//www.dianping.com/shop/ERJA8HGYyWNr9yuh/review" target="_blank" rel="nofollow" data-click-name="写评价"> <i class="icon"></i><span id="dpReviewBtn" >写评价</span></a> <div id="booking-wrapper" data-click-name="订座"></div> <span class="right-action"> <a class="share J-weixin" rel="nofollow" title="微信分享" data-click-name="微信分享"><i class="icon"></i></a> <a id="fav" class="favorite J-favorite" rel="nofollow" title="收藏" data-click-name="收藏"><i class="icon"></i></a> <a class="report" title="报错" href="/shop/ERJA8HGYyWNr9yuh/edit" rel="nofollow" target="_blank" data-click-name="报错"><i class="icon"></i></a> <a class="action-more J-action-more" ><i class="icon"></i></a> <div class="shop-action-more-list J-action-more-list Hide"> <a href="/upload/shop/ERJA8HGYyWNr9yuh" rel="nofollow" target="_blank" data-click-name="添加图片">添加图片</a> <i class="arrow"></i> </div> </span> </div> <div id="tuiguangAd-wrapper"> </div> </div> <div id="shop-branchs" class="shop-branchs Hide" rel="nofollow"> <a class="add-shop" rel="nofollow"><i class="icon"></i></a> <a class="more-shop" target="_blank" href="//www.dianping.com/brands/bERJA8HGYyWNr9yuh" data-click-name="查看全部分店">查看全部0家分店</a> </div> <div id="shop-score" class="shop-score Hide"> </div> <div id="shop-hours" class="shop-hours Hide"> <h3 class="title">修改时间</h3> <textarea></textarea> <p class="action"> <a class="J-cancel">取消</a> <a class="btn J-confirm">保存修改</a> </p> </div> <div id="stop-info" class="stop-info J-park-more Hide"> </div> <div id="promoinfo-wrapper"></div> <div id="joybooking-wrapper"></div> <div id="shoptabs-wrapper"></div> <div id="myreview-wrapper"></div> <div id="friends-comment" class="mod comment friends-comment"> <div id="friends-comment-head"></div> <ul class="comment-list J-list" id="friend-reviewlist-wrapper"></ul> <div id="friends-comment-tail"></div> <div id="qqfriends-comment-head"></div> <div class="qq-friends" id="qq-friends-wrapper"> <h3 class="names" id="qq-friends-names"></h3> <div class="avatars clearfix" id="qq-friends-avatars"></div> </div> </div> <div id="comment" class="mod comment" data-render="1"> <h2 class="mod-title J-tab" id="defaultcomment-wrapper"></h2> <div id="summaryfilter-wrapper"></div> <div id="attributefilter-wrapper"></div> <ul class="comment-list J-list" id="reviewlist-wrapper"></ul> <div id="morelink-wrapper"></div> </div> <div id="addreview-wrapper"></div> <div id="relatedeal-wrapper"></div> <div class="mod shop-owner"> <h2 class="mod-title"> <a class="item current">App专享优惠</a> </h2> </div> </div> <div id="aside" class="aside"> <div id="aside-photos" class="photos-container"></div> <div id="aside-bottom"></div> </div> </div> </div> <div class="footer-container"> <div id="channel-footer" class="channel-footer"> <p class="links"> <a target="_blank" href="https://about.meituan.com" rel="nofollow">关于我们</a>| <a target="_blank" href="https://dpapp-appeal.meituan.com/#/shopCreditRegulationPC" rel="nofollow">商户诚信公约</a>| <a target="_blank" href="https://rules-center.meituan.com/?from=dianpingPC" rel="nofollow">规则中心</a>| <a target="_blank" href="https://about.meituan.com/news/report" rel="nofollow">媒体报道</a>| <a target="_blank" href="https://e.dianping.com/claimcpc/page/index?source=dp" rel="nofollow">商户入驻</a>| <a target="_blank" href="//www.dianping.com/business/" rel="nofollow">推广服务</a>| <a target="_blank" href="https://join.dianping.com/" rel="nofollow">人才招聘</a>| <span class="links-container"> <a class="ext-links" href="javascript:void(0);" rel="nofollow">最新咨询</a>| </span> <a target="_blank" rel="nofollow" href="https://about.meituan.com/contact?source=dp" rel="nofollow">联系我们</a>| <a target="_blank" href="http://www.dianping.com/app/download">应用下载</a> </p> <div class="ext-container Hide"> <div class="link-items Hide"> <a target="_blank" href="//www.dianping.com/discovery/"><span>资讯评论精选</span></a> </div> </div> <p class="rights"> <span style="margin-right:10px;">©2003-2021 dianping.com, All Rights Reserved.</span> <span>本站发布的所有内容,未经许可,不得转载,详见 <a rel="nofollow" class="G" href="https://rules-center.meituan.com/rules-detail/69">《知识产权声明》</a>。 </span> </p> </div> <script> var _hmt = _hmt || []; (function() { var hm = document.createElement("script"); hm.src = "https://hm.baidu.com/hm.js?602b80cf8079ae6591966cc70a3940e7"; var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(hm, s); })(); </script> <script> (function(){var h=navigator.userAgent;var i=navigator.appName;var b=i.indexOf("Microsoft Internet Explorer")!==-1;if(!b){return false}var d=/MSIE (\d+).0/g;var e=d.exec(h);if(e&&e.length&&e[1]<9){var j='<div class="browser-overlay"></div><div id="browser-ie-con" class="browser-ie-con"><div id="browser-close" class="close">×</div><div class="browser-download chrome"><a href="//www.google.cn/chrome/browser/desktop/index.html?utm_dp" target="_black" title="chrome"></a></div><div class="browser-download firefox"><a href="//www.firefox.com.cn/download/?utm_dp" target="_black" title="firefox"></a></div></div>';var f=document.createElement("div");f.id="browser-update-ie";f.className="browser-update-ie";f.innerHTML=j;document.body.appendChild(f);var a=document.documentElement.clientWidth||document.body.clientWidth;var c=document.getElementById("browser-ie-con").offsetWidth;var g=(a-c)/2;document.getElementById("browser-ie-con").style.left=g+"px";document.getElementById("browser-close").attachEvent("onclick",function(){document.getElementById("browser-update-ie").style.display="none"},false)}})(); </script> </div> <script> window.shop_config={ userId: 912301448, shopId: "ERJA8HGYyWNr9yuh", shopCityId: 1, shopName: '剧<e class="address">理</e><e class="address">力</e>争·剧<e class="address">庄</e><e class="address">体</e>验<e class="address">馆</e>', address: '漕<e class="address">宝</e><e class="address">路</e><d class="num">3</d><d class="num">4</d><d class="num">8</d><d class="num">9</d><e class="address">计</e><e class="address">汇</e><e class="address">宝</e><e class="address">处</e><e class="address">非</e><e class="address">中</e><e class="address">心</e><e class="address">汇</e><e class="address">恒</e><e class="address">商</e><e class="address">室</e><e class="address">起</e><e class="address">厦</e>A<e class="address">座</e><d class="num">7</d><e class="address">楼</e>', publicTransit: '', cityId: "1", cityCnName: "上海", cityName: "上海", cityEnName: "shanghai", isOverseasCity: 0, power:5, shopPower:40, voteTotal:0, district:0, shopType:30, mainRegionId:848, categoryURLName:"life", shopGroupId: "ERJA8HGYyWNr9yuh", loadUserDomain:"//www.dianping.com", map:{ power:5, manaScore:"0" }, mainCategoryId:50035, defaultPic:"https://p0.meituan.net/merchantpic/faeda8b38bf3e07ce4f13a81b848a6bc636336.jpg%40300w_225h_1e_1c_1l%7Cwatermark%3D1%26%26r%3D1%26p%3D9%26x%3D2%26y%3D2%26relative%3D1%26o%3D20", textCssVersion:"zpiflf82yr", shopEvtId:"ERJA8HGYyWNr9yuh" } </script> <script src="//www.dpfile.com/app/app-pc-main/static/common.min.afe724462da9ff529198b050b4795387.js" type="text/javascript"></script><script src="//www.dpfile.com/app/app-pc-main/static/main-shop.min.7d66aacc6ff44203235b4c16777b120d.js" type="text/javascript"></script> <script crossorigin="anonymous" src="//www.dpfile.com/app/owl/static/owl.min.0a395aa3ae39405f6a594c29b26d00b7.js"></script> <script> Owl.start({ project: 'app-pc-main-shop', pageUrl: 'main-shop' }) </script> </body> </html>`
func TestWebBody_SpiderAddress(t *testing.T) {
soup := NewWebBody(webBody)
soup.SpiderAddress()
}
func TestWebBody_SpiderInfo(t *testing.T) {
soup := NewWebBody(webBody)
soup.SpiderInfo()
}