Commit 41a60fbe authored by Mathew Parker's avatar Mathew Parker

initial unit tests

parent 10f3ef3e
Pipeline #95 failed with stages
in 5 minutes and 33 seconds

Too many changes to show.

To preserve performance only 1000 of 1000+ files are displayed.
node_modules/.cache/*
node_modules/.cache/
dist/*
*.swp
......@@ -26,6 +26,15 @@ lint:
paths:
- node_modules/
unit:
stage: test
script:
- echo "Running unit tests"
- yarn test:unit
artifacts:
paths:
- node_modules/
build:
stage: build
script:
......
'use strict'
const svg = jest.genMockFromModule('src/asssets/js/spatial_svg.js');
module.exports = svg;
'use strict'
const fs = jest.genMockFromModule('svg.draggy.js');
module.exports = fs;
module.exports = {
presets: [
'@vue/app'
]
],
env: {
test: {
plugins: ["transform-es2015-modules-commonjs"]
}
}
}
<?xml version="1.0" encoding="UTF-8"?>
<coverage generated="1534694138580" clover="3.2.0">
<project timestamp="1534694138580" name="All files">
<metrics statements="164" coveredstatements="0" conditionals="327" coveredconditionals="0" methods="67" coveredmethods="0" elements="558" coveredelements="0" complexity="0" loc="164" ncloc="164" packages="7" files="15" classes="15">
<package name="nodenoggin">
<metrics statements="2" coveredstatements="0" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
<file name="babel.config.js" path="/home/mparker/dev/procter/nodenoggin/babel.config.js">
<metrics statements="1" coveredstatements="0" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
<line num="1" count="0" type="stmt"/>
</file>
<file name="jest.config.js" path="/home/mparker/dev/procter/nodenoggin/jest.config.js">
<metrics statements="1" coveredstatements="0" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
<line num="1" count="0" type="stmt"/>
</file>
</package>
<package name="nodenoggin.coverage.lcov-report">
<metrics statements="105" coveredstatements="0" conditionals="321" coveredconditionals="0" methods="52" coveredmethods="0"/>
<file name="block-navigation.js" path="/home/mparker/dev/procter/nodenoggin/coverage/lcov-report/block-navigation.js">
<metrics statements="27" coveredstatements="0" conditionals="15" coveredconditionals="0" methods="6" coveredmethods="0"/>
<line num="1" count="0" type="stmt"/>
<line num="3" count="0" type="stmt"/>
<line num="6" count="0" type="stmt"/>
<line num="9" count="0" type="stmt"/>
<line num="12" count="0" type="stmt"/>
<line num="17" count="0" type="stmt"/>
<line num="18" count="0" type="stmt"/>
<line num="22" count="0" type="stmt"/>
<line num="23" count="0" type="stmt"/>
<line num="24" count="0" type="stmt"/>
<line num="29" count="0" type="stmt"/>
<line num="30" count="0" type="cond" truecount="0" falsecount="4"/>
<line num="31" count="0" type="stmt"/>
<line num="32" count="0" type="cond" truecount="0" falsecount="2"/>
<line num="33" count="0" type="stmt"/>
<line num="36" count="0" type="stmt"/>
<line num="40" count="0" type="stmt"/>
<line num="42" count="0" type="cond" truecount="0" falsecount="4"/>
<line num="43" count="0" type="stmt"/>
<line num="46" count="0" type="stmt"/>
<line num="49" count="0" type="stmt"/>
<line num="50" count="0" type="stmt"/>
<line num="53" count="0" type="stmt"/>
<line num="54" count="0" type="stmt"/>
<line num="58" count="0" type="stmt"/>
<line num="59" count="0" type="stmt"/>
<line num="63" count="0" type="stmt"/>
</file>
<file name="prettify.js" path="/home/mparker/dev/procter/nodenoggin/coverage/lcov-report/prettify.js">
<metrics statements="1" coveredstatements="0" conditionals="284" coveredconditionals="0" methods="29" coveredmethods="0"/>
<line num="1" count="0" type="cond" truecount="0" falsecount="284"/>
</file>
<file name="sorter.js" path="/home/mparker/dev/procter/nodenoggin/coverage/lcov-report/sorter.js">
<metrics statements="77" coveredstatements="0" conditionals="22" coveredconditionals="0" methods="17" coveredmethods="0"/>
<line num="1" count="0" type="stmt"/>
<line num="4" count="0" type="stmt"/>
<line num="10" count="0" type="stmt"/>
<line num="12" count="0" type="stmt"/>
<line num="14" count="0" type="stmt"/>
<line num="16" count="0" type="stmt"/>
<line num="20" count="0" type="stmt"/>
<line num="22" count="0" type="stmt"/>
<line num="26" count="0" type="stmt"/>
<line num="27" count="0" type="stmt"/>
<line num="28" count="0" type="stmt"/>
<line num="33" count="0" type="stmt"/>
<line num="34" count="0" type="cond" truecount="0" falsecount="2"/>
<line num="35" count="0" type="stmt"/>
<line num="36" count="0" type="stmt"/>
<line num="39" count="0" type="stmt"/>
<line num="44" count="0" type="stmt"/>
<line num="47" count="0" type="stmt"/>
<line num="50" count="0" type="stmt"/>
<line num="51" count="0" type="stmt"/>
<line num="52" count="0" type="stmt"/>
<line num="53" count="0" type="stmt"/>
<line num="54" count="0" type="cond" truecount="0" falsecount="2"/>
<line num="55" count="0" type="stmt"/>
<line num="57" count="0" type="stmt"/>
<line num="59" count="0" type="stmt"/>
<line num="63" count="0" type="stmt"/>
<line num="66" count="0" type="stmt"/>
<line num="67" count="0" type="stmt"/>
<line num="72" count="0" type="stmt"/>
<line num="73" count="0" type="stmt"/>
<line num="74" count="0" type="stmt"/>
<line num="75" count="0" type="stmt"/>
<line num="76" count="0" type="cond" truecount="0" falsecount="4"/>
<line num="78" count="0" type="stmt"/>
<line num="79" count="0" type="stmt"/>
<line num="80" count="0" type="stmt"/>
<line num="81" count="0" type="stmt"/>
<line num="84" count="0" type="cond" truecount="0" falsecount="2"/>
<line num="85" count="0" type="stmt"/>
<line num="86" count="0" type="stmt"/>
<line num="90" count="0" type="stmt"/>
<line num="91" count="0" type="stmt"/>
<line num="92" count="0" type="stmt"/>
<line num="95" count="0" type="stmt"/>
<line num="97" count="0" type="stmt"/>
<line num="98" count="0" type="stmt"/>
<line num="103" count="0" type="stmt"/>
<line num="104" count="0" type="stmt"/>
<line num="106" count="0" type="stmt"/>
<line num="107" count="0" type="stmt"/>
<line num="111" count="0" type="cond" truecount="0" falsecount="2"/>
<line num="117" count="0" type="stmt"/>
<line num="118" count="0" type="stmt"/>