From fceafa235a14a3f4d783c02e9529a1f96ecd64c3 Mon Sep 17 00:00:00 2001 From: Ryan Willoughby Date: Wed, 27 Mar 2013 11:46:26 -0700 Subject: [PATCH] [spec] more specs --- spec/barcodescanner.tests.js | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/spec/barcodescanner.tests.js b/spec/barcodescanner.tests.js index fd0dbdf..da74ce6 100644 --- a/spec/barcodescanner.tests.js +++ b/spec/barcodescanner.tests.js @@ -38,4 +38,15 @@ describe('Plugin object (window.plugins)', function () { expect(window.plugins.barcodeScanner.encode).toBeDefined(); expect(typeof window.plugins.barcodeScanner.encode == 'function').toBe(true); }); + + it("should contain three DestinationType constants", function() { + expect(BarcodeScanner.Encode.TEXT_TYPE).toBe("TEXT_TYPE"); + expect(BarcodeScanner.Encode.EMAIL_TYPE).toBe("EMAIL_TYPE"); + expect(BarcodeScanner.Encode.PHONE_TYPE).toBe("PHONE_TYPE"); + expect(BarcodeScanner.Encode.SMS_TYPE).toBe("SMS_TYPE"); + }); + + it("should call scan successfully", function() { + window.plugins.barcodeScanner.scan(function() {}, function() {}); + }); });