Skip to content

Commit

Permalink
regression test #2543
Browse files Browse the repository at this point in the history
  • Loading branch information
liborm85 committed Feb 12, 2023
1 parent 72c48aa commit fb10d63
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions tests/unit/Node-interface.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
'use strict';

var pdfmake = require('../../js/index');

pdfmake.addFonts({
Roboto: {
normal: 'tests/fonts/Roboto-Regular.ttf',
bold: 'tests/fonts/Roboto-Medium.ttf',
italics: 'tests/fonts/Roboto-Italic.ttf',
bolditalics: 'tests/fonts/Roboto-MediumItalic.ttf'
}
});

describe('Node interface', function () {
describe('getBuffer', function () {
it('should return buffer', function () {

var docDefinition = {
content: [
'First paragraph',
'Another paragraph, this time a little bit longer to make sure, this line will be divided into at least two lines'
]
};

var pdf = pdfmake.createPdf(docDefinition);
pdf.getBuffer().then(() => {
//
}, err => {
throw err;
});

});

});
});

0 comments on commit fb10d63

Please sign in to comment.