Return-Path: X-Original-To: apmail-cordova-commits-archive@www.apache.org Delivered-To: apmail-cordova-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2C37DC0EC for ; Fri, 13 Sep 2013 05:40:23 +0000 (UTC) Received: (qmail 69541 invoked by uid 500); 12 Sep 2013 23:35:45 -0000 Delivered-To: apmail-cordova-commits-archive@cordova.apache.org Received: (qmail 69265 invoked by uid 500); 12 Sep 2013 23:35:43 -0000 Mailing-List: contact commits-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list commits@cordova.apache.org Received: (qmail 69120 invoked by uid 99); 12 Sep 2013 23:35:42 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 12 Sep 2013 23:35:42 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 8D87D16A4B; Thu, 12 Sep 2013 23:35:42 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: steven@apache.org To: commits@cordova.apache.org Date: Thu, 12 Sep 2013 23:35:47 -0000 Message-Id: <4fa0d93478ab4c3792a98f9b9c696903@git.apache.org> In-Reply-To: <7cde985947fc4c799e7c9ee9b9860825@git.apache.org> References: <7cde985947fc4c799e7c9ee9b9860825@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [06/16] git commit: Fix broken tests for platform ls after my recent change. Fix broken tests for platform ls after my recent change. Project: http://git-wip-us.apache.org/repos/asf/cordova-cli/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-cli/commit/16be5589 Tree: http://git-wip-us.apache.org/repos/asf/cordova-cli/tree/16be5589 Diff: http://git-wip-us.apache.org/repos/asf/cordova-cli/diff/16be5589 Branch: refs/heads/ffos Commit: 16be5589ee17242e2ba71c1dd5c4c1a623ffc025 Parents: 66f15d2 Author: Braden Shepherdson Authored: Tue Sep 3 16:10:30 2013 -0400 Committer: Braden Shepherdson Committed: Tue Sep 3 16:10:30 2013 -0400 ---------------------------------------------------------------------- spec/platform.spec.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cordova-cli/blob/16be5589/spec/platform.spec.js ---------------------------------------------------------------------- diff --git a/spec/platform.spec.js b/spec/platform.spec.js index 0ec7954..fb1fbb1 100644 --- a/spec/platform.spec.js +++ b/spec/platform.spec.js @@ -101,14 +101,14 @@ describe('platform command', function() { expect(is_cordova).toHaveBeenCalled(); }); - describe('`ls`', function() { + describe('`ls`', function() { afterEach(function() { cordova.removeAllListeners('results'); }); it('should list out no platforms for a fresh project', function(done) { list_platforms.andReturn([]); cordova.on('results', function(res) { - expect(res).toEqual('No platforms added. Use `cordova platform add `.'); + expect(res).toMatch(/^Installed platforms:\s*Available platforms:.*$/); done(); }); cordova.platform('list'); @@ -116,7 +116,7 @@ describe('platform command', function() { it('should list out added platforms in a project', function(done) { cordova.on('results', function(res) { - expect(res.length).toEqual(5); + expect(res).toMatch(/^Installed platforms: ios, android, wp7, wp8, blackberry10\s*Available platforms:\s*$/); done(); }); cordova.platform('list');