fix(core): update

This commit is contained in:
Philipp Kunz 2020-03-25 15:16:03 +00:00
parent aa709985ae
commit b42c700a28
7 changed files with 72 additions and 50 deletions

75
package-lock.json generated
View File

@ -4,11 +4,22 @@
"lockfileVersion": 1,
"requires": true,
"dependencies": {
"@apiglobal/typedrequest": {
"version": "1.0.28",
"resolved": "https://verdaccio.lossless.one/@apiglobal%2ftypedrequest/-/typedrequest-1.0.28.tgz",
"integrity": "sha512-dJ3Fxq+kEApD47AWrJ4LP+n6w9MKEBmzD/2YzmkdT5Adi2Htcpw1qfNZkvT5eMfXDuOgiLZC45+LMmwnwAUCdw==",
"requires": {
"@apiglobal/typedrequest-interfaces": "^1.0.12",
"@pushrocks/lik": "^3.0.17",
"@pushrocks/smartdelay": "^2.0.6",
"@pushrocks/smartjson": "^3.0.10",
"@pushrocks/smartrequest": "^1.1.47"
}
},
"@apiglobal/typedrequest-interfaces": {
"version": "1.0.13",
"resolved": "https://verdaccio.lossless.one/@apiglobal%2ftypedrequest-interfaces/-/typedrequest-interfaces-1.0.13.tgz",
"integrity": "sha512-3mk0mMC7unqh+Bb0mPEMwEfJcLAGl5ZjA1If/OGyk56KQOBqA2mLATS40HREeGoAEcUOHU2VCwPuU/tpSVMY/w==",
"dev": true
"integrity": "sha512-3mk0mMC7unqh+Bb0mPEMwEfJcLAGl5ZjA1If/OGyk56KQOBqA2mLATS40HREeGoAEcUOHU2VCwPuU/tpSVMY/w=="
},
"@babel/code-frame": {
"version": "7.8.3",
@ -105,7 +116,6 @@
"version": "3.0.19",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2flik/-/lik-3.0.19.tgz",
"integrity": "sha512-N9uTtQmTJ/iZ/V7LMCKbVx/ZAmP+b8uId0pxV9Au9T0Ulu9wcg3vNpyTQARgdWfG+tI9Qc0NHgOEa9H5mbDcDA==",
"dev": true,
"requires": {
"@pushrocks/smartdelay": "^2.0.6",
"@pushrocks/smartpromise": "^3.0.6",
@ -144,7 +154,6 @@
"version": "2.0.5",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartevent/-/smartevent-2.0.5.tgz",
"integrity": "sha512-2cromUAgMFOLxi9IuAhDesWV4FGmsdNQV6k2OQZbH/0bMYeaCT5Q4IcMxb8J5F0S820XCXlwGdy5VP5M6L+hAA==",
"dev": true,
"requires": {
"@pushrocks/smartpromise": "^3.0.6",
"@pushrocks/smartrx": "^2.0.5"
@ -271,7 +280,6 @@
"version": "2.0.5",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartrx/-/smartrx-2.0.5.tgz",
"integrity": "sha512-BOlIJmnCO8pxqu9f18D9UV5rIsyrmKeK/mWNMiAe/NH2OTeRPNLpgmhZBkXSKNVD8tSsD8aazs4BcACgYOg1FQ==",
"dev": true,
"requires": {
"@pushrocks/lik": "^3.0.11",
"@pushrocks/smartevent": "^2.0.3",
@ -296,7 +304,6 @@
"version": "3.0.12",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmarttime/-/smarttime-3.0.12.tgz",
"integrity": "sha512-NoMt1NUhNqcF5y7fCTHoC3d/+MobzgNUg6yHbSGxFRaentQzCrMPNahQIVLbrAStf03LUUBePUjSRdPYucP1gw==",
"dev": true,
"requires": {
"@pushrocks/smartpromise": "^3.0.2",
"@types/cron": "^1.7.1",
@ -309,7 +316,6 @@
"version": "3.0.3",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartunique/-/smartunique-3.0.3.tgz",
"integrity": "sha512-f+c3s2WzzjASoRHyYTLU0kHDVWREg4sZVdi5L42bTA3CTUWNrcGUC62h4wP4U4BiPl3bopTr3LPhClZHJ738oA==",
"dev": true,
"requires": {
"@types/shortid": "0.0.29",
"@types/uuid": "^7.0.0",
@ -330,9 +336,9 @@
}
},
"@tsclass/tsclass": {
"version": "3.0.13",
"resolved": "https://verdaccio.lossless.one/@tsclass%2ftsclass/-/tsclass-3.0.13.tgz",
"integrity": "sha512-eAcBQX03cNNZy1EmKD6xrU+EEjeQonyXo6vkMhl4HL3ATaCOyxurh/ZTi1zgjCFcBRenfUHqjsVoIRmuxWg3WQ==",
"version": "3.0.16",
"resolved": "https://verdaccio.lossless.one/@tsclass%2ftsclass/-/tsclass-3.0.16.tgz",
"integrity": "sha512-PX7r9gVSbxesHoVTBtty+eL+Ybmy4HVdrIlFdGFQVpT52chKvmHzndxIU0TUPh+MxaW0/EUNWJnw0gjQ4gbfew==",
"requires": {
"@pushrocks/tapbundle": "^3.2.1"
}
@ -368,7 +374,6 @@
"version": "1.7.2",
"resolved": "https://verdaccio.lossless.one/@types%2fcron/-/cron-1.7.2.tgz",
"integrity": "sha512-AEpNLRcsVSc5AdseJKNHpz0d4e8+ow+abTaC0fKDbAU86rF1evoFF0oC2fV9FdqtfVXkG2LKshpLTJCFOpyvTg==",
"dev": true,
"requires": {
"@types/node": "*",
"moment": ">=2.14.0"
@ -407,8 +412,7 @@
"@types/luxon": {
"version": "1.22.0",
"resolved": "https://verdaccio.lossless.one/@types%2fluxon/-/luxon-1.22.0.tgz",
"integrity": "sha512-riAvdx85rU7OXCrjW3f7dIf7fuJDrxck2Dkjd0weh6ul7q+wumrwe6+/tD8v7yOKnZAuEnTFF4FU7b+5W/I3bw==",
"dev": true
"integrity": "sha512-riAvdx85rU7OXCrjW3f7dIf7fuJDrxck2Dkjd0weh6ul7q+wumrwe6+/tD8v7yOKnZAuEnTFF4FU7b+5W/I3bw=="
},
"@types/mime-types": {
"version": "2.1.0",
@ -418,19 +422,17 @@
"@types/minimatch": {
"version": "3.0.3",
"resolved": "https://verdaccio.lossless.one/@types%2fminimatch/-/minimatch-3.0.3.tgz",
"integrity": "sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA==",
"dev": true
"integrity": "sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA=="
},
"@types/node": {
"version": "10.17.17",
"resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-10.17.17.tgz",
"integrity": "sha512-gpNnRnZP3VWzzj5k3qrpRC6Rk3H/uclhAVo1aIvwzK5p5cOrs9yEyQ8H/HBsBY0u5rrWxXEiVPQ0dEB6pkjE8Q=="
"version": "13.9.3",
"resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-13.9.3.tgz",
"integrity": "sha512-01s+ac4qerwd6RHD+mVbOEsraDHSgUaefQlEdBbUolnQFjKwCr7luvAlEwW1RFojh67u0z4OUTjPn9LEl4zIkA=="
},
"@types/shortid": {
"version": "0.0.29",
"resolved": "https://verdaccio.lossless.one/@types%2fshortid/-/shortid-0.0.29.tgz",
"integrity": "sha1-gJPuBBam4r8qpjOBCRFLP7/6Dps=",
"dev": true
"integrity": "sha1-gJPuBBam4r8qpjOBCRFLP7/6Dps="
},
"@types/through2": {
"version": "2.0.34",
@ -443,8 +445,7 @@
"@types/uuid": {
"version": "7.0.2",
"resolved": "https://verdaccio.lossless.one/@types%2fuuid/-/uuid-7.0.2.tgz",
"integrity": "sha512-8Ly3zIPTnT0/8RCU6Kg/G3uTICf9sRwYOpUzSIM3503tLIKcnJPRuinHhXngJUy2MntrEf6dlpOHXJju90Qh5w==",
"dev": true
"integrity": "sha512-8Ly3zIPTnT0/8RCU6Kg/G3uTICf9sRwYOpUzSIM3503tLIKcnJPRuinHhXngJUy2MntrEf6dlpOHXJju90Qh5w=="
},
"@types/which": {
"version": "1.3.2",
@ -692,7 +693,6 @@
"version": "1.8.2",
"resolved": "https://verdaccio.lossless.one/cron/-/cron-1.8.2.tgz",
"integrity": "sha512-Gk2c4y6xKEO8FSAUTklqtfSr7oTq0CiPQeLBG5Fl0qoXpZyMcj1SG59YL+hqq04bu6/IuEA7lMkYDAplQNKkyg==",
"dev": true,
"requires": {
"moment-timezone": "^0.5.x"
}
@ -934,8 +934,7 @@
"luxon": {
"version": "1.22.0",
"resolved": "https://verdaccio.lossless.one/luxon/-/luxon-1.22.0.tgz",
"integrity": "sha512-3sLvlfbFo+AxVEY3IqxymbumtnlgBwjDExxK60W3d+trrUzErNAz/PfvPT+mva+vEUrdIodeCOs7fB6zHtRSrw==",
"dev": true
"integrity": "sha512-3sLvlfbFo+AxVEY3IqxymbumtnlgBwjDExxK60W3d+trrUzErNAz/PfvPT+mva+vEUrdIodeCOs7fB6zHtRSrw=="
},
"make-error": {
"version": "1.3.6",
@ -988,14 +987,12 @@
"moment": {
"version": "2.24.0",
"resolved": "https://verdaccio.lossless.one/moment/-/moment-2.24.0.tgz",
"integrity": "sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg==",
"dev": true
"integrity": "sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg=="
},
"moment-timezone": {
"version": "0.5.28",
"resolved": "https://verdaccio.lossless.one/moment-timezone/-/moment-timezone-0.5.28.tgz",
"integrity": "sha512-TDJkZvAyKIVWg5EtVqRzU97w0Rb0YVbfpqyjgu6GwXCAohVRqwZjf4fOzDE6p1Ch98Sro/8hQQi65WDXW5STPw==",
"dev": true,
"requires": {
"moment": ">= 2.9.0"
}
@ -1008,8 +1005,7 @@
"nanoid": {
"version": "2.1.11",
"resolved": "https://verdaccio.lossless.one/nanoid/-/nanoid-2.1.11.tgz",
"integrity": "sha512-s/snB+WGm6uwi0WjsZdaVcuf3KJXlfGl2LcxgwkEwJF0D/BWzVWAZW/XY4bFaiR7s0Jk3FPvlnepg1H1b1UwlA==",
"dev": true
"integrity": "sha512-s/snB+WGm6uwi0WjsZdaVcuf3KJXlfGl2LcxgwkEwJF0D/BWzVWAZW/XY4bFaiR7s0Jk3FPvlnepg1H1b1UwlA=="
},
"once": {
"version": "1.4.0",
@ -1150,7 +1146,6 @@
"version": "6.5.4",
"resolved": "https://verdaccio.lossless.one/rxjs/-/rxjs-6.5.4.tgz",
"integrity": "sha512-naMQXcgEo3csAEGvw/NydRA0fuS2nDZJiw1YUWFKU7aPPAPGZEsD4Iimit96qwCieH6y614MCLYwdkrWx7z/7Q==",
"dev": true,
"requires": {
"tslib": "^1.9.0"
}
@ -1176,7 +1171,6 @@
"version": "2.2.15",
"resolved": "https://verdaccio.lossless.one/shortid/-/shortid-2.2.15.tgz",
"integrity": "sha512-5EaCy2mx2Jgc/Fdn9uuDuNIIfWBpzY4XIlhoqtXF6qsf+/+SGZ+FxDdX/ZsMZiWupIWNqAEmiNY4RC+LSmCeOw==",
"dev": true,
"requires": {
"nanoid": "^2.1.0"
}
@ -1261,8 +1255,7 @@
"symbol-tree": {
"version": "3.2.4",
"resolved": "https://verdaccio.lossless.one/symbol-tree/-/symbol-tree-3.2.4.tgz",
"integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==",
"dev": true
"integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw=="
},
"through2": {
"version": "3.0.1",
@ -1288,13 +1281,12 @@
"tslib": {
"version": "1.11.1",
"resolved": "https://verdaccio.lossless.one/tslib/-/tslib-1.11.1.tgz",
"integrity": "sha512-aZW88SY8kQbU7gpV19lN24LtXh/yD4ZZg6qieAJDDg+YBsJcSmLGK9QpnUjAKVG/xefmvJGd1WUmfpT/g6AJGA==",
"dev": true
"integrity": "sha512-aZW88SY8kQbU7gpV19lN24LtXh/yD4ZZg6qieAJDDg+YBsJcSmLGK9QpnUjAKVG/xefmvJGd1WUmfpT/g6AJGA=="
},
"tslint": {
"version": "5.20.1",
"resolved": "https://verdaccio.lossless.one/tslint/-/tslint-5.20.1.tgz",
"integrity": "sha512-EcMxhzCFt8k+/UP5r8waCf/lzmeSyVlqxqMEDQE7rWYiQky8KpIBz1JAoYXfROHrPZ1XXd43q8yQnULOLiBRQg==",
"version": "6.1.0",
"resolved": "https://verdaccio.lossless.one/tslint/-/tslint-6.1.0.tgz",
"integrity": "sha512-fXjYd/61vU6da04E505OZQGb2VCN2Mq3doeWcOIryuG+eqdmFUXTYVwdhnbEu2k46LNLgUYt9bI5icQze/j0bQ==",
"dev": true,
"requires": {
"@babel/code-frame": "^7.0.0",
@ -1308,7 +1300,7 @@
"mkdirp": "^0.5.1",
"resolve": "^1.3.2",
"semver": "^5.3.0",
"tslib": "^1.8.0",
"tslib": "^1.10.0",
"tsutils": "^2.29.0"
}
},
@ -1351,8 +1343,7 @@
"uuid": {
"version": "7.0.2",
"resolved": "https://verdaccio.lossless.one/uuid/-/uuid-7.0.2.tgz",
"integrity": "sha512-vy9V/+pKG+5ZTYKf+VcphF5Oc6EFiu3W8Nv3P3zIh0EqVI80ZxOzuPfe9EHjkFNvf8+xuTHVeei4Drydlx4zjw==",
"dev": true
"integrity": "sha512-vy9V/+pKG+5ZTYKf+VcphF5Oc6EFiu3W8Nv3P3zIh0EqVI80ZxOzuPfe9EHjkFNvf8+xuTHVeei4Drydlx4zjw=="
},
"wcwidth": {
"version": "1.0.1",

View File

@ -16,12 +16,13 @@
"@gitzone/tsbuild": "^2.0.22",
"@gitzone/tstest": "^1.0.15",
"@pushrocks/tapbundle": "^3.0.7",
"@types/node": "^10.11.7",
"tslint": "^5.11.0",
"@types/node": "^13.9.3",
"tslint": "^6.1.0",
"tslint-config-prettier": "^1.15.0"
},
"dependencies": {
"@tsclass/tsclass": "^3.0.13"
"@apiglobal/typedrequest": "^1.0.28",
"@tsclass/tsclass": "^3.0.16"
},
"files": [
"ts/**/*",

View File

@ -1,8 +1,20 @@
import { expect, tap } from '@pushrocks/tapbundle';
import * as sdk from '../ts/index';
import { ISimpleRequest } from '@tsclass/tsclass/dist_ts/network';
tap.test('first test', async () => {
console.log(sdk.standardExport);
tap.test('should create a valid Handler', async () => {
class MyHandler extends sdk.AAgHandler {
slug: 'testapi';
public async handleRequest(request: ISimpleRequest) {
// this.authenticationHandler
let response: any;
return response;
}
}
const myHandlerInstance = new MyHandler();
expect(myHandlerInstance).to.be.instanceOf(sdk.AAgHandler);
});
tap.start();

View File

@ -1,3 +1 @@
import * as plugins from './sdk.plugins';
export let standardExport = 'Hi there! :) This is an exported string';
export * from './sdk.classes.aghandler';

1
ts/interfaces/index.ts Normal file
View File

@ -0,0 +1 @@
export {};

View File

@ -0,0 +1,16 @@
import * as plugins from './sdk.plugins';
export abstract class AAgHandler {
public authenticationHandler: any;
/**
* a slug that separates the handler from other handlers
*/
public abstract slug: string;
public abstract handleRequest (request: plugins.tsclass.network.ISimpleRequest): Promise<plugins.tsclass.network.ISimpleResponse>;
public setAuthenticationHandler(authHandler) {
this.authenticationHandler = authHandler;
}
}

View File

@ -0,0 +1,3 @@
import * as plugins from './sdk.plugins';
export abstract class AAuthenticationHandler {}