diff --git a/refs/pull/136/merge/coverage/clover.xml b/refs/pull/136/merge/coverage/clover.xml new file mode 100644 index 00000000..f7581d66 --- /dev/null +++ b/refs/pull/136/merge/coverage/clover.xml @@ -0,0 +1,166 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/refs/pull/136/merge/coverage/coverage-final.json b/refs/pull/136/merge/coverage/coverage-final.json new file mode 100644 index 00000000..f9897ff7 --- /dev/null +++ b/refs/pull/136/merge/coverage/coverage-final.json @@ -0,0 +1,19 @@ +{"/home/runner/work/next-template/next-template/src/instrumentation.node.ts": {"path":"/home/runner/work/next-template/next-template/src/instrumentation.node.ts","statementMap":{"0":{"start":{"line":57,"column":15},"end":{"line":57,"column":48}},"1":{"start":{"line":59,"column":26},"end":{"line":94,"column":1}},"2":{"start":{"line":60,"column":24},"end":{"line":60,"column":57}},"3":{"start":{"line":62,"column":2},"end":{"line":81,"column":3}},"4":{"start":{"line":63,"column":4},"end":{"line":67,"column":5}},"5":{"start":{"line":64,"column":6},"end":{"line":66,"column":7}},"6":{"start":{"line":69,"column":4},"end":{"line":73,"column":5}},"7":{"start":{"line":75,"column":4},"end":{"line":80,"column":6}},"8":{"start":{"line":83,"column":2},"end":{"line":85,"column":3}},"9":{"start":{"line":87,"column":2},"end":{"line":93,"column":3}},"10":{"start":{"line":90,"column":6},"end":{"line":90,"column":56}},"11":{"start":{"line":96,"column":32},"end":{"line":98,"column":1}},"12":{"start":{"line":97,"column":2},"end":{"line":97,"column":77}},"13":{"start":{"line":100,"column":25},"end":{"line":102,"column":1}},"14":{"start":{"line":101,"column":2},"end":{"line":101,"column":76}},"15":{"start":{"line":104,"column":25},"end":{"line":135,"column":1}},"16":{"start":{"line":105,"column":23},"end":{"line":105,"column":55}},"17":{"start":{"line":107,"column":2},"end":{"line":123,"column":3}},"18":{"start":{"line":108,"column":4},"end":{"line":112,"column":5}},"19":{"start":{"line":109,"column":6},"end":{"line":111,"column":7}},"20":{"start":{"line":114,"column":4},"end":{"line":116,"column":5}},"21":{"start":{"line":118,"column":4},"end":{"line":122,"column":6}},"22":{"start":{"line":125,"column":2},"end":{"line":127,"column":3}},"23":{"start":{"line":129,"column":2},"end":{"line":134,"column":3}},"24":{"start":{"line":132,"column":6},"end":{"line":132,"column":56}},"25":{"start":{"line":137,"column":0},"end":{"line":137,"column":48}},"26":{"start":{"line":139,"column":12},"end":{"line":160,"column":2}},"27":{"start":{"line":161,"column":0},"end":{"line":161,"column":11}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":59,"column":26},"end":{"line":59,"column":27}},"loc":{"start":{"line":59,"column":52},"end":{"line":94,"column":1}},"line":59},"1":{"name":"(anonymous_1)","decl":{"start":{"line":89,"column":12},"end":{"line":89,"column":13}},"loc":{"start":{"line":90,"column":6},"end":{"line":90,"column":56}},"line":90},"2":{"name":"(anonymous_2)","decl":{"start":{"line":91,"column":16},"end":{"line":91,"column":17}},"loc":{"start":{"line":91,"column":28},"end":{"line":91,"column":30}},"line":91},"3":{"name":"(anonymous_3)","decl":{"start":{"line":92,"column":14},"end":{"line":92,"column":15}},"loc":{"start":{"line":92,"column":26},"end":{"line":92,"column":28}},"line":92},"4":{"name":"(anonymous_4)","decl":{"start":{"line":96,"column":32},"end":{"line":96,"column":33}},"loc":{"start":{"line":96,"column":38},"end":{"line":98,"column":1}},"line":96},"5":{"name":"(anonymous_5)","decl":{"start":{"line":100,"column":25},"end":{"line":100,"column":26}},"loc":{"start":{"line":100,"column":31},"end":{"line":102,"column":1}},"line":100},"6":{"name":"(anonymous_6)","decl":{"start":{"line":104,"column":25},"end":{"line":104,"column":26}},"loc":{"start":{"line":104,"column":45},"end":{"line":135,"column":1}},"line":104},"7":{"name":"(anonymous_7)","decl":{"start":{"line":131,"column":12},"end":{"line":131,"column":13}},"loc":{"start":{"line":132,"column":6},"end":{"line":132,"column":56}},"line":132},"8":{"name":"(anonymous_8)","decl":{"start":{"line":133,"column":14},"end":{"line":133,"column":15}},"loc":{"start":{"line":133,"column":26},"end":{"line":133,"column":28}},"line":133}},"branchMap":{"0":{"loc":{"start":{"line":62,"column":2},"end":{"line":81,"column":3}},"type":"if","locations":[{"start":{"line":62,"column":2},"end":{"line":81,"column":3}},{"start":{},"end":{}}],"line":62},"1":{"loc":{"start":{"line":63,"column":4},"end":{"line":67,"column":5}},"type":"if","locations":[{"start":{"line":63,"column":4},"end":{"line":67,"column":5}},{"start":{},"end":{}}],"line":63},"2":{"loc":{"start":{"line":97,"column":18},"end":{"line":97,"column":76}},"type":"binary-expr","locations":[{"start":{"line":97,"column":18},"end":{"line":97,"column":65}},{"start":{"line":97,"column":69},"end":{"line":97,"column":76}}],"line":97},"3":{"loc":{"start":{"line":101,"column":18},"end":{"line":101,"column":75}},"type":"binary-expr","locations":[{"start":{"line":101,"column":18},"end":{"line":101,"column":64}},{"start":{"line":101,"column":68},"end":{"line":101,"column":75}}],"line":101},"4":{"loc":{"start":{"line":107,"column":2},"end":{"line":123,"column":3}},"type":"if","locations":[{"start":{"line":107,"column":2},"end":{"line":123,"column":3}},{"start":{},"end":{}}],"line":107},"5":{"loc":{"start":{"line":108,"column":4},"end":{"line":112,"column":5}},"type":"if","locations":[{"start":{"line":108,"column":4},"end":{"line":112,"column":5}},{"start":{},"end":{}}],"line":108},"6":{"loc":{"start":{"line":152,"column":6},"end":{"line":152,"column":45}},"type":"binary-expr","locations":[{"start":{"line":152,"column":6},"end":{"line":152,"column":34}},{"start":{"line":152,"column":38},"end":{"line":152,"column":45}}],"line":152},"7":{"loc":{"start":{"line":154,"column":6},"end":{"line":154,"column":54}},"type":"binary-expr","locations":[{"start":{"line":154,"column":6},"end":{"line":154,"column":35}},{"start":{"line":154,"column":39},"end":{"line":154,"column":54}}],"line":154},"8":{"loc":{"start":{"line":156,"column":6},"end":{"line":156,"column":59}},"type":"binary-expr","locations":[{"start":{"line":156,"column":6},"end":{"line":156,"column":31}},{"start":{"line":156,"column":35},"end":{"line":156,"column":59}}],"line":156}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0},"b":{"0":[0,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0,0],"8":[0,0]}} +,"/home/runner/work/next-template/next-template/src/instrumentation.ts": {"path":"/home/runner/work/next-template/next-template/src/instrumentation.ts","statementMap":{"0":{"start":{"line":2,"column":2},"end":{"line":4,"column":3}},"1":{"start":{"line":3,"column":4},"end":{"line":3,"column":42}}},"fnMap":{"0":{"name":"register","decl":{"start":{"line":1,"column":22},"end":{"line":1,"column":30}},"loc":{"start":{"line":1,"column":33},"end":{"line":5,"column":1}},"line":1}},"branchMap":{"0":{"loc":{"start":{"line":2,"column":2},"end":{"line":4,"column":3}},"type":"if","locations":[{"start":{"line":2,"column":2},"end":{"line":4,"column":3}},{"start":{},"end":{}}],"line":2}},"s":{"0":0,"1":0},"f":{"0":0},"b":{"0":[0,0]}} +,"/home/runner/work/next-template/next-template/src/middleware.ts": {"path":"/home/runner/work/next-template/next-template/src/middleware.ts","statementMap":{"0":{"start":{"line":5,"column":27},"end":{"line":5,"column":30}},"1":{"start":{"line":6,"column":31},"end":{"line":6,"column":38}},"2":{"start":{"line":7,"column":17},"end":{"line":7,"column":40}},"3":{"start":{"line":9,"column":2},"end":{"line":15,"column":3}},"4":{"start":{"line":14,"column":4},"end":{"line":14,"column":30}},"5":{"start":{"line":17,"column":2},"end":{"line":17,"column":47}},"6":{"start":{"line":19,"column":2},"end":{"line":26,"column":3}},"7":{"start":{"line":20,"column":4},"end":{"line":22,"column":5}},"8":{"start":{"line":24,"column":4},"end":{"line":24,"column":33}},"9":{"start":{"line":25,"column":4},"end":{"line":25,"column":61}},"10":{"start":{"line":28,"column":2},"end":{"line":28,"column":28}}},"fnMap":{"0":{"name":"middleware","decl":{"start":{"line":4,"column":16},"end":{"line":4,"column":26}},"loc":{"start":{"line":4,"column":45},"end":{"line":29,"column":1}},"line":4}},"branchMap":{"0":{"loc":{"start":{"line":9,"column":2},"end":{"line":15,"column":3}},"type":"if","locations":[{"start":{"line":9,"column":2},"end":{"line":15,"column":3}},{"start":{},"end":{}}],"line":9},"1":{"loc":{"start":{"line":19,"column":2},"end":{"line":26,"column":3}},"type":"if","locations":[{"start":{"line":19,"column":2},"end":{"line":26,"column":3}},{"start":{},"end":{}}],"line":19},"2":{"loc":{"start":{"line":19,"column":6},"end":{"line":19,"column":39}},"type":"binary-expr","locations":[{"start":{"line":19,"column":6},"end":{"line":19,"column":19}},{"start":{"line":19,"column":23},"end":{"line":19,"column":39}}],"line":19}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0],"2":[0,0]}} +,"/home/runner/work/next-template/next-template/src/components/DateModified.tsx": {"path":"/home/runner/work/next-template/next-template/src/components/DateModified.tsx","statementMap":{"0":{"start":{"line":14,"column":50},"end":{"line":23,"column":1}},"1":{"start":{"line":15,"column":2},"end":{"line":22,"column":3}},"2":{"start":{"line":25,"column":0},"end":{"line":28,"column":1}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":14,"column":50},"end":{"line":14,"column":51}},"loc":{"start":{"line":14,"column":68},"end":{"line":23,"column":1}},"line":14}},"branchMap":{},"s":{"0":4,"1":6,"2":4},"f":{"0":6},"b":{},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"2d0c3b9a35e2403bd4187dd5a467fac3baccaa54"} +,"/home/runner/work/next-template/next-template/src/components/Footer.tsx": {"path":"/home/runner/work/next-template/next-template/src/components/Footer.tsx","statementMap":{"0":{"start":{"line":23,"column":38},"end":{"line":101,"column":1}},"1":{"start":{"line":24,"column":16},"end":{"line":24,"column":40}},"2":{"start":{"line":25,"column":2},"end":{"line":100,"column":3}},"3":{"start":{"line":42,"column":16},"end":{"line":51,"column":17}},"4":{"start":{"line":68,"column":18},"end":{"line":85,"column":19}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":23,"column":38},"end":{"line":23,"column":39}},"loc":{"start":{"line":23,"column":49},"end":{"line":101,"column":1}},"line":23},"1":{"name":"(anonymous_1)","decl":{"start":{"line":41,"column":40},"end":{"line":41,"column":41}},"loc":{"start":{"line":41,"column":58},"end":{"line":52,"column":15}},"line":41},"2":{"name":"(anonymous_2)","decl":{"start":{"line":67,"column":33},"end":{"line":67,"column":34}},"loc":{"start":{"line":67,"column":51},"end":{"line":86,"column":17}},"line":67}},"branchMap":{"0":{"loc":{"start":{"line":72,"column":24},"end":{"line":74,"column":79}},"type":"cond-expr","locations":[{"start":{"line":73,"column":28},"end":{"line":73,"column":92}},{"start":{"line":74,"column":28},"end":{"line":74,"column":79}}],"line":72}},"s":{"0":3,"1":5,"2":5,"3":38,"4":24},"f":{"0":5,"1":38,"2":24},"b":{"0":[5,19]},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"16663b91e845e5ce4d5db5bfdb30e1da7cbfe6c1"} +,"/home/runner/work/next-template/next-template/src/components/Header.tsx": {"path":"/home/runner/work/next-template/next-template/src/components/Header.tsx","statementMap":{"0":{"start":{"line":10,"column":38},"end":{"line":79,"column":1}},"1":{"start":{"line":11,"column":16},"end":{"line":11,"column":40}},"2":{"start":{"line":12,"column":2},"end":{"line":78,"column":3}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":10,"column":38},"end":{"line":10,"column":39}},"loc":{"start":{"line":10,"column":49},"end":{"line":79,"column":1}},"line":10}},"branchMap":{"0":{"loc":{"start":{"line":36,"column":18},"end":{"line":38,"column":46}},"type":"cond-expr","locations":[{"start":{"line":37,"column":22},"end":{"line":37,"column":46}},{"start":{"line":38,"column":22},"end":{"line":38,"column":46}}],"line":36},"1":{"loc":{"start":{"line":41,"column":18},"end":{"line":43,"column":46}},"type":"cond-expr","locations":[{"start":{"line":42,"column":22},"end":{"line":42,"column":44}},{"start":{"line":43,"column":22},"end":{"line":43,"column":46}}],"line":41},"2":{"loc":{"start":{"line":51,"column":20},"end":{"line":51,"column":47}},"type":"binary-expr","locations":[{"start":{"line":51,"column":20},"end":{"line":51,"column":40}},{"start":{"line":51,"column":44},"end":{"line":51,"column":47}}],"line":51},"3":{"loc":{"start":{"line":52,"column":22},"end":{"line":52,"column":59}},"type":"cond-expr","locations":[{"start":{"line":52,"column":48},"end":{"line":52,"column":52}},{"start":{"line":52,"column":55},"end":{"line":52,"column":59}}],"line":52},"4":{"loc":{"start":{"line":54,"column":20},"end":{"line":54,"column":57}},"type":"cond-expr","locations":[{"start":{"line":54,"column":46},"end":{"line":54,"column":50}},{"start":{"line":54,"column":53},"end":{"line":54,"column":57}}],"line":54},"5":{"loc":{"start":{"line":56,"column":15},"end":{"line":56,"column":52}},"type":"cond-expr","locations":[{"start":{"line":56,"column":41},"end":{"line":56,"column":45}},{"start":{"line":56,"column":48},"end":{"line":56,"column":52}}],"line":56},"6":{"loc":{"start":{"line":64,"column":20},"end":{"line":64,"column":47}},"type":"binary-expr","locations":[{"start":{"line":64,"column":20},"end":{"line":64,"column":40}},{"start":{"line":64,"column":44},"end":{"line":64,"column":47}}],"line":64},"7":{"loc":{"start":{"line":65,"column":22},"end":{"line":65,"column":59}},"type":"cond-expr","locations":[{"start":{"line":65,"column":48},"end":{"line":65,"column":52}},{"start":{"line":65,"column":55},"end":{"line":65,"column":59}}],"line":65},"8":{"loc":{"start":{"line":68,"column":20},"end":{"line":68,"column":57}},"type":"cond-expr","locations":[{"start":{"line":68,"column":46},"end":{"line":68,"column":50}},{"start":{"line":68,"column":53},"end":{"line":68,"column":57}}],"line":68},"9":{"loc":{"start":{"line":70,"column":15},"end":{"line":70,"column":63}},"type":"cond-expr","locations":[{"start":{"line":70,"column":41},"end":{"line":70,"column":51}},{"start":{"line":70,"column":54},"end":{"line":70,"column":63}}],"line":70}},"s":{"0":3,"1":6,"2":6},"f":{"0":6},"b":{"0":[5,1],"1":[5,1],"2":[6,6],"3":[5,1],"4":[5,1],"5":[5,1],"6":[6,6],"7":[5,1],"8":[5,1],"9":[5,1]},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"f7b136abc5c606ba41bf2de1190c39a3a12f8e47"} +,"/home/runner/work/next-template/next-template/src/components/Layout.tsx": {"path":"/home/runner/work/next-template/next-template/src/components/Layout.tsx","statementMap":{"0":{"start":{"line":13,"column":38},"end":{"line":95,"column":1}},"1":{"start":{"line":14,"column":16},"end":{"line":14,"column":40}},"2":{"start":{"line":16,"column":2},"end":{"line":94,"column":3}},"3":{"start":{"line":97,"column":0},"end":{"line":99,"column":1}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":13,"column":38},"end":{"line":13,"column":39}},"loc":{"start":{"line":13,"column":49},"end":{"line":95,"column":1}},"line":13}},"branchMap":{"0":{"loc":{"start":{"line":19,"column":18},"end":{"line":19,"column":38}},"type":"binary-expr","locations":[{"start":{"line":19,"column":18},"end":{"line":19,"column":30}},{"start":{"line":19,"column":34},"end":{"line":19,"column":38}}],"line":19}},"s":{"0":2,"1":4,"2":4,"3":2},"f":{"0":4},"b":{"0":[4,0]},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"817355d8d477e79613184235e54f871a201ad6da"} +,"/home/runner/work/next-template/next-template/src/lib/cms.ts": {"path":"/home/runner/work/next-template/next-template/src/lib/cms.ts","statementMap":{"0":{"start":{"line":2,"column":14},"end":{"line":2,"column":23}},"1":{"start":{"line":3,"column":2},"end":{"line":3,"column":38}},"2":{"start":{"line":7,"column":2},"end":{"line":9,"column":3}},"3":{"start":{"line":10,"column":2},"end":{"line":10,"column":71}}},"fnMap":{"0":{"name":"fetchContent","decl":{"start":{"line":1,"column":22},"end":{"line":1,"column":34}},"loc":{"start":{"line":1,"column":37},"end":{"line":4,"column":1}},"line":1},"1":{"name":"exampleResponse","decl":{"start":{"line":6,"column":15},"end":{"line":6,"column":30}},"loc":{"start":{"line":6,"column":33},"end":{"line":11,"column":1}},"line":6}},"branchMap":{"0":{"loc":{"start":{"line":3,"column":9},"end":{"line":3,"column":38}},"type":"cond-expr","locations":[{"start":{"line":3,"column":15},"end":{"line":3,"column":18}},{"start":{"line":3,"column":21},"end":{"line":3,"column":38}}],"line":3}},"s":{"0":1,"1":1,"2":1,"3":1},"f":{"0":1,"1":1},"b":{"0":[0,1]},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"7584c30fa17c9154c3308795370cd779b7b95f27"} +,"/home/runner/work/next-template/next-template/src/logging/log-level.ts": {"path":"/home/runner/work/next-template/next-template/src/logging/log-level.ts","statementMap":{"0":{"start":{"line":1,"column":21},"end":{"line":5,"column":1}}},"fnMap":{},"branchMap":{},"s":{"0":0},"f":{},"b":{}} +,"/home/runner/work/next-template/next-template/src/logging/log-util.ts": {"path":"/home/runner/work/next-template/next-template/src/logging/log-util.ts","statementMap":{"0":{"start":{"line":4,"column":18},"end":{"line":4,"column":71}},"1":{"start":{"line":7,"column":2},"end":{"line":7,"column":62}},"2":{"start":{"line":11,"column":2},"end":{"line":11,"column":49}}},"fnMap":{"0":{"name":"getLogLevel","decl":{"start":{"line":6,"column":16},"end":{"line":6,"column":27}},"loc":{"start":{"line":6,"column":52},"end":{"line":8,"column":1}},"line":6},"1":{"name":"getLogger","decl":{"start":{"line":10,"column":16},"end":{"line":10,"column":25}},"loc":{"start":{"line":10,"column":48},"end":{"line":12,"column":1}},"line":10}},"branchMap":{"0":{"loc":{"start":{"line":7,"column":9},"end":{"line":7,"column":62}},"type":"binary-expr","locations":[{"start":{"line":7,"column":9},"end":{"line":7,"column":30}},{"start":{"line":7,"column":34},"end":{"line":7,"column":52}},{"start":{"line":7,"column":56},"end":{"line":7,"column":62}}],"line":7}},"s":{"0":0,"1":0,"2":0},"f":{"0":0,"1":0},"b":{"0":[0,0,0]}} +,"/home/runner/work/next-template/next-template/src/pages/404.tsx": {"path":"/home/runner/work/next-template/next-template/src/pages/404.tsx","statementMap":{"0":{"start":{"line":7,"column":2},"end":{"line":61,"column":3}},"1":{"start":{"line":64,"column":0},"end":{"line":66,"column":1}},"2":{"start":{"line":65,"column":2},"end":{"line":65,"column":20}}},"fnMap":{"0":{"name":"Custom404","decl":{"start":{"line":6,"column":24},"end":{"line":6,"column":33}},"loc":{"start":{"line":6,"column":36},"end":{"line":62,"column":1}},"line":6},"1":{"name":"PageLayout","decl":{"start":{"line":64,"column":31},"end":{"line":64,"column":41}},"loc":{"start":{"line":64,"column":58},"end":{"line":66,"column":1}},"line":64}},"branchMap":{},"s":{"0":1,"1":1,"2":0},"f":{"0":1,"1":0},"b":{},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"4ddeb44a2300fa32dd9b3e2926545e1f1388f730"} +,"/home/runner/work/next-template/next-template/src/pages/_app.tsx": {"path":"/home/runner/work/next-template/next-template/src/pages/_app.tsx","statementMap":{"0":{"start":{"line":18,"column":12},"end":{"line":36,"column":1}},"1":{"start":{"line":19,"column":2},"end":{"line":21,"column":3}},"2":{"start":{"line":20,"column":4},"end":{"line":20,"column":60}},"3":{"start":{"line":23,"column":2},"end":{"line":35,"column":3}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":18,"column":12},"end":{"line":18,"column":13}},"loc":{"start":{"line":18,"column":49},"end":{"line":36,"column":1}},"line":18}},"branchMap":{"0":{"loc":{"start":{"line":19,"column":2},"end":{"line":21,"column":3}},"type":"if","locations":[{"start":{"line":19,"column":2},"end":{"line":21,"column":3}},{"start":{},"end":{}}],"line":19}},"s":{"0":1,"1":1,"2":1,"3":0},"f":{"0":1},"b":{"0":[1,0]},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"5c9b685e247cc67da3f7c03d134c3d802bcbba40"} +,"/home/runner/work/next-template/next-template/src/pages/_document.tsx": {"path":"/home/runner/work/next-template/next-template/src/pages/_document.tsx","statementMap":{"0":{"start":{"line":8,"column":15},"end":{"line":8,"column":29}},"1":{"start":{"line":9,"column":2},"end":{"line":26,"column":3}}},"fnMap":{"0":{"name":"Document","decl":{"start":{"line":7,"column":24},"end":{"line":7,"column":32}},"loc":{"start":{"line":7,"column":60},"end":{"line":27,"column":1}},"line":7}},"branchMap":{"0":{"loc":{"start":{"line":8,"column":15},"end":{"line":8,"column":29}},"type":"binary-expr","locations":[{"start":{"line":8,"column":15},"end":{"line":8,"column":21}},{"start":{"line":8,"column":25},"end":{"line":8,"column":29}}],"line":8}},"s":{"0":0,"1":0},"f":{"0":0},"b":{"0":[0,0]}} +,"/home/runner/work/next-template/next-template/src/pages/_error.tsx": {"path":"/home/runner/work/next-template/next-template/src/pages/_error.tsx","statementMap":{"0":{"start":{"line":10,"column":2},"end":{"line":68,"column":3}},"1":{"start":{"line":71,"column":0},"end":{"line":73,"column":1}},"2":{"start":{"line":72,"column":2},"end":{"line":72,"column":20}},"3":{"start":{"line":75,"column":0},"end":{"line":78,"column":1}},"4":{"start":{"line":76,"column":21},"end":{"line":76,"column":70}},"5":{"start":{"line":77,"column":2},"end":{"line":77,"column":23}}},"fnMap":{"0":{"name":"CustomError","decl":{"start":{"line":9,"column":16},"end":{"line":9,"column":27}},"loc":{"start":{"line":9,"column":56},"end":{"line":69,"column":1}},"line":9},"1":{"name":"PageLayout","decl":{"start":{"line":71,"column":33},"end":{"line":71,"column":43}},"loc":{"start":{"line":71,"column":60},"end":{"line":73,"column":1}},"line":71},"2":{"name":"(anonymous_2)","decl":{"start":{"line":75,"column":30},"end":{"line":75,"column":31}},"loc":{"start":{"line":75,"column":65},"end":{"line":78,"column":1}},"line":75}},"branchMap":{"0":{"loc":{"start":{"line":15,"column":11},"end":{"line":17,"column":43}},"type":"cond-expr","locations":[{"start":{"line":16,"column":14},"end":{"line":16,"column":57}},{"start":{"line":17,"column":14},"end":{"line":17,"column":43}}],"line":15},"1":{"loc":{"start":{"line":42,"column":11},"end":{"line":44,"column":45}},"type":"cond-expr","locations":[{"start":{"line":43,"column":14},"end":{"line":43,"column":36}},{"start":{"line":44,"column":14},"end":{"line":44,"column":45}}],"line":42},"2":{"loc":{"start":{"line":76,"column":21},"end":{"line":76,"column":70}},"type":"cond-expr","locations":[{"start":{"line":76,"column":27},"end":{"line":76,"column":41}},{"start":{"line":76,"column":44},"end":{"line":76,"column":70}}],"line":76},"3":{"loc":{"start":{"line":76,"column":44},"end":{"line":76,"column":70}},"type":"cond-expr","locations":[{"start":{"line":76,"column":50},"end":{"line":76,"column":64}},{"start":{"line":76,"column":67},"end":{"line":76,"column":70}}],"line":76}},"s":{"0":2,"1":1,"2":0,"3":1,"4":0,"5":0},"f":{"0":2,"1":0,"2":0},"b":{"0":[1,1],"1":[1,1],"2":[0,0],"3":[0,0]},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"2d328a48874b31cfdb8cee6099500f2dc83771ef"} +,"/home/runner/work/next-template/next-template/src/pages/home.tsx": {"path":"/home/runner/work/next-template/next-template/src/pages/home.tsx","statementMap":{"0":{"start":{"line":17,"column":16},"end":{"line":17,"column":50}},"1":{"start":{"line":18,"column":2},"end":{"line":29,"column":3}},"2":{"start":{"line":32,"column":46},"end":{"line":46,"column":1}},"3":{"start":{"line":33,"column":18},"end":{"line":33,"column":38}},"4":{"start":{"line":38,"column":2},"end":{"line":45,"column":3}}},"fnMap":{"0":{"name":"Home","decl":{"start":{"line":16,"column":24},"end":{"line":16,"column":28}},"loc":{"start":{"line":16,"column":47},"end":{"line":30,"column":1}},"line":16},"1":{"name":"(anonymous_1)","decl":{"start":{"line":32,"column":46},"end":{"line":32,"column":47}},"loc":{"start":{"line":32,"column":68},"end":{"line":46,"column":1}},"line":32}},"branchMap":{},"s":{"0":1,"1":1,"2":1,"3":1,"4":1},"f":{"0":1,"1":1},"b":{},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"e4c314d4732810b4db40893dc9398be529bc5a08"} +,"/home/runner/work/next-template/next-template/src/pages/index.tsx": {"path":"/home/runner/work/next-template/next-template/src/pages/index.tsx","statementMap":{"0":{"start":{"line":7,"column":2},"end":{"line":79,"column":3}},"1":{"start":{"line":82,"column":0},"end":{"line":84,"column":1}},"2":{"start":{"line":83,"column":2},"end":{"line":83,"column":20}}},"fnMap":{"0":{"name":"Index","decl":{"start":{"line":6,"column":24},"end":{"line":6,"column":29}},"loc":{"start":{"line":6,"column":32},"end":{"line":80,"column":1}},"line":6},"1":{"name":"PageLayout","decl":{"start":{"line":82,"column":27},"end":{"line":82,"column":37}},"loc":{"start":{"line":82,"column":54},"end":{"line":84,"column":1}},"line":82}},"branchMap":{},"s":{"0":2,"1":2,"2":1},"f":{"0":2,"1":1},"b":{},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"3f1740c6a967ed3ba5482be4f0b8e9da10f30fc6"} +,"/home/runner/work/next-template/next-template/src/pages/api/envAPIExample.ts": {"path":"/home/runner/work/next-template/next-template/src/pages/api/envAPIExample.ts","statementMap":{"0":{"start":{"line":4,"column":2},"end":{"line":4,"column":59}}},"fnMap":{"0":{"name":"handler","decl":{"start":{"line":3,"column":24},"end":{"line":3,"column":31}},"loc":{"start":{"line":3,"column":75},"end":{"line":5,"column":1}},"line":3}},"branchMap":{},"s":{"0":0},"f":{"0":0},"b":{}} +,"/home/runner/work/next-template/next-template/src/pages/api/metrics.ts": {"path":"/home/runner/work/next-template/next-template/src/pages/api/metrics.ts","statementMap":{},"fnMap":{},"branchMap":{},"s":{},"f":{},"b":{}} +} diff --git a/refs/pull/136/merge/coverage/coverage-summary.json b/refs/pull/136/merge/coverage/coverage-summary.json new file mode 100644 index 00000000..476669f5 --- /dev/null +++ b/refs/pull/136/merge/coverage/coverage-summary.json @@ -0,0 +1,20 @@ +{"total": {"lines":{"total":88,"covered":35,"skipped":0,"pct":39.77},"statements":{"total":88,"covered":35,"skipped":0,"pct":39.77},"functions":{"total":33,"covered":15,"skipped":0,"pct":45.45},"branches":{"total":67,"covered":29,"skipped":0,"pct":43.28},"branchesTrue":{"total":0,"covered":0,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/instrumentation.node.ts": {"lines":{"total":28,"covered":0,"skipped":0,"pct":0},"functions":{"total":9,"covered":0,"skipped":0,"pct":0},"statements":{"total":28,"covered":0,"skipped":0,"pct":0},"branches":{"total":18,"covered":0,"skipped":0,"pct":0}} +,"/home/runner/work/next-template/next-template/src/instrumentation.ts": {"lines":{"total":2,"covered":0,"skipped":0,"pct":0},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":2,"covered":0,"skipped":0,"pct":0},"branches":{"total":2,"covered":0,"skipped":0,"pct":0}} +,"/home/runner/work/next-template/next-template/src/middleware.ts": {"lines":{"total":11,"covered":0,"skipped":0,"pct":0},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":11,"covered":0,"skipped":0,"pct":0},"branches":{"total":6,"covered":0,"skipped":0,"pct":0}} +,"/home/runner/work/next-template/next-template/src/components/DateModified.tsx": {"lines":{"total":3,"covered":3,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":3,"covered":3,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/components/Footer.tsx": {"lines":{"total":5,"covered":5,"skipped":0,"pct":100},"functions":{"total":3,"covered":3,"skipped":0,"pct":100},"statements":{"total":5,"covered":5,"skipped":0,"pct":100},"branches":{"total":2,"covered":2,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/components/Header.tsx": {"lines":{"total":3,"covered":3,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":3,"covered":3,"skipped":0,"pct":100},"branches":{"total":20,"covered":20,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/components/Layout.tsx": {"lines":{"total":4,"covered":4,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":4,"covered":4,"skipped":0,"pct":100},"branches":{"total":2,"covered":1,"skipped":0,"pct":50}} +,"/home/runner/work/next-template/next-template/src/lib/cms.ts": {"lines":{"total":4,"covered":4,"skipped":0,"pct":100},"functions":{"total":2,"covered":2,"skipped":0,"pct":100},"statements":{"total":4,"covered":4,"skipped":0,"pct":100},"branches":{"total":2,"covered":1,"skipped":0,"pct":50}} +,"/home/runner/work/next-template/next-template/src/logging/log-level.ts": {"lines":{"total":1,"covered":0,"skipped":0,"pct":0},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":1,"covered":0,"skipped":0,"pct":0},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/logging/log-util.ts": {"lines":{"total":3,"covered":0,"skipped":0,"pct":0},"functions":{"total":2,"covered":0,"skipped":0,"pct":0},"statements":{"total":3,"covered":0,"skipped":0,"pct":0},"branches":{"total":3,"covered":0,"skipped":0,"pct":0}} +,"/home/runner/work/next-template/next-template/src/pages/404.tsx": {"lines":{"total":3,"covered":2,"skipped":0,"pct":66.66},"functions":{"total":2,"covered":1,"skipped":0,"pct":50},"statements":{"total":3,"covered":2,"skipped":0,"pct":66.66},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/pages/_app.tsx": {"lines":{"total":4,"covered":3,"skipped":0,"pct":75},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"statements":{"total":4,"covered":3,"skipped":0,"pct":75},"branches":{"total":2,"covered":1,"skipped":0,"pct":50}} +,"/home/runner/work/next-template/next-template/src/pages/_document.tsx": {"lines":{"total":2,"covered":0,"skipped":0,"pct":0},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":2,"covered":0,"skipped":0,"pct":0},"branches":{"total":2,"covered":0,"skipped":0,"pct":0}} +,"/home/runner/work/next-template/next-template/src/pages/_error.tsx": {"lines":{"total":6,"covered":3,"skipped":0,"pct":50},"functions":{"total":3,"covered":1,"skipped":0,"pct":33.33},"statements":{"total":6,"covered":3,"skipped":0,"pct":50},"branches":{"total":8,"covered":4,"skipped":0,"pct":50}} +,"/home/runner/work/next-template/next-template/src/pages/home.tsx": {"lines":{"total":5,"covered":5,"skipped":0,"pct":100},"functions":{"total":2,"covered":2,"skipped":0,"pct":100},"statements":{"total":5,"covered":5,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/pages/index.tsx": {"lines":{"total":3,"covered":3,"skipped":0,"pct":100},"functions":{"total":2,"covered":2,"skipped":0,"pct":100},"statements":{"total":3,"covered":3,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/pages/api/envAPIExample.ts": {"lines":{"total":1,"covered":0,"skipped":0,"pct":0},"functions":{"total":1,"covered":0,"skipped":0,"pct":0},"statements":{"total":1,"covered":0,"skipped":0,"pct":0},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}} +,"/home/runner/work/next-template/next-template/src/pages/api/metrics.ts": {"lines":{"total":0,"covered":0,"skipped":0,"pct":100},"functions":{"total":0,"covered":0,"skipped":0,"pct":100},"statements":{"total":0,"covered":0,"skipped":0,"pct":100},"branches":{"total":0,"covered":0,"skipped":0,"pct":100}} +} diff --git a/refs/pull/136/merge/coverage/lcov-report/base.css b/refs/pull/136/merge/coverage/lcov-report/base.css new file mode 100644 index 00000000..f418035b --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/base.css @@ -0,0 +1,224 @@ +body, html { + margin:0; padding: 0; + height: 100%; +} +body { + font-family: Helvetica Neue, Helvetica, Arial; + font-size: 14px; + color:#333; +} +.small { font-size: 12px; } +*, *:after, *:before { + -webkit-box-sizing:border-box; + -moz-box-sizing:border-box; + box-sizing:border-box; + } +h1 { font-size: 20px; margin: 0;} +h2 { font-size: 14px; } +pre { + font: 12px/1.4 Consolas, "Liberation Mono", Menlo, Courier, monospace; + margin: 0; + padding: 0; + -moz-tab-size: 2; + -o-tab-size: 2; + tab-size: 2; +} +a { color:#0074D9; text-decoration:none; } +a:hover { text-decoration:underline; } +.strong { font-weight: bold; } +.space-top1 { padding: 10px 0 0 0; } +.pad2y { padding: 20px 0; } +.pad1y { padding: 10px 0; } +.pad2x { padding: 0 20px; } +.pad2 { padding: 20px; } +.pad1 { padding: 10px; } +.space-left2 { padding-left:55px; } +.space-right2 { padding-right:20px; } +.center { text-align:center; } +.clearfix { display:block; } +.clearfix:after { + content:''; + display:block; + height:0; + clear:both; + visibility:hidden; + } +.fl { float: left; } +@media only screen and (max-width:640px) { + .col3 { width:100%; max-width:100%; } + .hide-mobile { display:none!important; } +} + +.quiet { + color: #7f7f7f; + color: rgba(0,0,0,0.5); +} +.quiet a { opacity: 0.7; } + +.fraction { + font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; + font-size: 10px; + color: #555; + background: #E8E8E8; + padding: 4px 5px; + border-radius: 3px; + vertical-align: middle; +} + +div.path a:link, div.path a:visited { color: #333; } +table.coverage { + border-collapse: collapse; + margin: 10px 0 0 0; + padding: 0; +} + +table.coverage td { + margin: 0; + padding: 0; + vertical-align: top; +} +table.coverage td.line-count { + text-align: right; + padding: 0 5px 0 20px; +} +table.coverage td.line-coverage { + text-align: right; + padding-right: 10px; + min-width:20px; +} + +table.coverage td span.cline-any { + display: inline-block; + padding: 0 5px; + width: 100%; +} +.missing-if-branch { + display: inline-block; + margin-right: 5px; + border-radius: 3px; + position: relative; + padding: 0 4px; + background: #333; + color: yellow; +} + +.skip-if-branch { + display: none; + margin-right: 10px; + position: relative; + padding: 0 4px; + background: #ccc; + color: white; +} +.missing-if-branch .typ, .skip-if-branch .typ { + color: inherit !important; +} +.coverage-summary { + border-collapse: collapse; + width: 100%; +} +.coverage-summary tr { border-bottom: 1px solid #bbb; } +.keyline-all { border: 1px solid #ddd; } +.coverage-summary td, .coverage-summary th { padding: 10px; } +.coverage-summary tbody { border: 1px solid #bbb; } +.coverage-summary td { border-right: 1px solid #bbb; } +.coverage-summary td:last-child { border-right: none; } +.coverage-summary th { + text-align: left; + font-weight: normal; + white-space: nowrap; +} +.coverage-summary th.file { border-right: none !important; } +.coverage-summary th.pct { } +.coverage-summary th.pic, +.coverage-summary th.abs, +.coverage-summary td.pct, +.coverage-summary td.abs { text-align: right; } +.coverage-summary td.file { white-space: nowrap; } +.coverage-summary td.pic { min-width: 120px !important; } +.coverage-summary tfoot td { } + +.coverage-summary .sorter { + height: 10px; + width: 7px; + display: inline-block; + margin-left: 0.5em; + background: url(sort-arrow-sprite.png) no-repeat scroll 0 0 transparent; +} +.coverage-summary .sorted .sorter { + background-position: 0 -20px; +} +.coverage-summary .sorted-desc .sorter { + background-position: 0 -10px; +} +.status-line { height: 10px; } +/* yellow */ +.cbranch-no { background: yellow !important; color: #111; } +/* dark red */ +.red.solid, .status-line.low, .low .cover-fill { background:#C21F39 } +.low .chart { border:1px solid #C21F39 } +.highlighted, +.highlighted .cstat-no, .highlighted .fstat-no, .highlighted .cbranch-no{ + background: #C21F39 !important; +} +/* medium red */ +.cstat-no, .fstat-no, .cbranch-no, .cbranch-no { background:#F6C6CE } +/* light red */ +.low, .cline-no { background:#FCE1E5 } +/* light green */ +.high, .cline-yes { background:rgb(230,245,208) } +/* medium green */ +.cstat-yes { background:rgb(161,215,106) } +/* dark green */ +.status-line.high, .high .cover-fill { background:rgb(77,146,33) } +.high .chart { border:1px solid rgb(77,146,33) } +/* dark yellow (gold) */ +.status-line.medium, .medium .cover-fill { background: #f9cd0b; } +.medium .chart { border:1px solid #f9cd0b; } +/* light yellow */ +.medium { background: #fff4c2; } + +.cstat-skip { background: #ddd; color: #111; } +.fstat-skip { background: #ddd; color: #111 !important; } +.cbranch-skip { background: #ddd !important; color: #111; } + +span.cline-neutral { background: #eaeaea; } + +.coverage-summary td.empty { + opacity: .5; + padding-top: 4px; + padding-bottom: 4px; + line-height: 1; + color: #888; +} + +.cover-fill, .cover-empty { + display:inline-block; + height: 12px; +} +.chart { + line-height: 0; +} +.cover-empty { + background: white; +} +.cover-full { + border-right: none !important; +} +pre.prettyprint { + border: none !important; + padding: 0 !important; + margin: 0 !important; +} +.com { color: #999 !important; } +.ignore-none { color: #999; font-weight: normal; } + +.wrapper { + min-height: 100%; + height: auto !important; + height: 100%; + margin: 0 auto -48px; +} +.footer, .push { + height: 48px; +} diff --git a/refs/pull/136/merge/coverage/lcov-report/block-navigation.js b/refs/pull/136/merge/coverage/lcov-report/block-navigation.js new file mode 100644 index 00000000..cc121302 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/block-navigation.js @@ -0,0 +1,87 @@ +/* eslint-disable */ +var jumpToCode = (function init() { + // Classes of code we would like to highlight in the file view + var missingCoverageClasses = ['.cbranch-no', '.cstat-no', '.fstat-no']; + + // Elements to highlight in the file listing view + var fileListingElements = ['td.pct.low']; + + // We don't want to select elements that are direct descendants of another match + var notSelector = ':not(' + missingCoverageClasses.join('):not(') + ') > '; // becomes `:not(a):not(b) > ` + + // Selecter that finds elements on the page to which we can jump + var selector = + fileListingElements.join(', ') + + ', ' + + notSelector + + missingCoverageClasses.join(', ' + notSelector); // becomes `:not(a):not(b) > a, :not(a):not(b) > b` + + // The NodeList of matching elements + var missingCoverageElements = document.querySelectorAll(selector); + + var currentIndex; + + function toggleClass(index) { + missingCoverageElements + .item(currentIndex) + .classList.remove('highlighted'); + missingCoverageElements.item(index).classList.add('highlighted'); + } + + function makeCurrent(index) { + toggleClass(index); + currentIndex = index; + missingCoverageElements.item(index).scrollIntoView({ + behavior: 'smooth', + block: 'center', + inline: 'center' + }); + } + + function goToPrevious() { + var nextIndex = 0; + if (typeof currentIndex !== 'number' || currentIndex === 0) { + nextIndex = missingCoverageElements.length - 1; + } else if (missingCoverageElements.length > 1) { + nextIndex = currentIndex - 1; + } + + makeCurrent(nextIndex); + } + + function goToNext() { + var nextIndex = 0; + + if ( + typeof currentIndex === 'number' && + currentIndex < missingCoverageElements.length - 1 + ) { + nextIndex = currentIndex + 1; + } + + makeCurrent(nextIndex); + } + + return function jump(event) { + if ( + document.getElementById('fileSearch') === document.activeElement && + document.activeElement != null + ) { + // if we're currently focused on the search input, we don't want to navigate + return; + } + + switch (event.which) { + case 78: // n + case 74: // j + goToNext(); + break; + case 66: // b + case 75: // k + case 80: // p + goToPrevious(); + break; + } + }; +})(); +window.addEventListener('keydown', jumpToCode); diff --git a/refs/pull/136/merge/coverage/lcov-report/favicon.png b/refs/pull/136/merge/coverage/lcov-report/favicon.png new file mode 100644 index 00000000..c1525b81 Binary files /dev/null and b/refs/pull/136/merge/coverage/lcov-report/favicon.png differ diff --git a/refs/pull/136/merge/coverage/lcov-report/index.html b/refs/pull/136/merge/coverage/lcov-report/index.html new file mode 100644 index 00000000..088958c3 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/index.html @@ -0,0 +1,191 @@ + + + + + + Code coverage report for All files + + + + + + + + + +
+
+

All files

+
+ +
+ 39.77% + Statements + 35/88 +
+ + +
+ 43.28% + Branches + 29/67 +
+ + +
+ 45.45% + Functions + 15/33 +
+ + +
+ 39.77% + Lines + 35/88 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
src +
+
0%0/410%0/260%0/110%0/41
src/components +
+
100%15/1595.83%23/24100%6/6100%15/15
src/lib +
+
100%4/450%1/2100%2/2100%4/4
src/logging +
+
0%0/40%0/30%0/20%0/4
src/pages +
+
69.56%16/2341.66%5/1263.63%7/1169.56%16/23
src/pages/api +
+
0%0/1100%0/00%0/10%0/1
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/prettify.css b/refs/pull/136/merge/coverage/lcov-report/prettify.css new file mode 100644 index 00000000..b317a7cd --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/prettify.css @@ -0,0 +1 @@ +.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee} diff --git a/refs/pull/136/merge/coverage/lcov-report/prettify.js b/refs/pull/136/merge/coverage/lcov-report/prettify.js new file mode 100644 index 00000000..b3225238 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/prettify.js @@ -0,0 +1,2 @@ +/* eslint-disable */ +window.PR_SHOULD_USE_CONTINUATION=true;(function(){var h=["break,continue,do,else,for,if,return,while"];var u=[h,"auto,case,char,const,default,double,enum,extern,float,goto,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"];var p=[u,"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"];var l=[p,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,dynamic_cast,explicit,export,friend,inline,late_check,mutable,namespace,nullptr,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"];var x=[p,"abstract,boolean,byte,extends,final,finally,implements,import,instanceof,null,native,package,strictfp,super,synchronized,throws,transient"];var R=[x,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,interface,internal,into,is,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var"];var r="all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,true,try,unless,until,when,while,yes";var w=[p,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"];var s="caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END";var I=[h,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"];var f=[h,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"];var H=[h,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"];var A=[l,R,w,s+I,f,H];var e=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)/;var C="str";var z="kwd";var j="com";var O="typ";var G="lit";var L="pun";var F="pln";var m="tag";var E="dec";var J="src";var P="atn";var n="atv";var N="nocode";var M="(?:^^\\.?|[+-]|\\!|\\!=|\\!==|\\#|\\%|\\%=|&|&&|&&=|&=|\\(|\\*|\\*=|\\+=|\\,|\\-=|\\->|\\/|\\/=|:|::|\\;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|\\?|\\@|\\[|\\^|\\^=|\\^\\^|\\^\\^=|\\{|\\||\\|=|\\|\\||\\|\\|=|\\~|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*";function k(Z){var ad=0;var S=false;var ac=false;for(var V=0,U=Z.length;V122)){if(!(al<65||ag>90)){af.push([Math.max(65,ag)|32,Math.min(al,90)|32])}if(!(al<97||ag>122)){af.push([Math.max(97,ag)&~32,Math.min(al,122)&~32])}}}}af.sort(function(av,au){return(av[0]-au[0])||(au[1]-av[1])});var ai=[];var ap=[NaN,NaN];for(var ar=0;arat[0]){if(at[1]+1>at[0]){an.push("-")}an.push(T(at[1]))}}an.push("]");return an.join("")}function W(al){var aj=al.source.match(new RegExp("(?:\\[(?:[^\\x5C\\x5D]|\\\\[\\s\\S])*\\]|\\\\u[A-Fa-f0-9]{4}|\\\\x[A-Fa-f0-9]{2}|\\\\[0-9]+|\\\\[^ux0-9]|\\(\\?[:!=]|[\\(\\)\\^]|[^\\x5B\\x5C\\(\\)\\^]+)","g"));var ah=aj.length;var an=[];for(var ak=0,am=0;ak=2&&ai==="["){aj[ak]=X(ag)}else{if(ai!=="\\"){aj[ak]=ag.replace(/[a-zA-Z]/g,function(ao){var ap=ao.charCodeAt(0);return"["+String.fromCharCode(ap&~32,ap|32)+"]"})}}}}return aj.join("")}var aa=[];for(var V=0,U=Z.length;V=0;){S[ac.charAt(ae)]=Y}}var af=Y[1];var aa=""+af;if(!ag.hasOwnProperty(aa)){ah.push(af);ag[aa]=null}}ah.push(/[\0-\uffff]/);V=k(ah)})();var X=T.length;var W=function(ah){var Z=ah.sourceCode,Y=ah.basePos;var ad=[Y,F];var af=0;var an=Z.match(V)||[];var aj={};for(var ae=0,aq=an.length;ae=5&&"lang-"===ap.substring(0,5);if(am&&!(ai&&typeof ai[1]==="string")){am=false;ap=J}if(!am){aj[ag]=ap}}var ab=af;af+=ag.length;if(!am){ad.push(Y+ab,ap)}else{var al=ai[1];var ak=ag.indexOf(al);var ac=ak+al.length;if(ai[2]){ac=ag.length-ai[2].length;ak=ac-al.length}var ar=ap.substring(5);B(Y+ab,ag.substring(0,ak),W,ad);B(Y+ab+ak,al,q(ar,al),ad);B(Y+ab+ac,ag.substring(ac),W,ad)}}ah.decorations=ad};return W}function i(T){var W=[],S=[];if(T.tripleQuotedStrings){W.push([C,/^(?:\'\'\'(?:[^\'\\]|\\[\s\S]|\'{1,2}(?=[^\']))*(?:\'\'\'|$)|\"\"\"(?:[^\"\\]|\\[\s\S]|\"{1,2}(?=[^\"]))*(?:\"\"\"|$)|\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$))/,null,"'\""])}else{if(T.multiLineStrings){W.push([C,/^(?:\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$)|\`(?:[^\\\`]|\\[\s\S])*(?:\`|$))/,null,"'\"`"])}else{W.push([C,/^(?:\'(?:[^\\\'\r\n]|\\.)*(?:\'|$)|\"(?:[^\\\"\r\n]|\\.)*(?:\"|$))/,null,"\"'"])}}if(T.verbatimStrings){S.push([C,/^@\"(?:[^\"]|\"\")*(?:\"|$)/,null])}var Y=T.hashComments;if(Y){if(T.cStyleComments){if(Y>1){W.push([j,/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,null,"#"])}else{W.push([j,/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\r\n]*)/,null,"#"])}S.push([C,/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,null])}else{W.push([j,/^#[^\r\n]*/,null,"#"])}}if(T.cStyleComments){S.push([j,/^\/\/[^\r\n]*/,null]);S.push([j,/^\/\*[\s\S]*?(?:\*\/|$)/,null])}if(T.regexLiterals){var X=("/(?=[^/*])(?:[^/\\x5B\\x5C]|\\x5C[\\s\\S]|\\x5B(?:[^\\x5C\\x5D]|\\x5C[\\s\\S])*(?:\\x5D|$))+/");S.push(["lang-regex",new RegExp("^"+M+"("+X+")")])}var V=T.types;if(V){S.push([O,V])}var U=(""+T.keywords).replace(/^ | $/g,"");if(U.length){S.push([z,new RegExp("^(?:"+U.replace(/[\s,]+/g,"|")+")\\b"),null])}W.push([F,/^\s+/,null," \r\n\t\xA0"]);S.push([G,/^@[a-z_$][a-z_$@0-9]*/i,null],[O,/^(?:[@_]?[A-Z]+[a-z][A-Za-z_$@0-9]*|\w+_t\b)/,null],[F,/^[a-z_$][a-z_$@0-9]*/i,null],[G,new RegExp("^(?:0x[a-f0-9]+|(?:\\d(?:_\\d+)*\\d*(?:\\.\\d*)?|\\.\\d\\+)(?:e[+\\-]?\\d+)?)[a-z]*","i"),null,"0123456789"],[F,/^\\[\s\S]?/,null],[L,/^.[^\s\w\.$@\'\"\`\/\#\\]*/,null]);return g(W,S)}var K=i({keywords:A,hashComments:true,cStyleComments:true,multiLineStrings:true,regexLiterals:true});function Q(V,ag){var U=/(?:^|\s)nocode(?:\s|$)/;var ab=/\r\n?|\n/;var ac=V.ownerDocument;var S;if(V.currentStyle){S=V.currentStyle.whiteSpace}else{if(window.getComputedStyle){S=ac.defaultView.getComputedStyle(V,null).getPropertyValue("white-space")}}var Z=S&&"pre"===S.substring(0,3);var af=ac.createElement("LI");while(V.firstChild){af.appendChild(V.firstChild)}var W=[af];function ae(al){switch(al.nodeType){case 1:if(U.test(al.className)){break}if("BR"===al.nodeName){ad(al);if(al.parentNode){al.parentNode.removeChild(al)}}else{for(var an=al.firstChild;an;an=an.nextSibling){ae(an)}}break;case 3:case 4:if(Z){var am=al.nodeValue;var aj=am.match(ab);if(aj){var ai=am.substring(0,aj.index);al.nodeValue=ai;var ah=am.substring(aj.index+aj[0].length);if(ah){var ak=al.parentNode;ak.insertBefore(ac.createTextNode(ah),al.nextSibling)}ad(al);if(!ai){al.parentNode.removeChild(al)}}}break}}function ad(ak){while(!ak.nextSibling){ak=ak.parentNode;if(!ak){return}}function ai(al,ar){var aq=ar?al.cloneNode(false):al;var ao=al.parentNode;if(ao){var ap=ai(ao,1);var an=al.nextSibling;ap.appendChild(aq);for(var am=an;am;am=an){an=am.nextSibling;ap.appendChild(am)}}return aq}var ah=ai(ak.nextSibling,0);for(var aj;(aj=ah.parentNode)&&aj.nodeType===1;){ah=aj}W.push(ah)}for(var Y=0;Y=S){ah+=2}if(V>=ap){Z+=2}}}var t={};function c(U,V){for(var S=V.length;--S>=0;){var T=V[S];if(!t.hasOwnProperty(T)){t[T]=U}else{if(window.console){console.warn("cannot override language handler %s",T)}}}}function q(T,S){if(!(T&&t.hasOwnProperty(T))){T=/^\s*]*(?:>|$)/],[j,/^<\!--[\s\S]*?(?:-\->|$)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],[L,/^(?:<[%?]|[%?]>)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]);c(g([[F,/^[\s]+/,null," \t\r\n"],[n,/^(?:\"[^\"]*\"?|\'[^\']*\'?)/,null,"\"'"]],[[m,/^^<\/?[a-z](?:[\w.:-]*\w)?|\/?>$/i],[P,/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^>\'\"\s]*(?:[^>\'\"\s\/]|\/(?=\s)))/],[L,/^[=<>\/]+/],["lang-js",/^on\w+\s*=\s*\"([^\"]+)\"/i],["lang-js",/^on\w+\s*=\s*\'([^\']+)\'/i],["lang-js",/^on\w+\s*=\s*([^\"\'>\s]+)/i],["lang-css",/^style\s*=\s*\"([^\"]+)\"/i],["lang-css",/^style\s*=\s*\'([^\']+)\'/i],["lang-css",/^style\s*=\s*([^\"\'>\s]+)/i]]),["in.tag"]);c(g([],[[n,/^[\s\S]+/]]),["uq.val"]);c(i({keywords:l,hashComments:true,cStyleComments:true,types:e}),["c","cc","cpp","cxx","cyc","m"]);c(i({keywords:"null,true,false"}),["json"]);c(i({keywords:R,hashComments:true,cStyleComments:true,verbatimStrings:true,types:e}),["cs"]);c(i({keywords:x,cStyleComments:true}),["java"]);c(i({keywords:H,hashComments:true,multiLineStrings:true}),["bsh","csh","sh"]);c(i({keywords:I,hashComments:true,multiLineStrings:true,tripleQuotedStrings:true}),["cv","py"]);c(i({keywords:s,hashComments:true,multiLineStrings:true,regexLiterals:true}),["perl","pl","pm"]);c(i({keywords:f,hashComments:true,multiLineStrings:true,regexLiterals:true}),["rb"]);c(i({keywords:w,cStyleComments:true,regexLiterals:true}),["js"]);c(i({keywords:r,hashComments:3,cStyleComments:true,multilineStrings:true,tripleQuotedStrings:true,regexLiterals:true}),["coffee"]);c(g([],[[C,/^[\s\S]+/]]),["regex"]);function d(V){var U=V.langExtension;try{var S=a(V.sourceNode);var T=S.sourceCode;V.sourceCode=T;V.spans=S.spans;V.basePos=0;q(U,T)(V);D(V)}catch(W){if("console" in window){console.log(W&&W.stack?W.stack:W)}}}function y(W,V,U){var S=document.createElement("PRE");S.innerHTML=W;if(U){Q(S,U)}var T={langExtension:V,numberLines:U,sourceNode:S};d(T);return S.innerHTML}function b(ad){function Y(af){return document.getElementsByTagName(af)}var ac=[Y("pre"),Y("code"),Y("xmp")];var T=[];for(var aa=0;aa=0){var ah=ai.match(ab);var am;if(!ah&&(am=o(aj))&&"CODE"===am.tagName){ah=am.className.match(ab)}if(ah){ah=ah[1]}var al=false;for(var ak=aj.parentNode;ak;ak=ak.parentNode){if((ak.tagName==="pre"||ak.tagName==="code"||ak.tagName==="xmp")&&ak.className&&ak.className.indexOf("prettyprint")>=0){al=true;break}}if(!al){var af=aj.className.match(/\blinenums\b(?::(\d+))?/);af=af?af[1]&&af[1].length?+af[1]:true:false;if(af){Q(aj,af)}S={langExtension:ah,sourceNode:aj,numberLines:af};d(S)}}}if(X]*(?:>|$)/],[PR.PR_COMMENT,/^<\!--[\s\S]*?(?:-\->|$)/],[PR.PR_PUNCTUATION,/^(?:<[%?]|[%?]>)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-handlebars",/^]*type\s*=\s*['"]?text\/x-handlebars-template['"]?\b[^>]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i],[PR.PR_DECLARATION,/^{{[#^>/]?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{&?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{{>?\s*[\w.][^}]*}}}/],[PR.PR_COMMENT,/^{{![^}]*}}/]]),["handlebars","hbs"]);PR.registerLangHandler(PR.createSimpleLexer([[PR.PR_PLAIN,/^[ \t\r\n\f]+/,null," \t\r\n\f"]],[[PR.PR_STRING,/^\"(?:[^\n\r\f\\\"]|\\(?:\r\n?|\n|\f)|\\[\s\S])*\"/,null],[PR.PR_STRING,/^\'(?:[^\n\r\f\\\']|\\(?:\r\n?|\n|\f)|\\[\s\S])*\'/,null],["lang-css-str",/^url\(([^\)\"\']*)\)/i],[PR.PR_KEYWORD,/^(?:url|rgb|\!important|@import|@page|@media|@charset|inherit)(?=[^\-\w]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|(?:\\[0-9a-f]+ ?))(?:[_a-z0-9\-]|\\(?:\\[0-9a-f]+ ?))*)\s*:/i],[PR.PR_COMMENT,/^\/\*[^*]*\*+(?:[^\/*][^*]*\*+)*\//],[PR.PR_COMMENT,/^(?:)/],[PR.PR_LITERAL,/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],[PR.PR_LITERAL,/^#(?:[0-9a-f]{3}){1,2}/i],[PR.PR_PLAIN,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i],[PR.PR_PUNCTUATION,/^[^\s\w\'\"]+/]]),["css"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_KEYWORD,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i]]),["css-kw"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_STRING,/^[^\)\"\']+/]]),["css-str"]); diff --git a/refs/pull/136/merge/coverage/lcov-report/sort-arrow-sprite.png b/refs/pull/136/merge/coverage/lcov-report/sort-arrow-sprite.png new file mode 100644 index 00000000..6ed68316 Binary files /dev/null and b/refs/pull/136/merge/coverage/lcov-report/sort-arrow-sprite.png differ diff --git a/refs/pull/136/merge/coverage/lcov-report/sorter.js b/refs/pull/136/merge/coverage/lcov-report/sorter.js new file mode 100644 index 00000000..2bb296a8 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/sorter.js @@ -0,0 +1,196 @@ +/* eslint-disable */ +var addSorting = (function() { + 'use strict'; + var cols, + currentSort = { + index: 0, + desc: false + }; + + // returns the summary table element + function getTable() { + return document.querySelector('.coverage-summary'); + } + // returns the thead element of the summary table + function getTableHeader() { + return getTable().querySelector('thead tr'); + } + // returns the tbody element of the summary table + function getTableBody() { + return getTable().querySelector('tbody'); + } + // returns the th element for nth column + function getNthColumn(n) { + return getTableHeader().querySelectorAll('th')[n]; + } + + function onFilterInput() { + const searchValue = document.getElementById('fileSearch').value; + const rows = document.getElementsByTagName('tbody')[0].children; + for (let i = 0; i < rows.length; i++) { + const row = rows[i]; + if ( + row.textContent + .toLowerCase() + .includes(searchValue.toLowerCase()) + ) { + row.style.display = ''; + } else { + row.style.display = 'none'; + } + } + } + + // loads the search box + function addSearchBox() { + var template = document.getElementById('filterTemplate'); + var templateClone = template.content.cloneNode(true); + templateClone.getElementById('fileSearch').oninput = onFilterInput; + template.parentElement.appendChild(templateClone); + } + + // loads all columns + function loadColumns() { + var colNodes = getTableHeader().querySelectorAll('th'), + colNode, + cols = [], + col, + i; + + for (i = 0; i < colNodes.length; i += 1) { + colNode = colNodes[i]; + col = { + key: colNode.getAttribute('data-col'), + sortable: !colNode.getAttribute('data-nosort'), + type: colNode.getAttribute('data-type') || 'string' + }; + cols.push(col); + if (col.sortable) { + col.defaultDescSort = col.type === 'number'; + colNode.innerHTML = + colNode.innerHTML + ''; + } + } + return cols; + } + // attaches a data attribute to every tr element with an object + // of data values keyed by column name + function loadRowData(tableRow) { + var tableCols = tableRow.querySelectorAll('td'), + colNode, + col, + data = {}, + i, + val; + for (i = 0; i < tableCols.length; i += 1) { + colNode = tableCols[i]; + col = cols[i]; + val = colNode.getAttribute('data-value'); + if (col.type === 'number') { + val = Number(val); + } + data[col.key] = val; + } + return data; + } + // loads all row data + function loadData() { + var rows = getTableBody().querySelectorAll('tr'), + i; + + for (i = 0; i < rows.length; i += 1) { + rows[i].data = loadRowData(rows[i]); + } + } + // sorts the table using the data for the ith column + function sortByIndex(index, desc) { + var key = cols[index].key, + sorter = function(a, b) { + a = a.data[key]; + b = b.data[key]; + return a < b ? -1 : a > b ? 1 : 0; + }, + finalSorter = sorter, + tableBody = document.querySelector('.coverage-summary tbody'), + rowNodes = tableBody.querySelectorAll('tr'), + rows = [], + i; + + if (desc) { + finalSorter = function(a, b) { + return -1 * sorter(a, b); + }; + } + + for (i = 0; i < rowNodes.length; i += 1) { + rows.push(rowNodes[i]); + tableBody.removeChild(rowNodes[i]); + } + + rows.sort(finalSorter); + + for (i = 0; i < rows.length; i += 1) { + tableBody.appendChild(rows[i]); + } + } + // removes sort indicators for current column being sorted + function removeSortIndicators() { + var col = getNthColumn(currentSort.index), + cls = col.className; + + cls = cls.replace(/ sorted$/, '').replace(/ sorted-desc$/, ''); + col.className = cls; + } + // adds sort indicators for current column being sorted + function addSortIndicators() { + getNthColumn(currentSort.index).className += currentSort.desc + ? ' sorted-desc' + : ' sorted'; + } + // adds event listeners for all sorter widgets + function enableUI() { + var i, + el, + ithSorter = function ithSorter(i) { + var col = cols[i]; + + return function() { + var desc = col.defaultDescSort; + + if (currentSort.index === i) { + desc = !currentSort.desc; + } + sortByIndex(i, desc); + removeSortIndicators(); + currentSort.index = i; + currentSort.desc = desc; + addSortIndicators(); + }; + }; + for (i = 0; i < cols.length; i += 1) { + if (cols[i].sortable) { + // add the click event handler on the th so users + // dont have to click on those tiny arrows + el = getNthColumn(i).querySelector('.sorter').parentElement; + if (el.addEventListener) { + el.addEventListener('click', ithSorter(i)); + } else { + el.attachEvent('onclick', ithSorter(i)); + } + } + } + } + // adds sorting functionality to the UI + return function() { + if (!getTable()) { + return; + } + cols = loadColumns(); + loadData(); + addSearchBox(); + addSortIndicators(); + enableUI(); + }; +})(); + +window.addEventListener('load', addSorting); diff --git a/refs/pull/136/merge/coverage/lcov-report/src/components/DateModified.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/components/DateModified.tsx.html new file mode 100644 index 00000000..a702223e --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/components/DateModified.tsx.html @@ -0,0 +1,175 @@ + + + + + + Code coverage report for src/components/DateModified.tsx + + + + + + + + + +
+
+

All files / src/components DateModified.tsx

+
+ +
+ 100% + Statements + 3/3 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 100% + Lines + 3/3 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31  +  +  +  +  +  +  +  +  +  +  +  +  +4x +6x +  +  +  +  +  +  +  +  +  +4x +  +  +  +  +  + 
import React from 'react'
+ 
+export interface DateModifiedProps {
+  // text to be displayed
+  text?: string
+ 
+  // id of the element for testing if needed
+  id?: string
+}
+ 
+/**
+ * Contains build time stamp
+ */
+const DateModified: React.FC<DateModifiedProps> = ({ id, text }) => {
+  return (
+    <dl id={id} className="container mx-auto py-8 px-4">
+      <dt className="inline mr-1">{text}</dt>
+      <dd className="inline ml-1">
+        <time>{process.env.NEXT_PUBLIC_BUILD_DATE}</time>
+      </dd>
+    </dl>
+  )
+}
+ 
+DateModified.defaultProps = {
+  id: 'date-modified',
+  text: 'Date Modified:',
+}
+ 
+export default DateModified
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/components/Footer.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/components/Footer.tsx.html new file mode 100644 index 00000000..1013996e --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/components/Footer.tsx.html @@ -0,0 +1,394 @@ + + + + + + Code coverage report for src/components/Footer.tsx + + + + + + + + + +
+
+

All files / src/components Footer.tsx

+
+ +
+ 100% + Statements + 5/5 +
+ + +
+ 100% + Branches + 2/2 +
+ + +
+ 100% + Functions + 3/3 +
+ + +
+ 100% + Lines + 5/5 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +3x +5x +5x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +38x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +24x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import React from 'react'
+import DateModified from './DateModified'
+import { useTranslation } from 'next-i18next'
+ 
+interface FooterProps {
+  footerNav1: string
+  footerNav2: string
+  footerBoxLinks: {
+    footerBoxlink: string
+    footerBoxLinkText: string
+  }[]
+  links: {
+    link: string
+    linkText: string
+  }[]
+  footerLogoAltText: string
+  footerLogoImage: string
+}
+ 
+/**
+ * footer element for all pages
+ */
+const Footer: React.FC<FooterProps> = (props) => {
+  const { t } = useTranslation('common')
+  return (
+    <footer>
+      <h2 className="sr-only">siteFooter</h2>
+      <div className="container mx-auto px-6 mt-5">{t('reportProblem')}</div>
+      <DateModified text={t('dateModified')} />
+      <div className="w-full">
+        <div className="w-full h-auto bg-footer-parliament-image bg-no-repeat bg-right-bottom bg-[#173451]">
+          <div
+            className="py-7 container mx-auto px-6"
+            role="navigation"
+            aria-labelledby="footerNav1"
+          >
+            <h3 className="sr-only" id="footerNav1">
+              {props.footerNav1}
+            </h3>
+            <ul className="flex flex-col text-sm sm:grid sm:grid-cols-2 xl:grid xl:grid-cols-3 sm:gap-1">
+              {props.footerBoxLinks.map((value, index) => {
+                return (
+                  <li
+                    key={index}
+                    className="text-white w-64 md:w-56 lg:w-80 my-2.5 hover:underline"
+                  >
+                    <a className="font-body" href={value.footerBoxlink}>
+                      {value.footerBoxLinkText}
+                    </a>
+                  </li>
+                )
+              })}
+            </ul>
+          </div>
+        </div>
+        <div className="w-full h-full pb-4">
+          <div className="h-auto pt-5 container mx-auto px-6 flex flex-col xl:flex xl:flex-row md:justify-between">
+            <div
+              className="mt-3.5 xl:mt-5"
+              role="navigation"
+              aria-labelledby="footerNav2"
+            >
+              <h3 className="sr-only" id="footerNav2">
+                {props.footerNav2}
+              </h3>
+              <ul className="flex flex-col md:grid md:grid-cols-2 xl:flex lg:flex-row">
+                {props.links.map((value, index) => {
+                  return (
+                    <li
+                      key={index}
+                      className={
+                        index === 0
+                          ? 'lg:mb-4 mb-5 mr-2.5 list-inside list-disc xl:list-none text-sm'
+                          : 'lg:mb-4 mb-5 mr-2.5 list-inside list-disc text-sm'
+                      }
+                    >
+                      <a
+                        className="text-sm font-body text-[#21303F] hover:text-[#5E8EBD]"
+                        data-cy="social-media-link"
+                        href={value.link}
+                      >
+                        {value.linkText}
+                      </a>
+                    </li>
+                  )
+                })}
+              </ul>
+            </div>
+            <div>
+              <img
+                className="mb-2.5 mt-8 xl:mt-0 h-6 md:h-10 w-auto float-right"
+                src={props.footerLogoImage}
+                alt={props.footerLogoAltText}
+              />
+            </div>
+          </div>
+        </div>
+      </div>
+    </footer>
+  )
+}
+ 
+export default Footer
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/components/Header.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/components/Header.tsx.html new file mode 100644 index 00000000..e7a2b920 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/components/Header.tsx.html @@ -0,0 +1,328 @@ + + + + + + Code coverage report for src/components/Header.tsx + + + + + + + + + +
+
+

All files / src/components Header.tsx

+
+ +
+ 100% + Statements + 3/3 +
+ + +
+ 100% + Branches + 20/20 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 100% + Lines + 3/3 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82  +  +  +  +  +  +  +  +  +3x +6x +6x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import React from 'react'
+import Link from 'next/link'
+import { useTranslation } from 'next-i18next'
+ 
+interface HeaderProps {
+  language: string
+  langToggleLink?: string
+}
+ 
+const Header: React.FC<HeaderProps> = (props) => {
+  const { t } = useTranslation('common')
+  return (
+    <>
+      <nav
+        role="navigation"
+        aria-label={t('skipToMainContent')}
+        className="absolute w-px h-px -left-96 focus-within:w-screen focus-within:h-auto focus-within:top-4 focus-within:z-50 focus-within:flex focus-within:justify-center"
+      >
+        <a
+          id="skipToMainContent"
+          className="bg-blue-800 text-white px-2 focus:outline-black-solid hover:bg-gray-dark"
+          href="#homeContent"
+          draggable={false}
+        >
+          {t('skipToMainContent')}
+        </a>
+      </nav>
+ 
+      <header>
+        <div className="container mx-auto px-6 flex-col flex md:flex md:flex-row justify-between pt-6">
+          <div className="flex flex-row justify-between items-center lg:mt-7">
+            <a href={t('gocLink')}>
+              <img
+                className="h-5 w-auto xs:h-6 sm:h-8 md:h-8 lg:h-7 xl:h-8"
+                src={
+                  props.language === 'en'
+                    ? '/assets/sig-blk-en.svg'
+                    : '/assets/sig-blk-fr.svg'
+                }
+                alt={
+                  props.language === 'en'
+                    ? 'Government of Canada'
+                    : 'Gouvernement du Canada'
+                }
+              />
+            </a>
+ 
+            {/* Language selector for small screens */}
+            <Link
+              key={props.language}
+              href={props.langToggleLink || '/'}
+              locale={props.language === 'en' ? 'fr' : 'en'}
+              className="block md:hidden md:text-sm ml-6 pb-2 sm:ml-16 underline font-body font-bold text-[#284162] text-base hover:text-[#0535d2]"
+              lang={props.language === 'en' ? 'fr' : 'en'}
+            >
+              {props.language === 'en' ? 'FR' : 'EN'}
+            </Link>
+          </div>
+ 
+          <div className="flex-col flex">
+            {/* Language selector for mid to larger screens */}
+            <Link
+              key={props.language}
+              href={props.langToggleLink || '/'}
+              locale={props.language === 'en' ? 'fr' : 'en'}
+              className="md:block hidden pb-0 lg:pb-4 self-end underline font-body text-[#284162] hover:text-[#0535d2] "
+              data-cy="toggle-language-link"
+              lang={props.language === 'en' ? 'fr' : 'en'}
+            >
+              {props.language === 'en' ? 'Français' : 'English'}
+            </Link>
+          </div>
+        </div>
+ 
+        <div className="mb-2 border-t pb-2 mt-4"></div>
+      </header>
+    </>
+  )
+}
+ 
+export default Header
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/components/Layout.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/components/Layout.tsx.html new file mode 100644 index 00000000..47740942 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/components/Layout.tsx.html @@ -0,0 +1,388 @@ + + + + + + Code coverage report for src/components/Layout.tsx + + + + + + + + + +
+
+

All files / src/components Layout.tsx

+
+ +
+ 100% + Statements + 4/4 +
+ + +
+ 50% + Branches + 1/2 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 100% + Lines + 4/4 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102  +  +  +  +  +  +  +  +  +  +  +  +2x +4x +  +4x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +  +  +  +  + 
import React, { ReactNode } from 'react'
+import Header from './Header'
+import Footer from './Footer'
+import { useTranslation } from 'next-i18next'
+ 
+interface LayoutProps {
+  children: ReactNode
+  locale?: string
+  title?: string
+  langToggleLink?: string
+}
+ 
+const Layout: React.FC<LayoutProps> = (props) => {
+  const { t } = useTranslation('common')
+ 
+  return (
+    <>
+      <Header
+        language={props.locale ?? 'en'}
+        langToggleLink={props.langToggleLink}
+      />
+ 
+      <main>
+        <div>{props.children}</div>
+      </main>
+ 
+      <Footer
+        footerLogoAltText="symbol2"
+        footerLogoImage="/assets/wmms-blk.svg"
+        footerNav1="aboutGovernment"
+        footerNav2="aboutThisSite"
+        links={[
+          {
+            link: t('footerSocialMediaURL'),
+            linkText: t('footerSocialMedia'),
+          },
+          {
+            link: t('footerMobileAppURL'),
+            linkText: t('footerMobileApp'),
+          },
+          {
+            link: t('footerAboutURL'),
+            linkText: t('footerAbout'),
+          },
+          {
+            link: t('footerTermsAndConditionURL'),
+            linkText: t('footerTermsAndCondition'),
+          },
+          {
+            link: t('footerPrivacyURL'),
+            linkText: t('footerPrivacy'),
+          },
+        ]}
+        footerBoxLinks={[
+          {
+            footerBoxlink: t('footerContactUsURL'),
+            footerBoxLinkText: t('footerContactUs'),
+          },
+          {
+            footerBoxlink: t('footerNewsURL'),
+            footerBoxLinkText: t('footerNews'),
+          },
+          {
+            footerBoxlink: t('footerPmURL'),
+            footerBoxLinkText: t('footerPm'),
+          },
+          {
+            footerBoxlink: t('footerDepartmentAgenciesURL'),
+            footerBoxLinkText: t('footerDepartmentAgencies'),
+          },
+          {
+            footerBoxlink: t('footerTreatiesURL'),
+            footerBoxLinkText: t('footerTreaties'),
+          },
+          {
+            footerBoxlink: t('footerHowGovWorksURL'),
+            footerBoxLinkText: t('footerHowGovWorks'),
+          },
+          {
+            footerBoxlink: t('footerPublicServiceURL'),
+            footerBoxLinkText: t('footerPublicService'),
+          },
+          {
+            footerBoxlink: t('footerGovReportingURL'),
+            footerBoxLinkText: t('footerGovReporting'),
+          },
+          {
+            footerBoxlink: t('footerOpenGovURL'),
+            footerBoxLinkText: t('footerOpenGov'),
+          },
+        ]}
+      />
+    </>
+  )
+}
+ 
+Layout.defaultProps = {
+  title: 'Next Template - Canada.ca',
+}
+ 
+export default Layout
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/components/index.html b/refs/pull/136/merge/coverage/lcov-report/src/components/index.html new file mode 100644 index 00000000..b5f9cbc4 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/components/index.html @@ -0,0 +1,161 @@ + + + + + + Code coverage report for src/components + + + + + + + + + +
+
+

All files src/components

+
+ +
+ 100% + Statements + 15/15 +
+ + +
+ 95.83% + Branches + 23/24 +
+ + +
+ 100% + Functions + 6/6 +
+ + +
+ 100% + Lines + 15/15 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
DateModified.tsx +
+
100%3/3100%0/0100%1/1100%3/3
Footer.tsx +
+
100%5/5100%2/2100%3/3100%5/5
Header.tsx +
+
100%3/3100%20/20100%1/1100%3/3
Layout.tsx +
+
100%4/450%1/2100%1/1100%4/4
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/index.html b/refs/pull/136/merge/coverage/lcov-report/src/index.html new file mode 100644 index 00000000..f6de7efb --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/index.html @@ -0,0 +1,146 @@ + + + + + + Code coverage report for src + + + + + + + + + +
+
+

All files src

+
+ +
+ 0% + Statements + 0/41 +
+ + +
+ 0% + Branches + 0/26 +
+ + +
+ 0% + Functions + 0/11 +
+ + +
+ 0% + Lines + 0/41 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
instrumentation.node.ts +
+
0%0/280%0/180%0/90%0/28
instrumentation.ts +
+
0%0/20%0/20%0/10%0/2
middleware.ts +
+
0%0/110%0/60%0/10%0/11
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/instrumentation.node.ts.html b/refs/pull/136/merge/coverage/lcov-report/src/instrumentation.node.ts.html new file mode 100644 index 00000000..c6503ba3 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/instrumentation.node.ts.html @@ -0,0 +1,568 @@ + + + + + + Code coverage report for src/instrumentation.node.ts + + + + + + + + + +
+
+

All files / src instrumentation.node.ts

+
+ +
+ 0% + Statements + 0/28 +
+ + +
+ 0% + Branches + 0/18 +
+ + +
+ 0% + Functions + 0/9 +
+ + +
+ 0% + Lines + 0/28 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
/**
+ * This file initializes OpenTelemetry for the application using the @opentelemetry/sdk-node package.
+ *
+ * Two Dynatrace exporters are provided, and rely on the following (optional) environment variables:
+ *
+ * <ul>
+ *   <li>
+ *     OTEL_METRICS_ENDPOINT -- defines the Dynatrace OpenTelemetry metrics endpoint
+ *     (ex: https://example.com/e/00000000-0000-0000-0000-000000000000/api/v2/otlp/v1/metrics)
+ *   </li>
+ *   <li>
+ *   - OTEL_TRACES_ENDPOINT -- defines the Dynatrace Opentelemetry traces endpoint
+ *     (ex: https://example.com/e/00000000-0000-0000-0000-000000000000/api/v2/otlp/v1/traces)
+ *   </li>
+ *   <li>
+ *   - OTEL_API_KEY -- defines the Dynatrace API key used by the metrics and traces endpoint
+ *   </li>
+ * </ul>
+ *
+ * If either Dynatrace endpoint is not provided, a NOOP metrics and/or a NOOP traces exporter will be configured.
+ *
+ * NOTE: to ensure that tracing is fully initialized, NodeSDK must be initialized early during runtime.
+ * For Next.js, this can be done by importing this file in next.config.js.
+ *
+ * NOTE: because of limitations in the Next.js runtimes, metrics cannot be emitted from middleware.
+ *
+ * References:
+ *
+ * <ul>
+ *   <li>https://www.npmjs.com/package/@opentelemetry/sdk-node</li>
+ *   <li>https://www.dynatrace.com/support/help/extend-dynatrace/opentelemetry</li>
+ *   <li>https://nextjs.org/docs/api-reference/edge-runtime</li>
+ * </ul>
+ */
+import { ExportResultCode } from '@opentelemetry/core'
+import { OTLPMetricExporter } from '@opentelemetry/exporter-metrics-otlp-proto'
+import { OTLPTraceExporter } from '@opentelemetry/exporter-trace-otlp-proto'
+import { CompressionAlgorithm } from '@opentelemetry/otlp-exporter-base'
+import {
+  Resource,
+  envDetector,
+  hostDetector,
+  osDetector,
+  processDetector,
+} from '@opentelemetry/resources'
+import {
+  AggregationTemporality,
+  PeriodicExportingMetricReader,
+  PushMetricExporter,
+} from '@opentelemetry/sdk-metrics'
+import { NodeSDK } from '@opentelemetry/sdk-node'
+import { SpanExporter } from '@opentelemetry/sdk-trace-base'
+import { SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'
+ 
+import { getLogger } from './logging/log-util'
+ 
+const logger = getLogger('instrumentation.node')
+ 
+const getMetricExporter = (): PushMetricExporter => {
+  const exportMetrics = process.env.OTEL_METRICS_ENDPOINT
+ 
+  if (exportMetrics) {
+    if (!process.env.OTEL_API_KEY) {
+      throw new Error(
+        'OTEL_API_KEY must be configured when OTEL_METRICS_ENDPOINT is set',
+      )
+    }
+ 
+    logger.info(
+      `Exporting metrics to ${
+        process.env.OTEL_METRICS_ENDPOINT
+      } every ${getMetricExportInterval()} ms`,
+    )
+ 
+    return new OTLPMetricExporter({
+      compression: CompressionAlgorithm.GZIP,
+      headers: { Authorization: `Api-Token ${process.env.OTEL_API_KEY}` },
+      temporalityPreference: AggregationTemporality.DELTA,
+      url: process.env.OTEL_METRICS_ENDPOINT,
+    })
+  }
+ 
+  logger.info(
+    'Metrics exporting is disabled; set OTEL_METRICS_ENDPOINT to enable.',
+  )
+ 
+  return {
+    // a no-op PushMetricExporter implementation
+    export: (metrics, resultCallback) =>
+      resultCallback({ code: ExportResultCode.SUCCESS }),
+    forceFlush: async () => {},
+    shutdown: async () => {},
+  }
+}
+ 
+const getMetricExportInterval = () => {
+  return parseInt(process.env.OTEL_METRICS_EXPORT_INTERVAL_MILLIS ?? '60000')
+}
+ 
+const getMetricTimeout = () => {
+  return parseInt(process.env.OTEL_METRICS_EXPORT_TIMEOUT_MILLIS ?? '30000')
+}
+ 
+const getTraceExporter = (): SpanExporter => {
+  const exportTraces = process.env.OTEL_TRACES_ENDPOINT
+ 
+  if (exportTraces) {
+    if (!process.env.OTEL_API_KEY) {
+      throw new Error(
+        'OTEL_API_KEY must be configured when OTEL_TRACES_ENDPOINT is set',
+      )
+    }
+ 
+    logger.info(
+      `Exporting traces to ${process.env.OTEL_TRACES_ENDPOINT} every 30000 ms`,
+    )
+ 
+    return new OTLPTraceExporter({
+      compression: CompressionAlgorithm.GZIP,
+      headers: { Authorization: `Api-Token ${process.env.OTEL_API_KEY}` },
+      url: process.env.OTEL_TRACES_ENDPOINT,
+    })
+  }
+ 
+  logger.info(
+    'Traces exporting is disabled; set OTEL_TRACES_ENDPOINT to enable.',
+  )
+ 
+  return {
+    // a no-op SpanExporter implementation
+    export: (spans, resultCallback) =>
+      resultCallback({ code: ExportResultCode.SUCCESS }),
+    shutdown: async () => {},
+  }
+}
+ 
+logger.info(`Initializing OpenTelemetry SDK...`)
+ 
+const sdk = new NodeSDK({
+  metricReader: new PeriodicExportingMetricReader({
+    exporter: getMetricExporter(),
+    exportIntervalMillis: getMetricExportInterval(),
+    exportTimeoutMillis: getMetricTimeout(),
+  }),
+  resource: new Resource({
+    // Note: any attributes added here must be configured in Dynatrace under
+    // Settings → Metrics → OpenTelemetry metrics → Allow list: resource and scope attributes
+    //
+    // see: node_modules/@opentelemetry/semantic-conventions/build/src/resource/SemanticResourceAttributes.js
+    // see: node_modules/@opentelemetry/semantic-conventions/build/src/trace/SemanticResourceAttributes.js
+    [SemanticResourceAttributes.DEPLOYMENT_ENVIRONMENT]:
+      process.env.OTEL_ENVIRONMENT ?? 'local',
+    [SemanticResourceAttributes.SERVICE_NAME]:
+      process.env.OTEL_SERVICE_NAME ?? 'next-template',
+    [SemanticResourceAttributes.SERVICE_VERSION]:
+      process.env.BUILD_VERSION ?? '00000000-0000-00000000',
+  }),
+  resourceDetectors: [envDetector, hostDetector, osDetector, processDetector],
+  traceExporter: getTraceExporter(),
+})
+sdk.start()
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/instrumentation.ts.html b/refs/pull/136/merge/coverage/lcov-report/src/instrumentation.ts.html new file mode 100644 index 00000000..cedb8fe2 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/instrumentation.ts.html @@ -0,0 +1,100 @@ + + + + + + Code coverage report for src/instrumentation.ts + + + + + + + + + +
+
+

All files / src instrumentation.ts

+
+ +
+ 0% + Statements + 0/2 +
+ + +
+ 0% + Branches + 0/2 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/2 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6  +  +  +  +  + 
export async function register() {
+  if (process.env.NEXT_RUNTIME === 'nodejs') {
+    await import('./instrumentation.node')
+  }
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/lib/cms.ts.html b/refs/pull/136/merge/coverage/lcov-report/src/lib/cms.ts.html new file mode 100644 index 00000000..c8cfdeb3 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/lib/cms.ts.html @@ -0,0 +1,118 @@ + + + + + + Code coverage report for src/lib/cms.ts + + + + + + + + + +
+
+

All files / src/lib cms.ts

+
+ +
+ 100% + Statements + 4/4 +
+ + +
+ 50% + Branches + 1/2 +
+ + +
+ 100% + Functions + 2/2 +
+ + +
+ 100% + Lines + 4/4 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12  +1x +1x +  +  +  +1x +  +  +1x +  + 
export async function fetchContent() {
+  const res = undefined
+  return res ? res : exampleResponse()
+}
+ 
+async function exampleResponse() {
+  console.log(
+    'Please replace this example response with a CMS call and error handling',
+  )
+  return { header: 'Hello World!', paragraph: 'Add your content here' }
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/lib/index.html b/refs/pull/136/merge/coverage/lcov-report/src/lib/index.html new file mode 100644 index 00000000..0730e328 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/lib/index.html @@ -0,0 +1,116 @@ + + + + + + Code coverage report for src/lib + + + + + + + + + +
+
+

All files src/lib

+
+ +
+ 100% + Statements + 4/4 +
+ + +
+ 50% + Branches + 1/2 +
+ + +
+ 100% + Functions + 2/2 +
+ + +
+ 100% + Lines + 4/4 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
cms.ts +
+
100%4/450%1/2100%2/2100%4/4
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/logging/index.html b/refs/pull/136/merge/coverage/lcov-report/src/logging/index.html new file mode 100644 index 00000000..ddb77687 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/logging/index.html @@ -0,0 +1,131 @@ + + + + + + Code coverage report for src/logging + + + + + + + + + +
+
+

All files src/logging

+
+ +
+ 0% + Statements + 0/4 +
+ + +
+ 0% + Branches + 0/3 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/4 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
log-level.ts +
+
0%0/1100%0/0100%0/00%0/1
log-util.ts +
+
0%0/30%0/30%0/20%0/3
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/logging/log-level.ts.html b/refs/pull/136/merge/coverage/lcov-report/src/logging/log-level.ts.html new file mode 100644 index 00000000..08fc704d --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/logging/log-level.ts.html @@ -0,0 +1,106 @@ + + + + + + Code coverage report for src/logging/log-level.ts + + + + + + + + + +
+
+

All files / src/logging log-level.ts

+
+ +
+ 0% + Statements + 0/1 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 0/0 +
+ + +
+ 0% + Lines + 0/1 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8  +  +  +  +  +  +  + 
const logLevelData = {
+  '*': 'silent',
+  'middleware': 'trace',
+  'home': 'info',
+}
+ 
+export default logLevelData
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/logging/log-util.ts.html b/refs/pull/136/merge/coverage/lcov-report/src/logging/log-util.ts.html new file mode 100644 index 00000000..4d14bc5d --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/logging/log-util.ts.html @@ -0,0 +1,121 @@ + + + + + + Code coverage report for src/logging/log-util.ts + + + + + + + + + +
+
+

All files / src/logging log-util.ts

+
+ +
+ 0% + Statements + 0/3 +
+ + +
+ 0% + Branches + 0/3 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/3 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13  +  +  +  +  +  +  +  +  +  +  +  + 
import logLevelData from './log-level'
+import pino, { Logger } from 'pino'
+ 
+const logLevels = new Map<string, string>(Object.entries(logLevelData))
+ 
+export function getLogLevel(logger: string): string {
+  return logLevels.get(logger) || logLevels.get('*') || 'info'
+}
+ 
+export function getLogger(name: string): Logger {
+  return pino({ name, level: getLogLevel(name) })
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/middleware.ts.html b/refs/pull/136/merge/coverage/lcov-report/src/middleware.ts.html new file mode 100644 index 00000000..aeac0b34 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/middleware.ts.html @@ -0,0 +1,172 @@ + + + + + + Code coverage report for src/middleware.ts + + + + + + + + + +
+
+

All files / src middleware.ts

+
+ +
+ 0% + Statements + 0/11 +
+ + +
+ 0% + Branches + 0/6 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/11 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { NextRequest, NextResponse } from 'next/server'
+import { getLogger } from './logging/log-util'
+ 
+export function middleware(req: NextRequest) {
+  const { nextUrl, url } = req
+  const { locale, pathname } = nextUrl
+  const logger = getLogger('middleware')
+ 
+  if (
+    new RegExp('^/((api|_next/static|_next/image|assets|favicon.ico))').test(
+      pathname,
+    )
+  ) {
+    return NextResponse.next()
+  }
+ 
+  logger.trace(`Incoming request for [${url}]`)
+ 
+  if (locale === '' && pathname !== '/') {
+    logger.trace(
+      `Requested path [${pathname}] does not include required locale of [en|fr]`,
+    )
+ 
+    req.nextUrl.pathname = '/404'
+    return NextResponse.rewrite(req.nextUrl, { status: 404 })
+  }
+ 
+  return NextResponse.next()
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/404.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/404.tsx.html new file mode 100644 index 00000000..6345460e --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/404.tsx.html @@ -0,0 +1,283 @@ + + + + + + Code coverage report for src/pages/404.tsx + + + + + + + + + +
+
+

All files / src/pages 404.tsx

+
+ +
+ 66.66% + Statements + 2/3 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 50% + Functions + 1/2 +
+ + +
+ 66.66% + Lines + 2/3 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67  +  +  +  +  +  +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +  +  + 
import Link from 'next/link'
+import React from 'react'
+import { NextPage } from 'next'
+import { NextSeo } from 'next-seo'
+ 
+export default function Custom404() {
+  return (
+    <>
+      <NextSeo title="Error 404 | Erreur 404" />
+      <div className="grid md:grid-cols-2 sm:grid-cols-1 items-center justify-center md:h-96 sm:h-screen my-2 gap-5">
+        <div className="px-20">
+          <h1 className="text-2xl">We couldn't find that Web page</h1>
+          <h2>An error 404 occured on server</h2>
+          <p>
+            We're sorry you ended up here. Sometimes a page gets moved or
+            deleted, but hopefully we can help you find what you're looking for.
+            What next?
+          </p>
+          <p>
+            <span>Return to the </span>
+            <Link href="/" className="text-cyan-600 underline">
+              home page
+            </Link>
+          </p>
+          <p>
+            <Link
+              href="https://www.canada.ca/en/contact.html"
+              className="text-cyan-600 underline"
+            >
+              Contact us
+            </Link>
+            <span> and we'll help you out</span>
+          </p>
+        </div>
+        <div className="px-20">
+          <h1 className="text-2xl">Nous ne pouvons trouver cette page Web</h1>
+          <h2>Erreur 404</h2>
+          <p>
+            Nous sommes désolés que vous ayez abouti ici. Il arrive parfois
+            qu'une page ait été déplacée ou supprimée. Heureusement, nous
+            pouvons vous aider à trouver ce que vous cherchez. Que faire?
+          </p>
+          <p>
+            <span>Retournez à la </span>
+            <Link href="/" className="text-cyan-600 underline">
+              page d'accueil
+            </Link>
+          </p>
+          <p>
+            <Link
+              href="https://www.canada.ca/en/contact.html"
+              className="text-cyan-600 underline"
+            >
+              Communiquez avec nous
+            </Link>
+            <span> pour obtenir de l'aide.</span>
+          </p>
+        </div>
+      </div>
+    </>
+  )
+}
+ 
+Custom404.getLayout = function PageLayout(page: NextPage) {
+  return <>{page}</>
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/_app.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/_app.tsx.html new file mode 100644 index 00000000..e37d2078 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/_app.tsx.html @@ -0,0 +1,199 @@ + + + + + + Code coverage report for src/pages/_app.tsx + + + + + + + + + +
+
+

All files / src/pages _app.tsx

+
+ +
+ 75% + Statements + 3/4 +
+ + +
+ 50% + Branches + 1/2 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 75% + Lines + 3/4 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +1x +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import '../styles/globals.css'
+import Layout from '../components/Layout'
+import { AppProps } from 'next/app'
+import React, { ComponentType, ReactElement, ReactNode } from 'react'
+import { NextPage } from 'next'
+import { appWithTranslation } from 'next-i18next'
+import Head from 'next/head'
+ 
+type Page<P = {}> = NextPage<P> & {
+  getLayout?: (page: ReactElement) => ReactNode
+  layout?: ComponentType
+}
+ 
+type Props = AppProps & {
+  Component: Page
+}
+ 
+const App = ({ Component, pageProps }: Props) => {
+  Eif (Component.getLayout) {
+    return Component.getLayout(<Component {...pageProps} />)
+  }
+ 
+  return (
+    <>
+      <Head>
+        <meta name="viewport" content="width=device-width, initial-scale=1" />
+      </Head>
+      <Layout
+        locale={pageProps.locale}
+        langToggleLink={pageProps.langToggleLink}
+      >
+        <Component {...pageProps} />
+      </Layout>
+    </>
+  )
+}
+ 
+export default appWithTranslation(App)
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/_document.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/_document.tsx.html new file mode 100644 index 00000000..d58037a1 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/_document.tsx.html @@ -0,0 +1,166 @@ + + + + + + Code coverage report for src/pages/_document.tsx + + + + + + + + + +
+
+

All files / src/pages _document.tsx

+
+ +
+ 0% + Statements + 0/2 +
+ + +
+ 0% + Branches + 0/2 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/2 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { Html, Head, Main, NextScript } from 'next/document'
+ 
+interface DocumentProps {
+  locale?: string
+}
+ 
+export default function Document({ locale }: DocumentProps) {
+  const lang = locale ?? 'en'
+  return (
+    <Html lang={lang}>
+      <Head>
+        <meta charSet="utf-8" />
+        <link rel="icon" href="/assets/favicon.ico" />
+        <link rel="preconnect" href="https://fonts.googleapis.com" />
+        <link rel="preconnect" href="https://fonts.gstatic.com" />
+        <link
+          href="https://fonts.googleapis.com/css2?family=Lato:ital,wght@0,100;0,300;0,400;0,700;0,900;1,100;1,300;1,400;1,700;1,900&display=swap"
+          rel="stylesheet"
+        />
+      </Head>
+      <body>
+        <Main />
+        <NextScript />
+      </body>
+    </Html>
+  )
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/_error.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/_error.tsx.html new file mode 100644 index 00000000..24366eb5 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/_error.tsx.html @@ -0,0 +1,325 @@ + + + + + + Code coverage report for src/pages/_error.tsx + + + + + + + + + +
+
+

All files / src/pages _error.tsx

+
+ +
+ 50% + Statements + 3/6 +
+ + +
+ 50% + Branches + 4/8 +
+ + +
+ 33.33% + Functions + 1/3 +
+ + +
+ 50% + Lines + 3/6 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81  +  +  +  +  +  +  +  +  +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +  +  +  +1x +  +  +  +  +  + 
import Link from 'next/link'
+import React from 'react'
+import { NextPage, NextPageContext } from 'next'
+ 
+interface ErrorProps {
+  statusCode?: number
+}
+ 
+export function CustomError({ statusCode }: ErrorProps) {
+  return (
+    <div className="grid md:grid-cols-2 sm:grid-cols-1 items-center justify-center md:h-96 sm:h-screen my-2 gap-5">
+      <div className="px-20">
+        <h1 className="text-2xl">We couldn't find that Web page</h1>
+        <h2>
+          {statusCode
+            ? `An error ${statusCode} occurred on server`
+            : 'An error occurred on client'}
+        </h2>
+        <p>
+          We're sorry you ended up here. Sometimes a page gets moved or deleted,
+          but hopefully we can help you find what you're looking for. What next?
+        </p>
+        <p>
+          <span>Return to the </span>
+          <Link href="/" className="text-cyan-600 underline">
+            home page
+          </Link>
+        </p>
+        <p>
+          <Link
+            href="https://www.canada.ca/en/contact.html"
+            className="text-cyan-600 underline"
+          >
+            Contact us
+          </Link>
+          <span> and we'll help you out</span>
+        </p>
+      </div>
+      <div className="px-20">
+        <h1 className="text-2xl">Nous ne pouvons trouver cette page Web</h1>
+        <h2>
+          {statusCode
+            ? `Erreur ${statusCode}`
+            : 'Erreur produite sur le client'}
+        </h2>
+        <p>
+          Nous sommes désolés que vous ayez abouti ici. Il arrive parfois qu'une
+          page ait été déplacée ou supprimée. Heureusement, nous pouvons vous
+          aider à trouver ce que vous cherchez. Que faire?
+        </p>
+        <p>
+          <span>Retournez à la </span>
+          <Link href="/" className="text-cyan-600 underline">
+            page d'accueil
+          </Link>
+        </p>
+        <p>
+          <Link
+            href="https://www.canada.ca/en/contact.html"
+            className="text-cyan-600 underline"
+          >
+            Communiquez avec nous
+          </Link>
+          <span> pour obtenir de l'aide.</span>
+        </p>
+      </div>
+    </div>
+  )
+}
+ 
+CustomError.getLayout = function PageLayout(page: NextPage) {
+  return <>{page}</>
+}
+ 
+CustomError.getInitialProps = ({ res, err }: NextPageContext) => {
+  const statusCode = res ? res.statusCode : err ? err.statusCode : 404
+  return { statusCode }
+}
+ 
+export default CustomError
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/api/envAPIExample.ts.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/api/envAPIExample.ts.html new file mode 100644 index 00000000..84ecb709 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/api/envAPIExample.ts.html @@ -0,0 +1,100 @@ + + + + + + Code coverage report for src/pages/api/envAPIExample.ts + + + + + + + + + +
+
+

All files / src/pages/api envAPIExample.ts

+
+ +
+ 0% + Statements + 0/1 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/1 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6  +  +  +  +  + 
import { NextApiRequest, NextApiResponse } from 'next'
+ 
+export default function handler(req: NextApiRequest, res: NextApiResponse) {
+  res.status(200).json({ apiEnv: process.env.ENV_EXAMPLE })
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/api/index.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/api/index.html new file mode 100644 index 00000000..4d312361 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/api/index.html @@ -0,0 +1,131 @@ + + + + + + Code coverage report for src/pages/api + + + + + + + + + +
+
+

All files src/pages/api

+
+ +
+ 0% + Statements + 0/1 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/1 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
envAPIExample.ts +
+
0%0/1100%0/00%0/10%0/1
metrics.ts +
+
0%0/00%0/00%0/00%0/0
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/api/metrics.ts.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/api/metrics.ts.html new file mode 100644 index 00000000..36c49ae6 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/api/metrics.ts.html @@ -0,0 +1,118 @@ + + + + + + Code coverage report for src/pages/api/metrics.ts + + + + + + + + + +
+
+

All files / src/pages/api metrics.ts

+
+ +
+ 0% + Statements + 0/0 +
+ + +
+ 0% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/0 +
+ + +
+ 0% + Lines + 0/0 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12  +  +  +  +  +  +  +  +  +  +  + 
import { register, collectDefaultMetrics } from 'prom-client'
+import { NextApiRequest, NextApiResponse } from 'next'
+ 
+/* istanbul ignore next */
+collectDefaultMetrics({ prefix: 'omnidevfrontend_' })
+ 
+/* istanbul ignore next */
+export default function handler(req: NextApiRequest, res: NextApiResponse) {
+  res.setHeader('Content-type', register.contentType)
+  res.send(register.metrics())
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/home.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/home.tsx.html new file mode 100644 index 00000000..560846a6 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/home.tsx.html @@ -0,0 +1,223 @@ + + + + + + Code coverage report for src/pages/home.tsx + + + + + + + + + +
+
+

All files / src/pages home.tsx

+
+ +
+ 100% + Statements + 5/5 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 2/2 +
+ + +
+ 100% + Lines + 5/5 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +1x +  +  +  +  +1x +  +  +  +  +  +  +  +  + 
import React from 'react'
+import { GetStaticProps } from 'next'
+import { fetchContent } from '../lib/cms'
+import { serverSideTranslations } from 'next-i18next/serverSideTranslations'
+import { NextSeo } from 'next-seo'
+import { useTranslation } from 'next-i18next'
+ 
+interface HomeProps {
+  locale: string
+  content: {
+    header: string
+    paragraph: string
+  }
+}
+ 
+export default function Home(props: HomeProps) {
+  const { t } = useTranslation(['home', 'common'])
+  return (
+    <>
+      <NextSeo title={t('title')} />
+      <div
+        id="homeContent"
+        className="container mx-auto px-6 mt-5 bg-slate-300 p-8"
+      >
+        <h1>{props.content.header}</h1>
+        <p>{props.content.paragraph}</p>
+      </div>
+    </>
+  )
+}
+ 
+export const getStaticProps: GetStaticProps = async ({ locale }) => {
+  const content = await fetchContent()
+ 
+  /* istanbul ignore next */
+  const langToggleLink = locale === 'en' ? '/fr/home' : '/home'
+ 
+  return {
+    props: {
+      ...(await serverSideTranslations(locale as string, ['common', 'home'])),
+      locale,
+      langToggleLink,
+      content,
+    },
+  }
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/index.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/index.html new file mode 100644 index 00000000..13e30b16 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/index.html @@ -0,0 +1,191 @@ + + + + + + Code coverage report for src/pages + + + + + + + + + +
+
+

All files src/pages

+
+ +
+ 69.56% + Statements + 16/23 +
+ + +
+ 41.66% + Branches + 5/12 +
+ + +
+ 63.63% + Functions + 7/11 +
+ + +
+ 69.56% + Lines + 16/23 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
404.tsx +
+
66.66%2/3100%0/050%1/266.66%2/3
_app.tsx +
+
75%3/450%1/2100%1/175%3/4
_document.tsx +
+
0%0/20%0/20%0/10%0/2
_error.tsx +
+
50%3/650%4/833.33%1/350%3/6
home.tsx +
+
100%5/5100%0/0100%2/2100%5/5
index.tsx +
+
100%3/3100%0/0100%2/2100%3/3
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov-report/src/pages/index.tsx.html b/refs/pull/136/merge/coverage/lcov-report/src/pages/index.tsx.html new file mode 100644 index 00000000..4c4f0979 --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov-report/src/pages/index.tsx.html @@ -0,0 +1,337 @@ + + + + + + Code coverage report for src/pages/index.tsx + + + + + + + + + +
+
+

All files / src/pages index.tsx

+
+ +
+ 100% + Statements + 3/3 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 2/2 +
+ + +
+ 100% + Lines + 3/3 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85  +  +  +  +  +  +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +1x +  + 
import Link from 'next/link'
+import React from 'react'
+import { NextPage } from 'next'
+import { NextSeo } from 'next-seo'
+ 
+export default function Index() {
+  return (
+    <>
+      <NextSeo title="Next Template - Canada.ca" />
+      <main
+        role="main"
+        className="container mx-auto px-6 my-5 bg-slate-300 p-12"
+      >
+        <div className="flex flex-col justify-center items-center m-auto">
+          <div className="z-10 bg-white h-auto w-[18.75rem] xl:w-[31.25rem]">
+            <h1 className="sr-only">service.canada.ca-digital-center</h1>
+            <div className="p-2">
+              <img
+                src="/assets/sig-blk-en.svg"
+                alt="Government of Canada / Gouvernement du Canada logo"
+                className="w-3/4"
+              />
+            </div>
+            <div className="flex w-max container py-11 mx-auto font-display">
+              <div className="grid grid-cols-2 gap-2 xl:gap-6">
+                <Link
+                  href="/home"
+                  className="font-display rounded focus:ring-1 focus:ring-black focus:ring-offset-2 py-2 px-10 whitespace-pre bg-[#173451] text-white text-center border border-[#173451] active:bg-[#21303F] hover:bg-#245C81 grid place-items-center"
+                  role="button"
+                  draggable="false"
+                  lang="en"
+                  id="english-button"
+                >
+                  English
+                </Link>
+                <Link
+                  href="/fr/home"
+                  className="font-display rounded focus:ring-1 focus:ring-black focus:ring-offset-2 py-2 px-10 whitespace-pre bg-[#173451] text-white text-center border border-[#173451] active:bg-[#21303F] hover:bg-#245C81 grid place-items-center"
+                  role="button"
+                  draggable="false"
+                  lang="fr"
+                  id="french-button"
+                >
+                  Français
+                </Link>
+              </div>
+            </div>
+          </div>
+ 
+          <div className="relative py-8 bg-gray-light text-p h-auto min-w-[18.75rem] w-[18.75rem] flex justify-between p-6 xl:w-[31.25rem] xl:items-center">
+            <div className="w-28 text-base xl:text-p xl:w-max font-body text-bright-blue-dark">
+              <Link
+                href="https://www.canada.ca/en/transparency/terms.html"
+                className="inline-block w-28 xl:w-max mr-0 hover:underline splash-a text-lg"
+                lang="en"
+                data-cy="terms"
+              >
+                Terms &amp; conditions
+              </Link>
+              <span> • </span>
+              <Link
+                href="https://www.canada.ca/fr/transparence/avis.html"
+                className="inline-block hover:underline font-body text-lg"
+                lang="fr"
+                data-cy="avis"
+              >
+                Avis
+              </Link>
+            </div>
+            <img
+              className="h-auto w-24 xl:w-28"
+              src="/assets/wmms-blk.svg"
+              alt=""
+            />
+          </div>
+        </div>
+      </main>
+    </>
+  )
+}
+ 
+Index.getLayout = function PageLayout(page: NextPage) {
+  return <>{page}</>
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/refs/pull/136/merge/coverage/lcov.info b/refs/pull/136/merge/coverage/lcov.info new file mode 100644 index 00000000..c1d2c0dd --- /dev/null +++ b/refs/pull/136/merge/coverage/lcov.info @@ -0,0 +1,383 @@ +TN: +SF:src/instrumentation.node.ts +FN:59,(anonymous_0) +FN:89,(anonymous_1) +FN:91,(anonymous_2) +FN:92,(anonymous_3) +FN:96,(anonymous_4) +FN:100,(anonymous_5) +FN:104,(anonymous_6) +FN:131,(anonymous_7) +FN:133,(anonymous_8) +FNF:9 +FNH:0 +FNDA:0,(anonymous_0) +FNDA:0,(anonymous_1) +FNDA:0,(anonymous_2) +FNDA:0,(anonymous_3) +FNDA:0,(anonymous_4) +FNDA:0,(anonymous_5) +FNDA:0,(anonymous_6) +FNDA:0,(anonymous_7) +FNDA:0,(anonymous_8) +DA:57,0 +DA:59,0 +DA:60,0 +DA:62,0 +DA:63,0 +DA:64,0 +DA:69,0 +DA:75,0 +DA:83,0 +DA:87,0 +DA:90,0 +DA:96,0 +DA:97,0 +DA:100,0 +DA:101,0 +DA:104,0 +DA:105,0 +DA:107,0 +DA:108,0 +DA:109,0 +DA:114,0 +DA:118,0 +DA:125,0 +DA:129,0 +DA:132,0 +DA:137,0 +DA:139,0 +DA:161,0 +LF:28 +LH:0 +BRDA:62,0,0,0 +BRDA:62,0,1,0 +BRDA:63,1,0,0 +BRDA:63,1,1,0 +BRDA:97,2,0,0 +BRDA:97,2,1,0 +BRDA:101,3,0,0 +BRDA:101,3,1,0 +BRDA:107,4,0,0 +BRDA:107,4,1,0 +BRDA:108,5,0,0 +BRDA:108,5,1,0 +BRDA:152,6,0,0 +BRDA:152,6,1,0 +BRDA:154,7,0,0 +BRDA:154,7,1,0 +BRDA:156,8,0,0 +BRDA:156,8,1,0 +BRF:18 +BRH:0 +end_of_record +TN: +SF:src/instrumentation.ts +FN:1,register +FNF:1 +FNH:0 +FNDA:0,register +DA:2,0 +DA:3,0 +LF:2 +LH:0 +BRDA:2,0,0,0 +BRDA:2,0,1,0 +BRF:2 +BRH:0 +end_of_record +TN: +SF:src/middleware.ts +FN:4,middleware +FNF:1 +FNH:0 +FNDA:0,middleware +DA:5,0 +DA:6,0 +DA:7,0 +DA:9,0 +DA:14,0 +DA:17,0 +DA:19,0 +DA:20,0 +DA:24,0 +DA:25,0 +DA:28,0 +LF:11 +LH:0 +BRDA:9,0,0,0 +BRDA:9,0,1,0 +BRDA:19,1,0,0 +BRDA:19,1,1,0 +BRDA:19,2,0,0 +BRDA:19,2,1,0 +BRF:6 +BRH:0 +end_of_record +TN: +SF:src/components/DateModified.tsx +FN:14,(anonymous_0) +FNF:1 +FNH:1 +FNDA:6,(anonymous_0) +DA:14,4 +DA:15,6 +DA:25,4 +LF:3 +LH:3 +BRF:0 +BRH:0 +end_of_record +TN: +SF:src/components/Footer.tsx +FN:23,(anonymous_0) +FN:41,(anonymous_1) +FN:67,(anonymous_2) +FNF:3 +FNH:3 +FNDA:5,(anonymous_0) +FNDA:38,(anonymous_1) +FNDA:24,(anonymous_2) +DA:23,3 +DA:24,5 +DA:25,5 +DA:42,38 +DA:68,24 +LF:5 +LH:5 +BRDA:72,0,0,5 +BRDA:72,0,1,19 +BRF:2 +BRH:2 +end_of_record +TN: +SF:src/components/Header.tsx +FN:10,(anonymous_0) +FNF:1 +FNH:1 +FNDA:6,(anonymous_0) +DA:10,3 +DA:11,6 +DA:12,6 +LF:3 +LH:3 +BRDA:36,0,0,5 +BRDA:36,0,1,1 +BRDA:41,1,0,5 +BRDA:41,1,1,1 +BRDA:51,2,0,6 +BRDA:51,2,1,6 +BRDA:52,3,0,5 +BRDA:52,3,1,1 +BRDA:54,4,0,5 +BRDA:54,4,1,1 +BRDA:56,5,0,5 +BRDA:56,5,1,1 +BRDA:64,6,0,6 +BRDA:64,6,1,6 +BRDA:65,7,0,5 +BRDA:65,7,1,1 +BRDA:68,8,0,5 +BRDA:68,8,1,1 +BRDA:70,9,0,5 +BRDA:70,9,1,1 +BRF:20 +BRH:20 +end_of_record +TN: +SF:src/components/Layout.tsx +FN:13,(anonymous_0) +FNF:1 +FNH:1 +FNDA:4,(anonymous_0) +DA:13,2 +DA:14,4 +DA:16,4 +DA:97,2 +LF:4 +LH:4 +BRDA:19,0,0,4 +BRDA:19,0,1,0 +BRF:2 +BRH:1 +end_of_record +TN: +SF:src/lib/cms.ts +FN:1,fetchContent +FN:6,exampleResponse +FNF:2 +FNH:2 +FNDA:1,fetchContent +FNDA:1,exampleResponse +DA:2,1 +DA:3,1 +DA:7,1 +DA:10,1 +LF:4 +LH:4 +BRDA:3,0,0,0 +BRDA:3,0,1,1 +BRF:2 +BRH:1 +end_of_record +TN: +SF:src/logging/log-level.ts +FNF:0 +FNH:0 +DA:1,0 +LF:1 +LH:0 +BRF:0 +BRH:0 +end_of_record +TN: +SF:src/logging/log-util.ts +FN:6,getLogLevel +FN:10,getLogger +FNF:2 +FNH:0 +FNDA:0,getLogLevel +FNDA:0,getLogger +DA:4,0 +DA:7,0 +DA:11,0 +LF:3 +LH:0 +BRDA:7,0,0,0 +BRDA:7,0,1,0 +BRDA:7,0,2,0 +BRF:3 +BRH:0 +end_of_record +TN: +SF:src/pages/404.tsx +FN:6,Custom404 +FN:64,PageLayout +FNF:2 +FNH:1 +FNDA:1,Custom404 +FNDA:0,PageLayout +DA:7,1 +DA:64,1 +DA:65,0 +LF:3 +LH:2 +BRF:0 +BRH:0 +end_of_record +TN: +SF:src/pages/_app.tsx +FN:18,(anonymous_0) +FNF:1 +FNH:1 +FNDA:1,(anonymous_0) +DA:18,1 +DA:19,1 +DA:20,1 +DA:23,0 +LF:4 +LH:3 +BRDA:19,0,0,1 +BRDA:19,0,1,0 +BRF:2 +BRH:1 +end_of_record +TN: +SF:src/pages/_document.tsx +FN:7,Document +FNF:1 +FNH:0 +FNDA:0,Document +DA:8,0 +DA:9,0 +LF:2 +LH:0 +BRDA:8,0,0,0 +BRDA:8,0,1,0 +BRF:2 +BRH:0 +end_of_record +TN: +SF:src/pages/_error.tsx +FN:9,CustomError +FN:71,PageLayout +FN:75,(anonymous_2) +FNF:3 +FNH:1 +FNDA:2,CustomError +FNDA:0,PageLayout +FNDA:0,(anonymous_2) +DA:10,2 +DA:71,1 +DA:72,0 +DA:75,1 +DA:76,0 +DA:77,0 +LF:6 +LH:3 +BRDA:15,0,0,1 +BRDA:15,0,1,1 +BRDA:42,1,0,1 +BRDA:42,1,1,1 +BRDA:76,2,0,0 +BRDA:76,2,1,0 +BRDA:76,3,0,0 +BRDA:76,3,1,0 +BRF:8 +BRH:4 +end_of_record +TN: +SF:src/pages/home.tsx +FN:16,Home +FN:32,(anonymous_1) +FNF:2 +FNH:2 +FNDA:1,Home +FNDA:1,(anonymous_1) +DA:17,1 +DA:18,1 +DA:32,1 +DA:33,1 +DA:38,1 +LF:5 +LH:5 +BRF:0 +BRH:0 +end_of_record +TN: +SF:src/pages/index.tsx +FN:6,Index +FN:82,PageLayout +FNF:2 +FNH:2 +FNDA:2,Index +FNDA:1,PageLayout +DA:7,2 +DA:82,2 +DA:83,1 +LF:3 +LH:3 +BRF:0 +BRH:0 +end_of_record +TN: +SF:src/pages/api/envAPIExample.ts +FN:3,handler +FNF:1 +FNH:0 +FNDA:0,handler +DA:4,0 +LF:1 +LH:0 +BRF:0 +BRH:0 +end_of_record +TN: +SF:src/pages/api/metrics.ts +FNF:0 +FNH:0 +LF:0 +LH:0 +BRF:0 +BRH:0 +end_of_record