Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Frontend test completed #35

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
Binary file added .DS_Store
Binary file not shown.
25 changes: 25 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
module.exports = {
env: {
browser: true,
node: true,
es6: true,
},
extends: ["eslint:recommended", "plugin:vue/essential"],
parserOptions: {
ecmaVersion: 8,
sourceType: "module",
ecmaFeatures: {
modules: true,
},
},
plugins: ["vue"],
rules: {},
overrides: [
{
files: ["**/*.spec.js", "**/*.spec.jsx"],
env: {
jest: true,
},
},
],
};
3 changes: 3 additions & 0 deletions babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module.exports = {
presets: ["@vue/cli-plugin-babel/preset"],
};
Binary file added coverage/.DS_Store
Binary file not shown.
105 changes: 105 additions & 0 deletions coverage/clover.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
<?xml version="1.0" encoding="UTF-8"?>
<coverage generated="1679250152411" clover="3.2.0">
<project timestamp="1679250152411" name="All files">
<metrics statements="51" coveredstatements="42" conditionals="11" coveredconditionals="6" methods="21" coveredmethods="19" elements="83" coveredelements="67" complexity="0" loc="51" ncloc="51" packages="5" files="11" classes="11"/>
<package name="api">
<metrics statements="12" coveredstatements="10" conditionals="0" coveredconditionals="0" methods="2" coveredmethods="2"/>
<file name="mocky.js" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/api/mocky.js">
<metrics statements="12" coveredstatements="10" conditionals="0" coveredconditionals="0" methods="2" coveredmethods="2"/>
<line num="1" count="4" type="stmt"/>
<line num="4" count="2" type="stmt"/>
<line num="5" count="2" type="stmt"/>
<line num="6" count="1" type="stmt"/>
<line num="7" count="1" type="stmt"/>
<line num="9" count="1" type="stmt"/>
<line num="12" count="1" type="stmt"/>
<line num="17" count="2" type="stmt"/>
<line num="18" count="2" type="stmt"/>
<line num="22" count="2" type="stmt"/>
<line num="24" count="0" type="stmt"/>
<line num="27" count="0" type="stmt"/>
</file>
</package>
<package name="assets">
<metrics statements="3" coveredstatements="3" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
<file name="delete.svg" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/delete.svg">
<metrics statements="1" coveredstatements="1" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
<line num="1" count="3" type="stmt"/>
</file>
<file name="fetch-document.svg" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/fetch-document.svg">
<metrics statements="1" coveredstatements="1" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
<line num="1" count="1" type="stmt"/>
</file>
<file name="upload.svg" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/upload.svg">
<metrics statements="1" coveredstatements="1" conditionals="0" coveredconditionals="0" methods="0" coveredmethods="0"/>
<line num="1" count="1" type="stmt"/>
</file>
</package>
<package name="components">
<metrics statements="7" coveredstatements="7" conditionals="3" coveredconditionals="2" methods="5" coveredmethods="5"/>
<file name="AddCardData.vue" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/AddCardData.vue">
<metrics statements="2" coveredstatements="2" conditionals="0" coveredconditionals="0" methods="1" coveredmethods="1"/>
<line num="1" count="18" type="stmt"/>
<line num="8" count="2" type="stmt"/>
</file>
<file name="CardData.vue" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CardData.vue">
<metrics statements="1" coveredstatements="1" conditionals="3" coveredconditionals="2" methods="1" coveredmethods="1"/>
<line num="1" count="52" type="cond" truecount="2" falsecount="1"/>
</file>
<file name="CustomButton.vue" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CustomButton.vue">
<metrics statements="2" coveredstatements="2" conditionals="0" coveredconditionals="0" methods="1" coveredmethods="1"/>
<line num="1" count="43" type="stmt"/>
<line num="6" count="4" type="stmt"/>
</file>
<file name="CustomCheckbox.vue" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CustomCheckbox.vue">
<metrics statements="1" coveredstatements="1" conditionals="0" coveredconditionals="0" methods="1" coveredmethods="1"/>
<line num="1" count="24" type="stmt"/>
</file>
<file name="NavigationHeader.vue" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/NavigationHeader.vue">
<metrics statements="1" coveredstatements="1" conditionals="0" coveredconditionals="0" methods="1" coveredmethods="1"/>
<line num="1" count="6" type="stmt"/>
</file>
</package>
<package name="store">
<metrics statements="28" coveredstatements="21" conditionals="6" coveredconditionals="3" methods="13" coveredmethods="11"/>
<file name="index.js" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/store/index.js">
<metrics statements="28" coveredstatements="21" conditionals="6" coveredconditionals="3" methods="13" coveredmethods="11"/>
<line num="5" count="3" type="stmt"/>
<line num="8" count="3" type="stmt"/>
<line num="14" count="3" type="stmt"/>
<line num="16" count="1" type="stmt"/>
<line num="19" count="3" type="cond" truecount="2" falsecount="0"/>
<line num="20" count="2" type="stmt"/>
<line num="26" count="1" type="stmt"/>
<line num="27" count="1" type="stmt"/>
<line num="35" count="1" type="stmt"/>
<line num="36" count="1" type="stmt"/>
<line num="39" count="1" type="stmt"/>
<line num="40" count="1" type="stmt"/>
<line num="42" count="1" type="stmt"/>
<line num="45" count="1" type="stmt"/>
<line num="46" count="1" type="stmt"/>
<line num="48" count="1" type="stmt"/>
<line num="51" count="2" type="stmt"/>
<line num="52" count="3" type="cond" truecount="1" falsecount="1"/>
<line num="54" count="2" type="stmt"/>
<line num="55" count="2" type="stmt"/>
<line num="59" count="3" type="stmt"/>
<line num="61" count="0" type="stmt"/>
<line num="62" count="0" type="stmt"/>
<line num="63" count="0" type="stmt"/>
<line num="66" count="0" type="stmt"/>
<line num="67" count="0" type="cond" truecount="0" falsecount="2"/>
<line num="68" count="0" type="stmt"/>
<line num="70" count="0" type="stmt"/>
</file>
</package>
<package name="views">
<metrics statements="1" coveredstatements="1" conditionals="2" coveredconditionals="1" methods="1" coveredmethods="1"/>
<file name="HomeView.vue" path="/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/views/HomeView.vue">
<metrics statements="1" coveredstatements="1" conditionals="2" coveredconditionals="1" methods="1" coveredmethods="1"/>
<line num="1" count="19" type="cond" truecount="1" falsecount="1"/>
</file>
</package>
</project>
</coverage>
12 changes: 12 additions & 0 deletions coverage/coverage-final.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/api/mocky.js": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/api/mocky.js","statementMap":{"0":{"start":{"line":1,"column":19},"end":{"line":1,"column":68}},"1":{"start":{"line":4,"column":2},"end":{"line":13,"column":3}},"2":{"start":{"line":5,"column":16},"end":{"line":5,"column":32}},"3":{"start":{"line":6,"column":17},"end":{"line":6,"column":33}},"4":{"start":{"line":7,"column":4},"end":{"line":7,"column":16}},"5":{"start":{"line":9,"column":4},"end":{"line":11,"column":6}},"6":{"start":{"line":12,"column":4},"end":{"line":12,"column":14}},"7":{"start":{"line":17,"column":2},"end":{"line":28,"column":3}},"8":{"start":{"line":18,"column":16},"end":{"line":21,"column":6}},"9":{"start":{"line":22,"column":4},"end":{"line":22,"column":22}},"10":{"start":{"line":24,"column":4},"end":{"line":26,"column":6}},"11":{"start":{"line":27,"column":4},"end":{"line":27,"column":24}}},"fnMap":{"0":{"name":"getMessages","decl":{"start":{"line":3,"column":22},"end":{"line":3,"column":33}},"loc":{"start":{"line":3,"column":36},"end":{"line":14,"column":1}},"line":3},"1":{"name":"uploadMessages","decl":{"start":{"line":16,"column":22},"end":{"line":16,"column":36}},"loc":{"start":{"line":16,"column":47},"end":{"line":29,"column":1}},"line":16}},"branchMap":{},"s":{"0":4,"1":2,"2":2,"3":1,"4":1,"5":1,"6":1,"7":2,"8":2,"9":2,"10":0,"11":0},"f":{"0":2,"1":2},"b":{},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"55cae5f9bfb940460bf04185453d023eb5354018"}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/delete.svg": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/delete.svg","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":19}}},"fnMap":{},"branchMap":{},"s":{"0":3},"f":{},"b":{},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"b892b32a445ec3007185a9540626348178488312"}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/fetch-document.svg": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/fetch-document.svg","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":19}}},"fnMap":{},"branchMap":{},"s":{"0":1},"f":{},"b":{},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"ccd2c08ae39700b858b707be2e82b8793b62b639"}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/upload.svg": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/assets/upload.svg","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":19}}},"fnMap":{},"branchMap":{},"s":{"0":1},"f":{},"b":{},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"fbd74f5f970dce7f37d562c753b41359f52326a2"}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/AddCardData.vue": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/AddCardData.vue","statementMap":{"0":{"start":{"line":8,"column":0},"end":{"line":24,"column":null}},"1":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}},"fnMap":{"0":{"name":"(anonymous_2)","decl":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}}},"branchMap":{},"s":{"0":2,"1":18},"f":{"0":4},"b":{}}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CardData.vue": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CardData.vue","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}}},"branchMap":{"0":{"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"type":"if","locations":[{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}]},"1":{"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"type":"cond-expr","locations":[{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}]}},"s":{"0":52},"f":{"0":16},"b":{"0":[0],"1":[10,18]}}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CustomButton.vue": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CustomButton.vue","statementMap":{"0":{"start":{"line":6,"column":0},"end":{"line":20,"column":null}},"1":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}}},"branchMap":{},"s":{"0":4,"1":43},"f":{"0":11},"b":{}}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CustomCheckbox.vue": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/CustomCheckbox.vue","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}}},"branchMap":{},"s":{"0":24},"f":{"0":6},"b":{}}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/NavigationHeader.vue": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/components/NavigationHeader.vue","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}}},"branchMap":{},"s":{"0":6},"f":{"0":1},"b":{}}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/store/index.js": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/store/index.js","statementMap":{"0":{"start":{"line":5,"column":0},"end":{"line":5,"column":14}},"1":{"start":{"line":8,"column":2},"end":{"line":11,"column":4}},"2":{"start":{"line":14,"column":25},"end":{"line":57,"column":1}},"3":{"start":{"line":16,"column":4},"end":{"line":16,"column":26}},"4":{"start":{"line":19,"column":4},"end":{"line":32,"column":5}},"5":{"start":{"line":20,"column":6},"end":{"line":24,"column":9}},"6":{"start":{"line":26,"column":20},"end":{"line":26,"column":68}},"7":{"start":{"line":27,"column":6},"end":{"line":31,"column":9}},"8":{"start":{"line":35,"column":18},"end":{"line":35,"column":74}},"9":{"start":{"line":35,"column":56},"end":{"line":35,"column":73}},"10":{"start":{"line":36,"column":4},"end":{"line":36,"column":36}},"11":{"start":{"line":39,"column":26},"end":{"line":41,"column":5}},"12":{"start":{"line":40,"column":19},"end":{"line":40,"column":36}},"13":{"start":{"line":42,"column":4},"end":{"line":42,"column":48}},"14":{"start":{"line":45,"column":26},"end":{"line":47,"column":5}},"15":{"start":{"line":46,"column":19},"end":{"line":46,"column":44}},"16":{"start":{"line":48,"column":4},"end":{"line":48,"column":47}},"17":{"start":{"line":51,"column":24},"end":{"line":53,"column":5}},"18":{"start":{"line":52,"column":19},"end":{"line":52,"column":62}},"19":{"start":{"line":54,"column":20},"end":{"line":54,"column":48}},"20":{"start":{"line":55,"column":4},"end":{"line":55,"column":32}},"21":{"start":{"line":59,"column":23},"end":{"line":75,"column":1}},"22":{"start":{"line":61,"column":17},"end":{"line":61,"column":36}},"23":{"start":{"line":62,"column":4},"end":{"line":62,"column":32}},"24":{"start":{"line":63,"column":4},"end":{"line":63,"column":29}},"25":{"start":{"line":66,"column":19},"end":{"line":66,"column":55}},"26":{"start":{"line":67,"column":4},"end":{"line":73,"column":5}},"27":{"start":{"line":68,"column":6},"end":{"line":68,"column":46}},"28":{"start":{"line":70,"column":6},"end":{"line":72,"column":8}}},"fnMap":{"0":{"name":"state","decl":{"start":{"line":7,"column":16},"end":{"line":7,"column":21}},"loc":{"start":{"line":7,"column":24},"end":{"line":12,"column":1}},"line":7},"1":{"name":"(anonymous_1)","decl":{"start":{"line":15,"column":2},"end":{"line":15,"column":3}},"loc":{"start":{"line":15,"column":27},"end":{"line":17,"column":3}},"line":15},"2":{"name":"(anonymous_2)","decl":{"start":{"line":18,"column":2},"end":{"line":18,"column":3}},"loc":{"start":{"line":18,"column":20},"end":{"line":33,"column":3}},"line":18},"3":{"name":"(anonymous_3)","decl":{"start":{"line":34,"column":2},"end":{"line":34,"column":3}},"loc":{"start":{"line":34,"column":31},"end":{"line":37,"column":3}},"line":34},"4":{"name":"(anonymous_4)","decl":{"start":{"line":35,"column":43},"end":{"line":35,"column":44}},"loc":{"start":{"line":35,"column":56},"end":{"line":35,"column":73}},"line":35},"5":{"name":"(anonymous_5)","decl":{"start":{"line":38,"column":2},"end":{"line":38,"column":3}},"loc":{"start":{"line":38,"column":43},"end":{"line":43,"column":3}},"line":38},"6":{"name":"(anonymous_6)","decl":{"start":{"line":40,"column":6},"end":{"line":40,"column":7}},"loc":{"start":{"line":40,"column":19},"end":{"line":40,"column":36}},"line":40},"7":{"name":"(anonymous_7)","decl":{"start":{"line":44,"column":2},"end":{"line":44,"column":3}},"loc":{"start":{"line":44,"column":42},"end":{"line":49,"column":3}},"line":44},"8":{"name":"(anonymous_8)","decl":{"start":{"line":46,"column":6},"end":{"line":46,"column":7}},"loc":{"start":{"line":46,"column":19},"end":{"line":46,"column":44}},"line":46},"9":{"name":"(anonymous_9)","decl":{"start":{"line":50,"column":2},"end":{"line":50,"column":3}},"loc":{"start":{"line":50,"column":24},"end":{"line":56,"column":3}},"line":50},"10":{"name":"(anonymous_10)","decl":{"start":{"line":52,"column":6},"end":{"line":52,"column":7}},"loc":{"start":{"line":52,"column":19},"end":{"line":52,"column":62}},"line":52},"11":{"name":"(anonymous_11)","decl":{"start":{"line":60,"column":2},"end":{"line":60,"column":3}},"loc":{"start":{"line":60,"column":32},"end":{"line":64,"column":3}},"line":60},"12":{"name":"(anonymous_12)","decl":{"start":{"line":65,"column":2},"end":{"line":65,"column":3}},"loc":{"start":{"line":65,"column":34},"end":{"line":74,"column":3}},"line":65}},"branchMap":{"0":{"loc":{"start":{"line":19,"column":4},"end":{"line":32,"column":5}},"type":"if","locations":[{"start":{"line":19,"column":4},"end":{"line":32,"column":5}},{"start":{"line":25,"column":11},"end":{"line":32,"column":5}}],"line":19},"1":{"loc":{"start":{"line":52,"column":19},"end":{"line":52,"column":62}},"type":"binary-expr","locations":[{"start":{"line":52,"column":19},"end":{"line":52,"column":39}},{"start":{"line":52,"column":43},"end":{"line":52,"column":62}}],"line":52},"2":{"loc":{"start":{"line":67,"column":4},"end":{"line":73,"column":5}},"type":"if","locations":[{"start":{"line":67,"column":4},"end":{"line":73,"column":5}},{"start":{"line":69,"column":11},"end":{"line":73,"column":5}}],"line":67}},"s":{"0":3,"1":3,"2":3,"3":1,"4":3,"5":2,"6":1,"7":1,"8":1,"9":1,"10":1,"11":1,"12":1,"13":1,"14":1,"15":1,"16":1,"17":2,"18":3,"19":2,"20":2,"21":3,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0},"f":{"0":3,"1":1,"2":3,"3":1,"4":1,"5":1,"6":1,"7":1,"8":1,"9":2,"10":3,"11":0,"12":0},"b":{"0":[2,1],"1":[3,0],"2":[0,0]},"_coverageSchema":"1a1c01bbd47fc00a2c39e90264f33305004495a9","hash":"e477a6ec21baaeff9f673c01ce61e9c04b40205e"}
,"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/views/HomeView.vue": {"path":"/Users/ismael/Documents/personal/frontend-challenge/unbabel-test/src/views/HomeView.vue","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}}},"branchMap":{"0":{"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"type":"cond-expr","locations":[{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},{"start":{"line":1,"column":0},"end":{"line":1,"column":null}}]}},"s":{"0":19},"f":{"0":8},"b":{"0":[4,0]}}
}
Binary file added coverage/lcov-report/.DS_Store
Binary file not shown.
Loading