From 0bcb4658eca981568d5cce48fd4b370c8778cbd6 Mon Sep 17 00:00:00 2001 From: abraaoalves Date: Sat, 12 Dec 2015 11:24:19 -0300 Subject: [PATCH] fix noimplicitAny errors --- cucumber/cucumber-tests.ts | 6 +++--- cucumber/cucumber.d.ts | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cucumber/cucumber-tests.ts b/cucumber/cucumber-tests.ts index ba7ff1f72e..f8b5606070 100644 --- a/cucumber/cucumber-tests.ts +++ b/cucumber/cucumber-tests.ts @@ -1,4 +1,4 @@ -/// +/// function StepSample() { type Callback = cucumber.CallbackStepDefinition; @@ -19,7 +19,7 @@ function StepSample() { callback(); }); - step.Given(/^I am on the Cucumber.js GitHub repository$/, function(callback) { + step.Given(/^I am on the Cucumber.js GitHub repository$/, function(callback:Callback) { this.visit('https://github.com/cucumber/cucumber-js', callback); }); @@ -27,7 +27,7 @@ function StepSample() { callback.pending(); }); - step.Then(/^I should see "(.*)" as the page title$/, { timeout:60*1000}, function(title:string, callback) { + step.Then(/^I should see "(.*)" as the page title$/, { timeout:60*1000}, function(title:string, callback:Callback) { var pageTitle = this.browser.text('title'); if (title === pageTitle) { diff --git a/cucumber/cucumber.d.ts b/cucumber/cucumber.d.ts index b70fbb6b46..75faeff7a5 100644 --- a/cucumber/cucumber.d.ts +++ b/cucumber/cucumber.d.ts @@ -31,7 +31,7 @@ declare module cucumber { } interface HookScenario{ - attach(text: string, mimeType?: string, callback?: (err?) => void): void; + attach(text: string, mimeType?: string, callback?: (err?:any) => void): void; isFailed() : boolean; } @@ -48,7 +48,7 @@ declare module cucumber { After(code: HookCode): void; Around(code: AroundCode):void; setDefaultTimeout(time:number): void; - registerHandler(handlerOption:string, code:(event, callback:CallbackStepDefinition) =>void): void; + registerHandler(handlerOption:string, code:(event:any, callback:CallbackStepDefinition) =>void): void; } }