Skip to content

Commit

Permalink
build: move npm-depends to top of package hooks
Browse files Browse the repository at this point in the history
  • Loading branch information
jankapunkt committed Aug 1, 2024
1 parent 19461bc commit 452c590
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions package.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ const dependencies = {
};

Package.onUse(function (api) {
Npm.depends(dependencies);
api.versionsFrom(['2.3', '3.0']);

api.use(['ecmascript', 'webapp', 'http@1.0.0 || 2.0.0']);
Expand All @@ -35,11 +36,16 @@ Package.onUse(function (api) {

api.mainModule('server/index.js', 'server');
api.mainModule('client/methods.js', 'client');
Npm.depends(dependencies);
});


Package.onTest(function (api) {
Npm.depends({
...dependencies,
'chai': '4.2.0',
'sinon': '7.1.1',
'sinon-chai': '3.2.0'
});
api.use('ecmascript');
api.use('lmieulet:meteor-legacy-coverage@0.4.0', 'server');
api.use(['lmieulet:meteor-coverage@4.3.0']);
Expand All @@ -48,11 +54,4 @@ Package.onTest(function (api) {
api.addFiles(['client/methods.e2e.tests.js', 'client/methods.unit.tests.js', 'client/client.instrumentation.tests.js'], 'client');
api.mainModule('server/tests.js', 'server');
api.mainModule('client/main.tests.js', 'client');

Npm.depends({
...dependencies,
'chai': '4.2.0',
'sinon': '7.1.1',
'sinon-chai': '3.2.0'
});
});

0 comments on commit 452c590

Please sign in to comment.