@maka/maka-cli 5.1.9 → 5.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundle/obf/package.json +1 -1
- package/bundle/obf/src/command.js +1 -1
- package/bundle/obf/src/commands/_index.js +1 -1
- package/bundle/obf/src/commands/ai.js +1 -1
- package/bundle/obf/src/commands/aws/_index.js +1 -1
- package/bundle/obf/src/commands/aws/aws.command.js +1 -1
- package/bundle/obf/src/commands/aws/cecr.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/chz.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/ci.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/ckp.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/csg.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/decr.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/di.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/dkp.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/dsg.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/lecr.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/rbi.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/rdn.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/rkp.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/sth.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/aws/ti.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/build/_index.js +1 -1
- package/bundle/obf/src/commands/build/build.js +1 -1
- package/bundle/obf/src/commands/build/docker.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/create.js +1 -1
- package/bundle/obf/src/commands/debug.js +1 -1
- package/bundle/obf/src/commands/deploy/_index.js +1 -1
- package/bundle/obf/src/commands/deploy/deploy.command.js +1 -1
- package/bundle/obf/src/commands/deploy/galaxy.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/deploy/ubuntu.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/_index.js +1 -1
- package/bundle/obf/src/commands/game/battleship.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/play.command.js +1 -1
- package/bundle/obf/src/commands/game/pong.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/command.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/drop.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/equip.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/go.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/lock.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/look.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/say.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/search.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/solve.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/take.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/unequip.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/unlock.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/commands/use.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/factories/commandF.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/factories/roomsF.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/game.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/_index.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/door.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/inventory.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/item.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/npc.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/player.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/puzzle.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/room.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/models/scene.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/scenes/items.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/scenes/rooms.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/types/abstracts.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/types/enums.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/types/interfaces.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/types/types.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/ui.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest/utilities/logger.js +1 -1
- package/bundle/obf/src/commands/game/sideQuest.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/snake.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/game/tetris.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/generate.js +1 -1
- package/bundle/obf/src/commands/get/_index.js +1 -1
- package/bundle/obf/src/commands/get/get.command.js +1 -1
- package/bundle/obf/src/commands/get/global.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/get/local.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/get/whoami.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/help.js +1 -1
- package/bundle/obf/src/commands/install.js +1 -1
- package/bundle/obf/src/commands/jsdoc.js +1 -1
- package/bundle/obf/src/commands/lint.js +1 -1
- package/bundle/obf/src/commands/login.js +1 -1
- package/bundle/obf/src/commands/logout.js +1 -1
- package/bundle/obf/src/commands/logs.js +1 -1
- package/bundle/obf/src/commands/maka.cmd.js +1 -1
- package/bundle/obf/src/commands/murder.js +1 -1
- package/bundle/obf/src/commands/profile.js +1 -1
- package/bundle/obf/src/commands/proxy.js +1 -1
- package/bundle/obf/src/commands/reconfig.js +1 -1
- package/bundle/obf/src/commands/register.js +1 -1
- package/bundle/obf/src/commands/run/_index.js +1 -1
- package/bundle/obf/src/commands/run/docker.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/run/run.command.js +1 -1
- package/bundle/obf/src/commands/set/_index.js +1 -1
- package/bundle/obf/src/commands/set/global.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/set/local.sub.cmd.js +1 -1
- package/bundle/obf/src/commands/set/set.command.js +1 -1
- package/bundle/obf/src/commands/ssh.js +1 -1
- package/bundle/obf/src/commands/ssl.js +1 -1
- package/bundle/obf/src/commands/testCmd/_index.js +1 -0
- package/bundle/obf/src/commands/testCmd/jest.sub.cmd.js +1 -0
- package/bundle/obf/src/commands/testCmd/mocha.sub.cmd.js +1 -0
- package/bundle/obf/src/commands/testCmd/test.command.js +1 -0
- package/bundle/obf/src/commands/undo.js +1 -1
- package/bundle/obf/src/commands/version/_index.js +1 -0
- package/bundle/obf/src/commands/version/list.sub.cmd.js +1 -0
- package/bundle/obf/src/commands/version/use.sub.cmd.js +1 -0
- package/bundle/obf/src/commands/version/version.js +1 -0
- package/bundle/obf/src/error.js +1 -1
- package/bundle/obf/src/exec.js +1 -1
- package/bundle/obf/src/generator.js +1 -1
- package/bundle/obf/src/generators/_index.js +1 -1
- package/bundle/obf/src/generators/api.js +1 -1
- package/bundle/obf/src/generators/aws/_index.js +1 -1
- package/bundle/obf/src/generators/aws/aws.js +1 -1
- package/bundle/obf/src/generators/aws/cloudformation/_index.js +1 -1
- package/bundle/obf/src/generators/aws/cloudformation/cloudformation.js +1 -1
- package/bundle/obf/src/generators/aws/cloudformation/create-ec2-instance.cf.gen.js +1 -1
- package/bundle/obf/src/generators/collection.js +1 -1
- package/bundle/obf/src/generators/component.js +1 -1
- package/bundle/obf/src/generators/config.js +1 -1
- package/bundle/obf/src/generators/dbc.js +1 -1
- package/bundle/obf/src/generators/dockerfile.js +1 -1
- package/bundle/obf/src/generators/hook.js +1 -1
- package/bundle/obf/src/generators/kits/_index.js +1 -1
- package/bundle/obf/src/generators/kits/auth/_index.js +1 -1
- package/bundle/obf/src/generators/kits/auth/auth.generator.js +1 -1
- package/bundle/obf/src/generators/kits/auth/basic-meteor.auth.gen.js +1 -1
- package/bundle/obf/src/generators/kits/auth/provider.auth.gen.js +1 -1
- package/bundle/obf/src/generators/kits/esri/_index.js +1 -1
- package/bundle/obf/src/generators/kits/esri/esri.generator.js +1 -1
- package/bundle/obf/src/generators/kits/esri/map.esri.gen.js +1 -1
- package/bundle/obf/src/generators/kits/kit.js +1 -1
- package/bundle/obf/src/generators/kits/mui/_index.js +1 -1
- package/bundle/obf/src/generators/kits/mui/auth.mui.gen.js +1 -1
- package/bundle/obf/src/generators/kits/mui/frame.mui.gen.js +1 -1
- package/bundle/obf/src/generators/kits/mui/mui.generator.js +1 -1
- package/bundle/obf/src/generators/layout.js +1 -1
- package/bundle/obf/src/generators/maka.gen.js +1 -1
- package/bundle/obf/src/generators/methods.js +1 -1
- package/bundle/obf/src/generators/package.js +1 -1
- package/bundle/obf/src/generators/page.js +1 -1
- package/bundle/obf/src/generators/publish.js +1 -1
- package/bundle/obf/src/generators/route.js +1 -1
- package/bundle/obf/src/generators/service.js +1 -1
- package/bundle/obf/src/generators/services/_index.js +1 -1
- package/bundle/obf/src/generators/services/openssl.js +1 -1
- package/bundle/obf/src/generators/services/translation.js +1 -1
- package/bundle/obf/src/maka.js +1 -1
- package/bundle/obf/src/tool.js +1 -1
- package/bundle/obf/src/tools/actions/actions.class.js +1 -1
- package/bundle/obf/src/tools/aws/aws.class.js +1 -1
- package/bundle/obf/src/tools/aws/aws.interfaces.js +1 -1
- package/bundle/obf/src/tools/cfg/cfg.class.js +1 -1
- package/bundle/obf/src/tools/docker/docker.class.js +1 -1
- package/bundle/obf/src/tools/docker/docker.interfaces.js +1 -1
- package/bundle/obf/src/tools/fsi/fsi.class.js +1 -1
- package/bundle/obf/src/tools/fsi/fsi.interfaces.js +1 -1
- package/bundle/obf/src/tools/https/https.class.js +1 -1
- package/bundle/obf/src/tools/https/https.interface.js +1 -1
- package/bundle/obf/src/tools/log/log.class.js +1 -1
- package/bundle/obf/src/tools/log/log.interfaces.js +1 -1
- package/bundle/obf/src/tools/mpi/mpi.class.js +1 -1
- package/bundle/obf/src/tools/options/options.class.js +1 -1
- package/bundle/obf/src/tools/pkg/pkg.class.js +1 -1
- package/bundle/obf/src/tools/progress/progress.class.js +1 -1
- package/bundle/obf/src/tools/scaffold/scaffold.class.js +1 -1
- package/bundle/obf/src/tools/spawn-async/spawn-async.class.js +1 -1
- package/bundle/obf/src/tools/spawn-async/spawn-async.interfaces.js +1 -1
- package/bundle/obf/src/tools/ssh/ssh.class.js +1 -1
- package/bundle/obf/src/tools/ssh/ssh.interfaces.js +1 -1
- package/bundle/obf/src/tools/ssl/ssl.class.js +1 -1
- package/package.json +1 -1
- package/bundle/obf/src/commands/test/_index.js +0 -1
- package/bundle/obf/src/commands/test/jest.sub.cmd.js +0 -1
- package/bundle/obf/src/commands/test/mocha.sub.cmd.js +0 -1
- package/bundle/obf/src/commands/test/test.command.js +0 -1
- package/bundle/obf/src/commands/version.js +0 -1
- package/bundle/obf/src/templates/react/test/test.js +0 -1
- package/bundle/obf/src/templates/react/test/test.js.jsx +0 -38
- package/bundle/obf/src/templates/react/test/test.js.ts +0 -1
- package/bundle/obf/src/templates/react/test/test.js.tsx +0 -38
- package/bundle/obf/src/templates/service/test/jest/jest.config.js +0 -6
- package/bundle/obf/src/templates/service/test/jest/jest.setup.js +0 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(a,b){var f=
|
|
1
|
+
(function(a,b){var f=a167d,c=a();while(!![]){try{var d=-parseInt(f(0x148))/0x1*(parseInt(f(0x14a))/0x2)+-parseInt(f(0x14d))/0x3*(parseInt(f(0x152))/0x4)+-parseInt(f(0x14f))/0x5*(parseInt(f(0x155))/0x6)+-parseInt(f(0x14e))/0x7*(parseInt(f(0x14b))/0x8)+-parseInt(f(0x14c))/0x9+-parseInt(f(0x146))/0xa+-parseInt(f(0x149))/0xb*(-parseInt(f(0x145))/0xc);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a167c,0xa3abf));function a167d(a,b){var c=a167c();return a167d=function(d,e){d=d-0x145;var f=c[d];return f;},a167d(a,b);}var a167b=(function(){var a=!![];return function(b,c){var d=a?function(){var g=a167d;if(c){var e=c[g(0x153)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a167a=a167b(this,function(){var h=a167d;return a167a['toString']()[h(0x147)](h(0x151))[h(0x150)]()[h(0x154)](a167a)[h(0x147)](h(0x151));});a167a();function a167c(){var i=['473009vZyOIh','979kyhxSZ','2lvPvyb','263776tPcHGE','8699787meIBvr','177hUgsqZ','56wAfEvL','11745KvQBEY','toString','(((.+)+)+)+$','3988vcFxUq','apply','constructor','1758kVHQYi','528036xeZksc','7953600Eisksa','search'];a167c=function(){return i;};return a167c();}export{};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a168p=a168d;function a168d(a,b){const c=a168c();return a168d=function(d,e){d=d-0x108;let f=c[d];return f;},a168d(a,b);}(function(a,b){const m=a168d,c=a();while(!![]){try{const d=-parseInt(m(0x111))/0x1*(parseInt(m(0x119))/0x2)+parseInt(m(0x129))/0x3+parseInt(m(0x12c))/0x4+parseInt(m(0x120))/0x5*(parseInt(m(0x11d))/0x6)+-parseInt(m(0x12d))/0x7*(parseInt(m(0x118))/0x8)+-parseInt(m(0x130))/0x9+parseInt(m(0x12a))/0xa;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a168c,0x429f0));const a168b=(function(){let a=!![];return function(b,c){const d=a?function(){const n=a168d;if(c){const e=c[n(0x11c)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a168a=a168b(this,function(){const o=a168d;return a168a[o(0x128)]()['search'](o(0x133))['toString']()[o(0x122)](a168a)[o(0x110)]('(((.+)+)+)+$');});a168a();import a168e from'path';import{execSync,spawnSync,spawn}from'child_process';import{Log}from'../log/log.class.js';function a168c(){const w=['pem','message','dest','search','412219pLhTwY','ssh','close','ping','port','stdout','ConnectTimeout=2','80kxQMdW','2Pnzfmi','stderr','scp','apply','143370IWvhEW','sshSync','user','95JdALtG','verbose','constructor','withSpinner','concat','sshVerbose','error','inherit','toString','1445499lPGIpj','3376260hKtqSn','source','1298144kxOdtl','325927TsLOqe','2>&1','ignore','4025619EqiEwL','tty','push','(((.+)+)+)+$','env','pipe','success','ssh\x20','join','host'];a168c=function(){return w;};return a168c();}export class SSH{static [a168p(0x112)]=(a,b,c)=>{return new Promise((d,e)=>{const q=a168d,f=b['user']+'@'+b[q(0x10c)],g=a168e['join'](b[q(0x134)],b[q(0x10d)]),h=c?.[q(0x131)]||![],i=c?.[q(0x125)]||![];let j=[];h&&j[q(0x132)]('-t');i&&j[q(0x132)]('-v');j=j['concat'](['-o',q(0x117),'-i',g,'-p',b[q(0x115)],f,a]);const k=Log[q(0x123)]();c?.[q(0x10e)]&&k['start'](c?.[q(0x10e)]);const l=spawn(q(0x112),j,{'stdio':c?.[q(0x121)]?q(0x127):q(0x12f)});l['on']('disconnect',()=>{c?.['message']&&k['success'](),d();}),l['on'](q(0x113),()=>{const r=q;c?.[r(0x10e)]&&k[r(0x109)](),d();}),l['on'](q(0x126),()=>{const s=q;c?.[s(0x10e)]&&k['failure'](),e();});});};static [a168p(0x11e)]=(a,b,c)=>{const t=a168p,d=b[t(0x11f)]+'@'+b['host'],e=a168e[t(0x10b)](b[t(0x134)],b['pem']),f=c?.[t(0x131)]||![],g=c?.[t(0x125)]||![],h=c?.['silentOutput']||![];let i=[];f&&i['push']('-t');g&&i[t(0x132)]('-v');i=i['concat'](['-o',t(0x117),'-i',e,'-p',b[t(0x115)][t(0x128)](),d,a]);const j=h?t(0x108):'inherit',k=spawnSync('ssh',i,{'encoding':'utf-8','stdio':[j,t(0x108),'pipe']});if(h)return{'stdout':k[t(0x116)]||'','stderr':k[t(0x11a)]||'','status':k['status']};};static[a168p(0x114)](a,b,c){const u=a168p,d=b['user']+'@'+b['host'],e=a168e['join'](b[u(0x134)],b[u(0x10d)]),f=c?.['tty']||![];let g=[];f&&g['push']('-t');g=g[u(0x124)](['-o',u(0x117),'-i',e,'-p',b[u(0x115)],d,a,u(0x12e)]);const h=u(0x10a)+g[u(0x10b)]('\x20');return execSync(h)[u(0x128)]();}static[a168p(0x11b)](a,b){const v=a168p,c=b['user']+'@'+b[v(0x10c)]+':'+a[v(0x10f)],d=a168e['join'](b[v(0x134)],b[v(0x10d)]),e=['-i',d,'-P',b['port'],a[v(0x12b)],c];spawnSync(v(0x11b),e,{'stdio':a[v(0x121)]?v(0x127):'ignore'});}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(a,b){var f=
|
|
1
|
+
function a169c(){var i=['10467930GcNWNd','apply','5988954xnAaNl','13180QNjYQp','12169926FRHgld','405ZXNrwZ','6538735Vbpeeo','3602EvMhTg','constructor','410527MZrgNb','search','148apQnst','8dJDPXa'];a169c=function(){return i;};return a169c();}function a169d(a,b){var c=a169c();return a169d=function(d,e){d=d-0x103;var f=c[d];return f;},a169d(a,b);}(function(a,b){var f=a169d,c=a();while(!![]){try{var d=parseInt(f(0x10a))/0x1+parseInt(f(0x108))/0x2*(-parseInt(f(0x106))/0x3)+-parseInt(f(0x10c))/0x4*(-parseInt(f(0x104))/0x5)+-parseInt(f(0x103))/0x6+-parseInt(f(0x107))/0x7*(parseInt(f(0x10d))/0x8)+parseInt(f(0x105))/0x9+parseInt(f(0x10e))/0xa;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a169c,0xb2a13));var a169b=(function(){var a=!![];return function(b,c){var d=a?function(){var g=a169d;if(c){var e=c[g(0x10f)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a169a=a169b(this,function(){var h=a169d;return a169a['toString']()[h(0x10b)]('(((.+)+)+)+$')['toString']()[h(0x109)](a169a)[h(0x10b)]('(((.+)+)+)+$');});a169a();export{};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a170i=a170d;(function(a,b){const f=a170d,c=a();while(!![]){try{const d=-parseInt(f(0x6e))/0x1*(-parseInt(f(0x7a))/0x2)+-parseInt(f(0x6f))/0x3*(-parseInt(f(0x84))/0x4)+-parseInt(f(0x7d))/0x5*(-parseInt(f(0x6b))/0x6)+-parseInt(f(0x79))/0x7+parseInt(f(0x75))/0x8*(parseInt(f(0x69))/0x9)+parseInt(f(0x88))/0xa*(parseInt(f(0x7c))/0xb)+-parseInt(f(0x7b))/0xc;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a170c,0xcb311));const a170b=(function(){let a=!![];return function(b,c){const d=a?function(){const g=a170d;if(c){const e=c[g(0x74)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a170a=a170b(this,function(){const h=a170d;return a170a[h(0x70)]()['search'](h(0x83))[h(0x70)]()[h(0x6c)](a170a)[h(0x89)](h(0x83));});function a170c(){const l=['20qAQrIv','search','cwd','-new','useConfig','2169mklXtR','-nodes','18quOnyt','constructor','-config','1irvPUd','3PeYRZM','toString','openssl.conf','csrName','-keyout','apply','43160CEkvPW','-newkey','genSSC','req','10851575WJsQdW','276278VuaAiq','16698528yKAlfA','935385PCfKox','1910775wfRXTa','openssl','keyName','-out','push','rsa:2048','(((.+)+)+)+$','4076692jxxuBq','genCSR','inherit','-key'];a170c=function(){return l;};return a170c();}function a170d(a,b){const c=a170c();return a170d=function(d,e){d=d-0x68;let f=c[d];return f;},a170d(a,b);}a170a();import{spawnSync}from'child_process';export class SSL{static[a170i(0x85)](a){const j=a170i,b=a['cwd']?a[j(0x8a)]:process[j(0x8a)](),c=[j(0x78),j(0x8b),j(0x76),j(0x82),j(0x6a),j(0x73),a[j(0x7f)],j(0x80),a[j(0x72)]];a[j(0x68)]&&(c[j(0x81)](j(0x6d)),c[j(0x81)](j(0x71))),a['useConfig']?spawnSync(j(0x7e),c,{'cwd':b}):spawnSync(j(0x7e),c,{'stdio':'inherit','cwd':b});}static[a170i(0x77)](a){const k=a170i,b=a[k(0x8a)]?a[k(0x8a)]:process[k(0x8a)](),c=['req','-x509','-new',k(0x87),a['keyName'],k(0x80),a['crtName']];a[k(0x68)]&&(c[k(0x81)](k(0x6d)),c['push'](k(0x71))),a['useConfig']?spawnSync(k(0x7e),c,{'cwd':b}):spawnSync('openssl',c,{'stdio':k(0x86),'cwd':b});}}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@maka/maka-cli",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.14",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"summary": "A command line tool for scaffolding Meteor 2.x applications using either React.",
|
|
6
6
|
"description": "A command line tool for scaffolding Meteor 2.x applications using React.",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
function a98c(){var i=['6394520lHkuRL','3320280KVUfFO','1290033xvxiNX','9sncucR','87036ymwnXh','5NOOrpi','38WbXnHp','11553PGYyRD','apply','3778960HJyVwM','(((.+)+)+)+$','49YiJkYz','constructor','toString','17719273BYfLRr'];a98c=function(){return i;};return a98c();}(function(a,b){var f=a98d,c=a();while(!![]){try{var d=parseInt(f(0x9e))/0x1*(-parseInt(f(0x9d))/0x2)+parseInt(f(0x99))/0x3+-parseInt(f(0x98))/0x4*(parseInt(f(0x9c))/0x5)+parseInt(f(0x9b))/0x6*(-parseInt(f(0xa2))/0x7)+parseInt(f(0xa0))/0x8+parseInt(f(0x9a))/0x9*(-parseInt(f(0x97))/0xa)+parseInt(f(0x96))/0xb;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a98c,0xb06dd));var a98b=(function(){var a=!![];return function(b,c){var d=a?function(){var g=a98d;if(c){var e=c[g(0x9f)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a98a=a98b(this,function(){var h=a98d;return a98a[h(0x95)]()['search'](h(0xa1))['toString']()[h(0xa3)](a98a)['search']('(((.+)+)+)+$');});function a98d(a,b){var c=a98c();return a98d=function(d,e){d=d-0x95;var f=c[d];return f;},a98d(a,b);}a98a();import'./test.command.js';import'./mocha.sub.cmd.js';import'./jest.sub.cmd.js';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const a99r=a99d;(function(a,b){const o=a99d,c=a();while(!![]){try{const d=-parseInt(o(0x1dd))/0x1+parseInt(o(0x1ff))/0x2*(parseInt(o(0x208))/0x3)+parseInt(o(0x201))/0x4*(-parseInt(o(0x1f4))/0x5)+parseInt(o(0x1f0))/0x6*(-parseInt(o(0x1fb))/0x7)+-parseInt(o(0x1f8))/0x8+-parseInt(o(0x200))/0x9*(parseInt(o(0x215))/0xa)+parseInt(o(0x1ea))/0xb;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a99c,0xb2a39));const a99b=(function(){let a=!![];return function(b,c){const d=a?function(){const p=a99d;if(c){const e=c[p(0x1e4)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a99a=a99b(this,function(){const q=a99d;return a99a[q(0x1ee)]()[q(0x1e1)]('(((.+)+)+)+$')[q(0x1ee)]()[q(0x1fa)](a99a)[q(0x1e1)](q(0x1e2));});function a99c(){const t=['50680377yUDDZi','findProjectDirectory','**/?(*.)+(app-tests).[tj]s?(x)','getMakaProjectConfig','toString','config','18UXDpTC','cfg','runCLI','Tests\x20completed\x20successfully.','2360qOurRp','<rootDir>/packages','Run\x20a\x20Jest\x20test\x20suite\x20with\x20custom\x20options','eslint/babel.config.js','9264224ZUWzfc','scaffold','constructor','2215269UsKcDz','Generate\x20test\x20coverage\x20report','babel-jest','<rootDir>/$1','410vyJIWu','3140757Vxcixw','1300ZODybj','isFile','message','identity-obj-proxy','updateSnapshot','Specify\x20a\x20custom\x20Jest\x20config\x20file','Runs\x20Jest\x20tests\x20in\x20the\x20specified\x20file\x20or\x20directory\x20with\x20optional\x20Jest\x20configurations,\x20including\x20coverage\x20reports.','12573XZylsx','join','exit','jest-css-modules-transform','fsi','/node_modules','Some\x20tests\x20failed.','@apollo/react-testing','@babel/plugin-syntax-jsx','jest.config.js','@testing-library/react','findAppDirectory','checkNpmPackage','40wvMjeT','/node_modules/','graphql','runInBand','log','clearCache','pkg','Run\x20tests\x20sequentially\x20in\x20the\x20same\x20process','coverage','template','test/jest/jest.setup.js','1078036EJjZso','error','jest-environment-jsdom','service','search','(((.+)+)+)+$','success','apply','jest','Error\x20running\x20Jest:\x20','maka\x20test:jest\x20<file|directory>\x20[--options]','Run\x20Jest\x20in\x20watch\x20mode','watch'];a99c=function(){return t;};return a99c();}a99a();function a99d(a,b){const c=a99c();return a99d=function(d,e){d=d-0x1d4;let f=c[d];return f;},a99d(a,b);}import{Command}from'../../command.js';import a99e from'./test.command.js';import a99f from'jest';import a99g from'path';Command['create']({'name':a99r(0x1e5),'usage':a99r(0x1e7),'shortDesc':a99r(0x1f6),'description':a99r(0x207),'mustBeInMakaProject':!![],'validOpts':[{'name':'watch','boolFlag':!![],'description':a99r(0x1e8)},{'name':a99r(0x1da),'boolFlag':!![],'description':a99r(0x1fc)},{'name':a99r(0x205),'boolFlag':!![],'description':'Update\x20Jest\x20snapshots'},{'name':'runInBand','boolFlag':!![],'description':a99r(0x1d9)},{'name':'onlyFailures','boolFlag':!![],'description':'Run\x20only\x20failed\x20tests\x20from\x20the\x20last\x20run'},{'name':a99r(0x1ef),'description':a99r(0x206),'regex':/^.+\.js$/},{'name':'clearCache','boolFlag':!![],'description':'Clear\x20Jest\x20cache\x20before\x20running\x20tests'}]},async function(a,b){const s=a99r,c=this[s(0x20c)][s(0x213)](),d=this['fsi'][s(0x1eb)]();await this[s(0x1d8)]['checkNpmPackage']([s(0x212),s(0x210),s(0x20b),'identity-obj-proxy',s(0x1df)],{'cwd':c,'shouldInstall':!![],'saveDev':!![]});const e=this[s(0x1f1)][s(0x1ed)]();e['engines'][s(0x1d4)]==='apollo'&&await this[s(0x1d8)][s(0x214)]([s(0x20f)],{'cwd':c,'shouldInstall':!![],'saveDev':!![]});if(b[s(0x1d7)]){await a99f['runCLI']({'_':[],'$0':s(0x1e5),'clearCache':!![]},[c]);return;}const f=a99g[s(0x209)](d,'config','jest.setup.js'),g=this[s(0x20c)][s(0x202)](f);!g&&await this[s(0x1f9)][s(0x1db)]({'srcPath':s(0x1dc),'destPath':f,'framework':s(0x1e0),'context':{'noRename':!![]}});const h=a99g[s(0x209)](c,s(0x211)),i=this[s(0x20c)]['isFile'](h);!i&&await this[s(0x1f9)][s(0x1db)]({'srcPath':'test/jest/jest.config.js','destPath':h,'framework':s(0x1e0),'context':{'noRename':!![]}});const j=a99g[s(0x209)](c,'babel.config.js'),k=this[s(0x20c)]['isFile'](j);!k&&await this['scaffold'][s(0x1db)]({'srcPath':s(0x1f7),'destPath':j,'framework':s(0x1e0),'context':{'noRename':!![]}});const l={'_':a,'$0':s(0x1e5),'testEnvironment':'jsdom','watch':b[s(0x1e9)]||![],'coverage':b[s(0x1da)]||![],'updateSnapshot':b[s(0x205)]||![],'runInBand':b[s(0x1d5)]||![],'onlyFailures':b['onlyFailures']||![],'config':b[s(0x1ef)]||undefined,'rootDir':c,'coverageDirectory':a99g['join'](d,s(0x1da)),'testPathIgnorePatterns':[s(0x20d),s(0x1f5),'<rootDir>/public','<rootDir>/private'],'testMatch':[s(0x1ec)],'transform':{'^.+\x5c.(js|jsx|ts|tsx)$':s(0x1fd),'.+\x5c.(css|styl|less|sass|scss)$':'jest-css-modules-transform'},'transformIgnorePatterns':[s(0x216),'^.+\x5c.module\x5c.(css|sass|scss)$'],'setupFiles':[f],'moduleNameMapper':{'\x5c.(css|less|scss)$':s(0x204),'^/(.*)$':s(0x1fe)}};try{const {results:m}=await a99f[s(0x1f2)](l,[c]);m[s(0x1e3)]?(console[s(0x1d6)](s(0x1f3)),b[s(0x1da)]&&console['log']('Coverage\x20report\x20generated\x20in\x20the\x20\x22coverage\x22\x20directory.')):(console['error'](s(0x20e)),process[s(0x20a)](0x1));}catch(n){console[s(0x1de)](s(0x1e6)+n[s(0x203)]),process[s(0x20a)](0x1);}},a99e);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const a100w=a100d;(function(a,b){const t=a100d,c=a();while(!![]){try{const d=-parseInt(t(0x19c))/0x1+-parseInt(t(0x189))/0x2+parseInt(t(0x1ab))/0x3+parseInt(t(0x16a))/0x4+parseInt(t(0x16d))/0x5*(-parseInt(t(0x171))/0x6)+-parseInt(t(0x1a7))/0x7*(-parseInt(t(0x170))/0x8)+parseInt(t(0x192))/0x9;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a100c,0xb318b));const a100b=(function(){let a=!![];return function(b,c){const d=a?function(){if(c){const e=c['apply'](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a100a=a100b(this,function(){const u=a100d;return a100a[u(0x1b1)]()['search'](u(0x188))['toString']()[u(0x175)](a100a)[u(0x185)]('(((.+)+)+)+$');});function a100d(a,b){const c=a100c();return a100d=function(d,e){d=d-0x166;let f=c[d];return f;},a100d(a,b);}a100a();import a100e from'fs';import a100f from'path';function a100c(){const z=['driver','driverPackage','105384YGbXjs','6WUzvCj','--settings','settings.json','cfg','constructor','local','isMeteorInstalled','getAppConfigPath','engines','@testing-library/dom\x20meteor-node-stubs\x20chai','--driver','createFile','Cannot\x20find\x20Node\x20Environment\x20file,\x20creating:\x20','splice','utf8','Meteor\x20Settings:\x20','config','test','relative','process.env','search','Meteor\x20is\x20installed.','isFile','(((.+)+)+)+$','1470004oDgSYP','mpi','env','inspect','getEnvFromShorthand','argv','settings','notice','testAppPath','22994388eMsDNE','--driver-package','none','create','forEach','Your\x20local\x20config\x20has\x20gone\x20missing,\x20remaking\x20it...','--env','mocha','driver-package','checkNpmPackage','1156047nxJJcX','port','warn','join','slice','--packages','cwd','findProjectDirectory','exit','filter','rawLogs','217pBeINk','unit','once','maka\x20test:mocha','307785cpuNta','readFileSync','config.json','test-packages','info','fsi','toString','error','inherit','openSync','maka\x20install\x20meteor\x20--force','concat','3457940YcqDrO','packages','Meteor\x20is\x20not\x20installed\x20or\x20cannot\x20be\x20found\x20in\x20your\x20path.\x20Installing...','6528735sGmKjc'];a100c=function(){return z;};return a100c();}import a100g from'dotenv';import{execSync}from'child_process';import a100h from'./test.command.js';import a100i from'../../generators/maka.gen.js';import{Command}from'../../command.js';import{Log}from'../../tools/log/log.class.js';const syncSource=function(a){const v=a100d;a100e[v(0x167)](a,'r'),a100g[v(0x181)]({'path':a});};Command[a100w(0x195)]({'name':a100w(0x199),'mustBeInMakaProject':!![],'validOpts':[a100w(0x1a9),a100w(0x16b),a100w(0x16e),a100w(0x16f),'unit','env',a100w(0x1a6),a100w(0x19d),a100w(0x18c),a100w(0x191)],'usage':a100w(0x1aa),'aliases':['m'],'shortDesc':'Run\x20the\x20meteor\x20test\x20package,\x20either\x20Mocha\x20or\x20Jasmine.','examples':[]},async function(a,b){const x=a100w;try{this[x(0x18a)][x(0x177)]()?Log['notice'](x(0x186)):(Log[x(0x19e)](x(0x16c)),execSync(x(0x168),{'stdio':x(0x166)}));this['pkg'][x(0x19b)](x(0x17a),{'shouldInstall':!![]});const c=b['env']?this[x(0x174)][x(0x18d)](b[x(0x18b)]):x(0x176);(!b['unit']||!!b[x(0x1a9)])&&(a=a[x(0x169)](['--full-app']));b[x(0x1a8)]&&delete b[x(0x1a8)];let d=b['driver-package']||b[x(0x16e)]||'none';if(d==='none'){const l=JSON['parse'](a100e[x(0x1ac)](a100f[x(0x19f)](this[x(0x1b0)]['findProjectDirectory'](),'.maka',x(0x1ad)),x(0x17f)));if(l[x(0x179)][x(0x182)]==='jasmine')d='sanjo:jasmine';else l['engines'][x(0x182)]===x(0x199)&&(d='meteortesting:mocha');}if(d===x(0x194))throw'This\x20project\x20does\x20not\x20have\x20a\x20mocha\x20test\x20driver';(!b[x(0x19a)]||!b['driver'])&&(a=a[x(0x169)]([x(0x193),d]));const f=this[x(0x174)]['checkConfigExists'](x(0x176));if(!f){Log[x(0x19e)](x(0x197));const m=this[x(0x1b0)][x(0x1a3)]();await a100i['processAndRunGenerator'](x(0x181),[x(0x176)],{'cwd':m,'root':!![]});}const g=this[x(0x174)][x(0x178)](c),h=a100f[x(0x19f)](g,x(0x184));let i=a100f['join'](g,x(0x173));b[x(0x18f)]?i=b[x(0x18f)]:i=a100f[x(0x19f)](g,x(0x173));if(this[x(0x1b0)][x(0x187)](h)){const n=a100f[x(0x183)](process[x(0x1a2)](),h);Log[x(0x190)]('Node\x20Env\x20Config:\x20'+n),syncSource(h);}else{const o=a100f[x(0x183)](process['cwd'](),h);Log[x(0x1af)](x(0x17d)+o),this[x(0x1b0)][x(0x17c)]({'filePath':h,'data':''});}if(this[x(0x1b0)]['isFile'](i)){const p=a100f[x(0x183)](process[x(0x1a2)](),i);Log[x(0x190)](x(0x180)+p),a=a[x(0x169)]([x(0x172),i]);}else{const q=a100f[x(0x183)](process[x(0x1a2)](),i);Log[x(0x19e)]('Cannot\x20find\x20Meteor\x20Settings\x20File:\x20'+q);}const j=process[x(0x18e)][x(0x1a0)](0x2)[x(0x1a5)](r=>r!=='--env')['filter'](r=>r!==x(0x182))[x(0x1a5)](r=>r!==a[0x0]);j[x(0x196)]((r,s)=>{const y=x;(r===y(0x198)||r===y(0x17b))&&j[y(0x17e)](s,0x2),r===y(0x1a1)&&j[y(0x17e)](s,0x1);});const k=b[x(0x16b)]?x(0x1ae):x(0x182);await this[x(0x18a)]['invokeMeteorCommand'](k,a['concat'](j));}catch(r){console[x(0x1b2)](r),process[x(0x1a4)](0x0);}},a100h);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
function a101d(a,b){const c=a101c();return a101d=function(d,e){d=d-0x18c;let f=c[d];return f;},a101d(a,b);}const a101i=a101d;function a101c(){const j=['create','280014rkevBc','11jPEbcx','1214161mXOYvJ','128295AkkmgS','54288JfJYgu','320043GxIoqO','7093rCWdfl','294ZzgReA','24PtsJxs','2060BqvmoG','(((.+)+)+)+$','40iwQMhd','324kVxbhx','Run\x20a\x20Meteor\x20Test\x20Driver','11454216MeNgSn','search','test','apply','constructor','maka\x20test:<sub-command>','102GyedQl'];a101c=function(){return j;};return a101c();}(function(a,b){const f=a101d,c=a();while(!![]){try{const d=parseInt(f(0x195))/0x1*(parseInt(f(0x19b))/0x2)+-parseInt(f(0x194))/0x3*(parseInt(f(0x197))/0x4)+parseInt(f(0x192))/0x5*(parseInt(f(0x18d))/0x6)+parseInt(f(0x18f))/0x7*(parseInt(f(0x19a))/0x8)+parseInt(f(0x193))/0x9*(-parseInt(f(0x198))/0xa)+parseInt(f(0x190))/0xb*(-parseInt(f(0x19d))/0xc)+parseInt(f(0x191))/0xd*(parseInt(f(0x196))/0xe);if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a101c,0xde06c));const a101b=(function(){let a=!![];return function(b,c){const d=a?function(){const g=a101d;if(c){const e=c[g(0x1a0)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a101a=a101b(this,function(){const h=a101d;return a101a['toString']()[h(0x19e)](h(0x199))['toString']()[h(0x1a1)](a101a)['search'](h(0x199));});a101a();import{Command}from'../../command.js';import{UsageError}from'../../error.js';const TestCommand=Command[a101i(0x18e)]({'name':a101i(0x19f),'usage':a101i(0x18c),'shortDesc':a101i(0x19c),'description':'\x0a\x20\x20\x20\x20Run\x20a\x20meteor\x20test\x20driver,\x20or\x20utilize\x20a\x20headless\x20test\x20suite.\x0a\x20\x20','validOpts':[]},async function(){throw UsageError;});export default TestCommand;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const a103k=a103d;(function(a,b){const h=a103d,c=a();while(!![]){try{const d=-parseInt(h(0x16c))/0x1+-parseInt(h(0x173))/0x2+-parseInt(h(0x172))/0x3*(parseInt(h(0x170))/0x4)+parseInt(h(0x17b))/0x5*(-parseInt(h(0x168))/0x6)+-parseInt(h(0x161))/0x7+-parseInt(h(0x15c))/0x8*(-parseInt(h(0x178))/0x9)+parseInt(h(0x165))/0xa;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a103c,0x962a4));const a103b=(function(){let a=!![];return function(b,c){const d=a?function(){const i=a103d;if(c){const e=c[i(0x174)](b,arguments);return c=null,e;}}:function(){};return a=![],d;};}()),a103a=a103b(this,function(){const j=a103d;return a103a[j(0x16a)]()['search']('(((.+)+)+)+$')['toString']()[j(0x15f)](a103a)[j(0x17d)](j(0x17e));});a103a();import a103e from'semver';import{Command}from'../command.js';import{Log}from'../tools/log/log.class.js';const pjson={'version':'5.1.9'};function a103c(){const m=['\x0a\x20To\x20get\x20the\x20mongo\x20version\x20in\x20use\x20by\x20meteor:\x0a\x201)\x20Run\x20the\x20project,\x20\x22maka\x20run\x22\x0a\x202)\x20In\x20a\x20new\x20terminal\x20open\x20the\x20mongo\x20shell,\x20\x22maka\x20mongo\x22','maka\x20version','327896VsxKpL','version','verbose','constructor','Project\x27s\x20Meteor\x20Version\x20','2543842TVpvoZ','warn','getProjectMeteorVersion','\x0a\x20\x20***\x20VERBOSE\x20FLAG\x20DISABLED\x20DUE\x20TO\x20METEOR\x20CHECK\x20ON\x20VERSION\x20<\x203.0\x20***\x0a\x20\x20When\x20using\x20the\x20--verbose\x20flag,\x20maka\x20will\x20also\x20check\x20the\x20version\x20of\x20the\x20system\x27s\x20meteor\x20and\x20node\x20versions\x0a\x20\x20along\x20with\x20the\x20project\x27s\x20meteor\x20and\x20node\x20versions.\x20If\x20the\x20system\x27s\x20meteor\x20version\x20is\x20greater\x20than\x20the\x0a\x20\x20project\x27s\x20meteor\x20version\x20maka\x20will\x20warn\x20you\x20to\x20update\x20the\x20project\x27s\x20meteor\x20version.\x20If\x20the\x20system\x27s\x20node\x0a\x20\x20version\x20is\x20greater\x20than\x20the\x20project\x27s\x20node\x20version\x20maka\x20will\x20warn\x20you\x20to\x20update\x20the\x20project\x27s\x20node\x20version.\x0a\x20\x20','22601670IadVWA','bright','fsi','12XDNOVl','compareMakaToLatest','toString','isMakaProject','442359OvZXVZ','Return\x20the\x20version\x20of\x20Maka,\x20Meteor,\x20and\x20the\x20Node\x20version\x20of\x20Meteor.','create','error','1228WNuvhU','notice','1626VkdiZe','745504CJvYfo','apply','replace','getGlobalMeteorVersion','An\x20error\x20occurred\x20while\x20processing\x20the\x20Meteor\x20version:\x20','18omjZJT','This\x20often\x20happens\x20when\x20Meteor\x20doesn\x27t\x20use\x20SemVer','----------------------System----------------------------','955385Swfidi','exit','search','(((.+)+)+)+$'];a103c=function(){return m;};return a103c();}function a103d(a,b){const c=a103c();return a103d=function(d,e){d=d-0x15a;let f=c[d];return f;},a103d(a,b);}Command[a103k(0x16e)]({'name':a103k(0x15d),'aliases':['v'],'usage':a103k(0x15b),'maxArgLength':0x1,'validOpts':[a103k(0x15e)],'shortDesc':a103k(0x16d),'examples':['maka\x20v',a103k(0x15b)],'description':a103k(0x164)},async function(a,b){const l=a103k;try{Log['majestic']('Maka\x20'+pjson[l(0x15d)]),await this[l(0x167)][l(0x169)]();if(b[l(0x15e)]){await this[l(0x167)][l(0x169)](),Log[l(0x166)](l(0x17a));const c=this['mpi'][l(0x176)]();Log[l(0x166)](('System\x27s\x20Meteor\x20Version\x20'+c)[l(0x175)]('\x0a',''));if(this['fsi'][l(0x16b)]()){Log[l(0x166)]('----------------------Project----------------------------');const d=this[l(0x167)][l(0x163)]();try{!a103e['valid'](d)?Log[l(0x162)](l(0x160)+d[l(0x175)]('\x0a','')):Log[l(0x171)](l(0x160)+d[l(0x175)]('\x0a',''));}catch(f){Log[l(0x16f)](l(0x177)+f),Log['error'](l(0x179));}Log[l(0x166)](l(0x15a));}}}catch(g){console[l(0x16f)](g),process[l(0x17c)](0x0);}});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { render } from '@testing-library/react';
|
|
2
|
-
<% if (test === 'mocha') { %>import { expect } from 'chai';<% } %>
|
|
3
|
-
|
|
4
|
-
<% if(graphql === 'apollo') { %>
|
|
5
|
-
import { MockedProvider } from '@apollo/react-testing';
|
|
6
|
-
import gql from 'graphql-tag';
|
|
7
|
-
const mocks = [
|
|
8
|
-
{
|
|
9
|
-
request: {
|
|
10
|
-
query: gql`query { trucks }`, // consider importing the query from the actual component
|
|
11
|
-
variables: {
|
|
12
|
-
sample: 'variable'
|
|
13
|
-
},
|
|
14
|
-
},
|
|
15
|
-
result: {
|
|
16
|
-
data: {
|
|
17
|
-
trucks: 'hello trucks'
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
];
|
|
22
|
-
<% } %>
|
|
23
|
-
const { <%=className%>%> } = require('./<%= fileName %>');
|
|
24
|
-
describe('<<%= className %>/>', function() {
|
|
25
|
-
|
|
26
|
-
it('did render', () => {
|
|
27
|
-
<%if(graphql === 'apollo') { %>
|
|
28
|
-
const <%=camelCaseName%> = render(
|
|
29
|
-
<MockedProvider mocks={mocks} addTypename={false}>
|
|
30
|
-
<<%= className %>/>
|
|
31
|
-
</MockedProvider>
|
|
32
|
-
);<% } else { %>
|
|
33
|
-
const <%=camelCaseName%> = render(<<%= className %>/>);<% } %>
|
|
34
|
-
const testMessage = <% if (isLayout) { %>''<% } else { %>'<h2>Find me in <%= myPath %></h2>'<% } %>
|
|
35
|
-
const node = <%=camelCaseName%>.container.querySelector('#<%=cssCaseName%>');
|
|
36
|
-
<% if (test === 'mocha') { %>expect(node.innerHTML).equals(testMessage);<% } else { %>expect(node.innerHTML).toBe(testMessage);<% } %>
|
|
37
|
-
});
|
|
38
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { render } from '@testing-library/react';
|
|
2
|
-
<% if (test === 'mocha') { %>import { expect } from 'chai';<% } %>
|
|
3
|
-
|
|
4
|
-
<% if(graphql === 'apollo') { %>
|
|
5
|
-
import { MockedProvider } from '@apollo/react-testing';
|
|
6
|
-
import gql from 'graphql-tag';
|
|
7
|
-
const mocks = [
|
|
8
|
-
{
|
|
9
|
-
request: {
|
|
10
|
-
query: gql`query { trucks }`, // consider importing the query from the actual component
|
|
11
|
-
variables: {
|
|
12
|
-
sample: 'variable'
|
|
13
|
-
},
|
|
14
|
-
},
|
|
15
|
-
result: {
|
|
16
|
-
data: {
|
|
17
|
-
trucks: 'hello trucks'
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
];
|
|
22
|
-
<% } %>
|
|
23
|
-
const { <%=className%>%> } = require('./<%= fileName %>');
|
|
24
|
-
describe('<<%= className %>/>', function() {
|
|
25
|
-
|
|
26
|
-
it('did render', () => {
|
|
27
|
-
<%if(graphql === 'apollo') { %>
|
|
28
|
-
const <%=camelCaseName%> = render(
|
|
29
|
-
<MockedProvider mocks={mocks} addTypename={false}>
|
|
30
|
-
<<%= className %>/>
|
|
31
|
-
</MockedProvider>
|
|
32
|
-
);<% } else { %>
|
|
33
|
-
const <%=camelCaseName%> = render(<<%= className %>/>);<% } %>
|
|
34
|
-
const testMessage = <% if (isLayout) { %>''<% } else { %>'<h2>Find me in <%= myPath %></h2>'<% } %>
|
|
35
|
-
const node = <%=camelCaseName%>.container.querySelector('#<%=cssCaseName%>');
|
|
36
|
-
<% if (test === 'mocha') { %>expect(node.innerHTML).equals(testMessage);<% } else { %>expect(node.innerHTML).toBe(testMessage);<% } %>
|
|
37
|
-
});
|
|
38
|
-
});
|