Skip to content

Commit

Permalink
(fix) Use Concerto exported in ergo-compiler package
Browse files Browse the repository at this point in the history
Signed-off-by: Jerome Simeon <[email protected]>
  • Loading branch information
jeromesimeon committed May 2, 2019
1 parent b060e48 commit e5ad5d6
Show file tree
Hide file tree
Showing 10 changed files with 28 additions and 31 deletions.
25 changes: 12 additions & 13 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion packages/cicero-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@
"@accordproject/cicero-engine": "0.12.1",
"@accordproject/cicero-tools": "0.12.1",
"@accordproject/cicero-test": "0.12.1",
"composer-concerto": "0.70.2",
"uuid": "3.3.2",
"yargs": "9.0.1"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/cicero-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
"webpack-cli": "^3.1.0"
},
"dependencies": {
"@accordproject/ergo-compiler": "0.8.1",
"@accordproject/ergo-compiler": "0.8.2",
"axios": "0.18.0",
"composer-concerto": "0.70.2",
"debug": "4.1.0",
Expand Down
12 changes: 6 additions & 6 deletions packages/cicero-core/src/grammarvisitor.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
'use strict';

const APModelManager = require('@accordproject/ergo-compiler').APModelManager;
const Field = require('composer-concerto').Field;
const ModelFile = require('composer-concerto').ModelFile;
const RelationshipDeclaration = require('composer-concerto').RelationshipDeclaration;
const EnumDeclaration = require('composer-concerto').EnumDeclaration;
const EnumValueDeclaration = require('composer-concerto').EnumValueDeclaration;
const ClassDeclaration = require('composer-concerto').ClassDeclaration;
const Field = require('@accordproject/ergo-compiler').ComposerConcerto.Field;
const ModelFile = require('@accordproject/ergo-compiler').ComposerConcerto.ModelFile;
const RelationshipDeclaration = require('@accordproject/ergo-compiler').ComposerConcerto.RelationshipDeclaration;
const EnumDeclaration = require('@accordproject/ergo-compiler').ComposerConcerto.EnumDeclaration;
const EnumValueDeclaration = require('@accordproject/ergo-compiler').ComposerConcerto.EnumValueDeclaration;
const ClassDeclaration = require('@accordproject/ergo-compiler').ComposerConcerto.ClassDeclaration;
const util = require('util');
const debug = require('debug')('cicero:grammarvisitor');

Expand Down
4 changes: 2 additions & 2 deletions packages/cicero-core/src/parsermanager.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
'use strict';

const fsPath = require('path');
const RelationshipDeclaration = require('composer-concerto').RelationshipDeclaration;
const Writer = require('composer-concerto').Writer;
const RelationshipDeclaration = require('@accordproject/ergo-compiler').ComposerConcerto.RelationshipDeclaration;
const Writer = require('@accordproject/ergo-compiler').ComposerConcerto.Writer;
const Logger = require('@accordproject/ergo-compiler').Logger;
const nearley = require('nearley');
const compile = require('nearley/lib/compile');
Expand Down
2 changes: 1 addition & 1 deletion packages/cicero-core/src/templateinstance.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const moment = require('moment-mini');
// Make sure Moment serialization preserves utcOffset. See https://momentjs.com/docs/#/displaying/as-json/
moment.fn.toJSON = Util.momentToJson;

const RelationshipDeclaration = require('composer-concerto').RelationshipDeclaration;
const RelationshipDeclaration = require('@accordproject/ergo-compiler').ComposerConcerto.RelationshipDeclaration;

/**
* A TemplateInstance is an instance of a Clause or Contract template. It is executable business logic, linked to
Expand Down
2 changes: 1 addition & 1 deletion packages/cicero-core/test/grammarvisitor.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

const APModelManager = require('@accordproject/ergo-compiler').APModelManager;
const Logger = require('@accordproject/ergo-compiler').Logger;
const Writer = require('composer-concerto').Writer;
const Writer = require('@accordproject/ergo-compiler').ComposerConcerto.Writer;
const GrammarVisitor = require('../lib/grammarvisitor');
const ParserManager = require('../lib/parsermanager');
const nunjucks = require('nunjucks');
Expand Down
4 changes: 2 additions & 2 deletions packages/cicero-core/test/template.js
Original file line number Diff line number Diff line change
Expand Up @@ -444,15 +444,15 @@ describe('Template', () => {

describe('#getFactory', () => {
it('should return a Factory', async () => {
const Factory = require('composer-concerto').Factory;
const Factory = require('@accordproject/ergo-compiler').ComposerConcerto.Factory;
const template = await Template.fromDirectory('./test/data/latedeliveryandpenalty');
template.getFactory().should.be.an.instanceof(Factory);
});
});

describe('#getSerializer', () => {
it('should return a Serializer', async () => {
const Serializer = require('composer-concerto').Serializer;
const Serializer = require('@accordproject/ergo-compiler').ComposerConcerto.Serializer;
const template = await Template.fromDirectory('./test/data/latedeliveryandpenalty');
template.getSerializer().should.be.an.instanceof(Serializer);
});
Expand Down
5 changes: 2 additions & 3 deletions packages/cicero-engine/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,8 @@
},
"dependencies": {
"@accordproject/cicero-core": "0.12.1",
"@accordproject/ergo-compiler": "0.8.1",
"@accordproject/ergo-engine": "0.8.1",
"composer-concerto": "0.70.2",
"@accordproject/ergo-compiler": "0.8.2",
"@accordproject/ergo-engine": "0.8.2",
"moment-mini": "2.22.1"
},
"license-check-config": {
Expand Down
2 changes: 1 addition & 1 deletion packages/cicero-test/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"dependencies": {
"@accordproject/cicero-core": "0.12.1",
"@accordproject/cicero-engine": "0.12.1",
"@accordproject/ergo-test": "0.8.1",
"@accordproject/ergo-test": "0.8.2",
"chai": "4.2.0",
"chai-things": "0.2.0",
"cucumber": "^5.1.0"
Expand Down

0 comments on commit e5ad5d6

Please sign in to comment.