aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/images.tests.js13
-rw-r--r--tests/mammoth.tests.js2
2 files changed, 14 insertions, 1 deletions
diff --git a/tests/images.tests.js b/tests/images.tests.js
new file mode 100644
index 0000000..7aac5a2
--- /dev/null
+++ b/tests/images.tests.js
@@ -0,0 +1,13 @@
+var assert = require("assert");
+
+var mammoth = require("../");
+
+var testing = require("./testing");
+var test = testing.test;
+
+
+describe('images', function() {
+ test('mammoth.images.inline() should be an alias of mammoth.images.imgElement()', function() {
+ assert.ok(mammoth.images.inline === mammoth.images.imgElement);
+ });
+});
diff --git a/tests/mammoth.tests.js b/tests/mammoth.tests.js
index 9d057f6..801bb02 100644
--- a/tests/mammoth.tests.js
+++ b/tests/mammoth.tests.js
@@ -174,7 +174,7 @@ describe('mammoth', function() {
test('src of inline images can be changed', function() {
var docxPath = path.join(__dirname, "test-data/tiny-picture.docx");
- var convertImage = mammoth.images.inline(function(element) {
+ var convertImage = mammoth.images.imgElement(function(element) {
return element.read("base64").then(function(encodedImage) {
return {src: encodedImage.substring(0, 2) + "," + element.contentType};
});