const fs=require('fs'); const h=fs.readFileSync('/data/workspace/index.html','utf8'); const required=[ 'Image260916115601596220.png', // banner 'Image26091611510265267f.png', // about 'Image260916104633007e22.jpg', 'Image260916104631289d36.jpg', 'Image260916104632726db6.jpg', 'Image260916104631382c8b.jpg', 'Image2609161046322732ee.jpg', 'Image260916104631257ad9.jpg', 'Image2609161046322893b3.jpg', 'Image2609161046318043d2.jpg', ]; const forbidden=['form','input','textarea','select']; const checks=[ ['banner图已引用', h.includes('Image260916115601596220.png')], ['about图已引用', h.includes('Image26091611510265267f.png')], ['8张产品图全部引用', required.slice(2).every(u=>h.includes(u))], ['无表单form', !/
.*<\/title>/.test(h)], ['含keywords', h.includes('name="keywords"')], ['含description', h.includes('name="description"')], ['title含克孜勒苏', h.includes('克孜勒苏')], ['title含更新时间格式', /更新时间:2026-09-16 22:27:17/.test(h)], ['banner比例1920x1000(aspect-ratio)', h.includes('1920/1000')], ['自适应viewport', h.includes('width=device-width')], ['菜单折叠toggle', h.includes('menu-toggle')], ['无ICP备案字样', !/ICP/.test(h)], ['无绝对化用语(最)', !/最/.test(h.replace(/更新时间/g,''))], ]; // 城市分站 & 友情链接 URL 完整性 const cityUrls=['nfcfs.tbtnt.com','palld.xidisy.com','xxfxv.xmotp.com','qwdvq.aixixin.com','xtbpq.xmotp.com','jhrah.buhuihua.com','odkfy.yu68999.com','dbdex.buhuihua.com','gulmx.51mplg.com','kxien.bfcmgg.com']; const linkUrls=['dtmaq.qianyin168.com','xawkl.xmotp.com','citzn.xidisy.com','luyxg.buhuihua.com','hqqcz.zhfmgc.com','hvhim.jntfw.com','nauzh.836188.com','dpqnl.layouwei.com','hksph.hgesf.com','meeaq.yu68999.com']; checks.push(['10个城市分站URL齐全', cityUrls.every(u=>h.includes(u))]); checks.push(['10个友情链接URL齐全', linkUrls.every(u=>h.includes(u))]); // 资质证书板块:未提供素材 => 应不存在 checks.push(['未写资质证书板块', !/资质证书/.test(h)]); let ok=0; checks.forEach(([n,r])=>{console.log((r?'✅':'❌')+' '+n); if(r)ok++;}); console.log(`\n通过 ${ok}/${checks.length}`); process.exit(ok===checks.length?0:1);