mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 19:07:08 +00:00
Fix tests that were failing (#13972)
This commit is contained in:
parent
a8dc31d5a2
commit
2273809e3d
@ -17,21 +17,21 @@ arrayForEach(array, (i: number, index: number, array: Array<number>) => {
|
||||
|
||||
const resultThis: Array<{i: number, that: string}> = [];
|
||||
|
||||
arrayForEach(array, function(i: number) {
|
||||
arrayForEach(array, function(i) {
|
||||
resultThis.push({
|
||||
i: i,
|
||||
that: this.that
|
||||
});
|
||||
}, { that: 'jeff' });
|
||||
|
||||
arrayForEach(array, function(i: number, index: number) {
|
||||
arrayForEach(array, function(i, index) {
|
||||
resultThis.push({
|
||||
i: i + index,
|
||||
that: this.that
|
||||
});
|
||||
}, { that: 'jeff' });
|
||||
|
||||
arrayForEach(array, function(i: number, index: number, array: Array<number>) {
|
||||
arrayForEach(array, function(i, index, array) {
|
||||
resultThis.push({
|
||||
i: array[i],
|
||||
that: this.that
|
||||
|
||||
5
bootstrap.v3.datetimepicker/v3/package.json
Normal file
5
bootstrap.v3.datetimepicker/v3/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"moment": ">=2.14.0"
|
||||
}
|
||||
}
|
||||
5
content-disposition/index.d.ts
vendored
5
content-disposition/index.d.ts
vendored
@ -17,8 +17,5 @@ declare namespace contentDisposition {
|
||||
export function parse(contentDispositionHeader: string): ContentDisposition;
|
||||
}
|
||||
|
||||
declare function contentDisposition(): string;
|
||||
declare function contentDisposition(filename: undefined, options: contentDisposition.Options): string;
|
||||
declare function contentDisposition(filename: string, options?: contentDisposition.Options): string;
|
||||
|
||||
declare function contentDisposition(filename?: string, options?: contentDisposition.Options): string;
|
||||
export = contentDisposition;
|
||||
|
||||
2
cordova-sqlite-storage/index.d.ts
vendored
2
cordova-sqlite-storage/index.d.ts
vendored
@ -53,7 +53,7 @@ declare namespace SQLitePlugin {
|
||||
readTransaction(fn: TransactionFunction, error?: ErrorCallback, success?: SuccessCallback): void;
|
||||
|
||||
executeSql(statement: string, params?: any[], success?: StatementSuccessCallback, error?: ErrorCallback): void;
|
||||
sqlBatch (sqlStatements: Array<string|[string, any[]]>, success?: SuccessCallback, error?: ErrorCallback): void;
|
||||
sqlBatch(sqlStatements: Array<string|[string, any[]]>, success?: SuccessCallback, error?: ErrorCallback): void;
|
||||
|
||||
close(success?: SuccessCallback, error?: ErrorCallback): void;
|
||||
}
|
||||
|
||||
2
d3-scale/index.d.ts
vendored
2
d3-scale/index.d.ts
vendored
@ -18,7 +18,7 @@ import { CountableTimeInterval, TimeInterval } from 'd3-time';
|
||||
* The second generic corresponds to the data type of the return type of the interpolator.
|
||||
*/
|
||||
// This is a base interface to be extended, hence the suppression of the warning
|
||||
// tslint:disable-next-line:functional-interfaces
|
||||
// tslint:disable-next-line:callable-types
|
||||
export interface InterpolatorFactory<T, U> {
|
||||
/**
|
||||
* Construct a new interpolator function, based on the provided interpolation boundaries.
|
||||
|
||||
4
d3-shape/index.d.ts
vendored
4
d3-shape/index.d.ts
vendored
@ -1610,7 +1610,7 @@ export interface CurveGeneratorLineOnly {
|
||||
* A factory for curve generators addressing only lines, but not areas.
|
||||
*/
|
||||
// This is a base interface to be extended, hence the suppression of the warning
|
||||
// tslint:disable-next-line:functional-interfaces
|
||||
// tslint:disable-next-line:callable-types
|
||||
export interface CurveFactoryLineOnly {
|
||||
/**
|
||||
* Returns a "lines only" curve generator which renders to the specified context.
|
||||
@ -1646,7 +1646,7 @@ export interface CurveGenerator extends CurveGeneratorLineOnly {
|
||||
* A factory for curve generators addressing both lines and areas.
|
||||
*/
|
||||
// This is a base interface to be extended, hence the suppression of the warning
|
||||
// tslint:disable-next-line:functional-interfaces
|
||||
// tslint:disable-next-line:callable-types
|
||||
export interface CurveFactory {
|
||||
/**
|
||||
* Returns a curve generator which renders to the specified context.
|
||||
|
||||
@ -7073,7 +7073,7 @@ namespace TestIsError {
|
||||
let result: CustomError = value;
|
||||
}
|
||||
else {
|
||||
let result: number = value;
|
||||
let result: number = value as number;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -63,7 +63,7 @@ function makeRequest() {
|
||||
} else {
|
||||
details.displayItems.splice(1, 1, shippingOption);
|
||||
}
|
||||
|
||||
|
||||
details.shippingOptions = [shippingOption];
|
||||
} else {
|
||||
details.shippingOptions = [];
|
||||
@ -76,7 +76,7 @@ function makeRequest() {
|
||||
}
|
||||
|
||||
async function processPayment(): Promise<PaymentResponse> {
|
||||
let paymentResponse;
|
||||
let paymentResponse: PaymentResponse;
|
||||
try {
|
||||
paymentResponse = await makeRequest()
|
||||
} catch (error) {
|
||||
|
||||
3
plugapi/index.d.ts
vendored
3
plugapi/index.d.ts
vendored
@ -357,8 +357,7 @@ declare namespace PlugAPI {
|
||||
}
|
||||
|
||||
declare class PlugAPI {
|
||||
constructor(login: PlugAPI.PlugLogin, callback?: (error: Error, bot: PlugAPI) => void);
|
||||
constructor(login: PlugAPI.PlugLogin, callback?: (bot: PlugAPI) => void);
|
||||
constructor(login: PlugAPI.PlugLogin, callback?: (error: Error, bot: PlugAPI) => void | ((bot: PlugAPI) => void));
|
||||
deleteAllChat: boolean;
|
||||
multiLine: boolean;
|
||||
multiLineLimit: number;
|
||||
|
||||
24
random-seed/index.d.ts
vendored
24
random-seed/index.d.ts
vendored
@ -4,21 +4,21 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
export interface RandomSeed {
|
||||
range (range: number): number;
|
||||
random (): number;
|
||||
floatBetween (min: number, max: number): number;
|
||||
intBetween (min: number, max: number): number;
|
||||
range(range: number): number;
|
||||
random(): number;
|
||||
floatBetween(min: number, max: number): number;
|
||||
intBetween(min: number, max: number): number;
|
||||
|
||||
string (count: number): string;
|
||||
seed (seed: string): void;
|
||||
string(count: number): string;
|
||||
seed(seed: string): void;
|
||||
|
||||
cleanString (inStr: string): string;
|
||||
hashString (inStr: string): string;
|
||||
cleanString(inStr: string): string;
|
||||
hashString(inStr: string): string;
|
||||
|
||||
addEntropy (...args: any[]): void;
|
||||
initState (): void;
|
||||
addEntropy(...args: any[]): void;
|
||||
initState(): void;
|
||||
|
||||
done (): void;
|
||||
done(): void;
|
||||
}
|
||||
|
||||
export function create (seed?: string): RandomSeed;
|
||||
export function create(seed?: string): RandomSeed;
|
||||
|
||||
5
redux-action-utils/package.json
Normal file
5
redux-action-utils/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"redux": "^3.6.0"
|
||||
}
|
||||
}
|
||||
5
redux-immutable-state-invariant/package.json
Normal file
5
redux-immutable-state-invariant/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"redux": "^3.6.0"
|
||||
}
|
||||
}
|
||||
5
redux-immutable/package.json
Normal file
5
redux-immutable/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"redux": "^3.6.0"
|
||||
}
|
||||
}
|
||||
4
redux-localstorage-filter/index.d.ts
vendored
4
redux-localstorage-filter/index.d.ts
vendored
@ -5,5 +5,5 @@
|
||||
|
||||
import { StorageAdapter } from "redux-localstorage";
|
||||
|
||||
export function getSubset (obj: any, paths: string[]): any;
|
||||
export default function filter (paths?: string | string[]): <A>(adapter: StorageAdapter<A>) => StorageAdapter<A>;
|
||||
export function getSubset(obj: any, paths: string[]): any;
|
||||
export default function filter(paths?: string | string[]): <A>(adapter: StorageAdapter<A>) => StorageAdapter<A>;
|
||||
|
||||
4
redux-localstorage/index.d.ts
vendored
4
redux-localstorage/index.d.ts
vendored
@ -22,8 +22,8 @@ export type StorageAdapterCreator<A> = (storage: A) => StorageAdapter<A>;
|
||||
|
||||
export interface StorageAdapterEnhancer {}
|
||||
|
||||
export function mergePersistedState (merge?: <A1, A2>(initialState: A1, persistentState: A2) => A1 & A2): <A>(next: Redux.Reducer<A>) => Redux.Reducer<A>;
|
||||
export function mergePersistedState(merge?: <A1, A2>(initialState: A1, persistentState: A2) => A1 & A2): <A>(next: Redux.Reducer<A>) => Redux.Reducer<A>;
|
||||
|
||||
export default function persistState<A> (storage?: StorageAdapter<A>, key?: string, callback?: Function): Redux.GenericStoreEnhancer;
|
||||
export default function persistState<A>(storage?: StorageAdapter<A>, key?: string, callback?: Function): Redux.GenericStoreEnhancer;
|
||||
|
||||
export const actionTypes: ActionTypes;
|
||||
|
||||
5
redux-logger/package.json
Normal file
5
redux-logger/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"redux": "^3.6.0"
|
||||
}
|
||||
}
|
||||
5
redux-promise/package.json
Normal file
5
redux-promise/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"redux": "^3.6.0"
|
||||
}
|
||||
}
|
||||
5
redux-ui/package.json
Normal file
5
redux-ui/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"redux": "^3.6.0"
|
||||
}
|
||||
}
|
||||
@ -4,7 +4,7 @@
|
||||
"target": "es6",
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": false,
|
||||
"strictNullChecks": true,
|
||||
"strictNullChecks": false,
|
||||
"baseUrl": "../../",
|
||||
"typeRoots": [
|
||||
"../../"
|
||||
|
||||
6
table/index.d.ts
vendored
6
table/index.d.ts
vendored
@ -44,8 +44,8 @@ export interface TableUserConfig {
|
||||
columnDefault?: ColumnConfig;
|
||||
}
|
||||
|
||||
export function table (data: any[], userConfig?: TableUserConfig): string;
|
||||
export function table(data: any[], userConfig?: TableUserConfig): string;
|
||||
|
||||
export function createStream (userConfig: TableUserConfig): { write: string[] };
|
||||
export function createStream(userConfig: TableUserConfig): { write: string[] };
|
||||
|
||||
export function getBorderCharacters (templateName: borderType): JoinStruct;
|
||||
export function getBorderCharacters(templateName: borderType): JoinStruct;
|
||||
|
||||
5
transducers-js/package.json
Normal file
5
transducers-js/package.json
Normal file
@ -0,0 +1,5 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"immutable": "^3.8.1"
|
||||
}
|
||||
}
|
||||
3
verror/index.d.ts
vendored
3
verror/index.d.ts
vendored
@ -26,8 +26,7 @@ declare class VError extends Error {
|
||||
static fullStack(err: Error): string;
|
||||
|
||||
cause(): Error | undefined;
|
||||
constructor(options: VError.Options, message: string, ...params: any[]);
|
||||
constructor(cause: Error, message: string, ...params: any[]);
|
||||
constructor(options: VError.Options | Error, message: string, ...params: any[]);
|
||||
constructor(message: string, ...params: any[]);
|
||||
}
|
||||
|
||||
|
||||
6
webappsec-credential-management/index.d.ts
vendored
6
webappsec-credential-management/index.d.ts
vendored
@ -223,13 +223,9 @@ type CredentialBodyType = FormData|URLSearchParams;
|
||||
declare class PasswordCredential extends SiteBoundCredential {
|
||||
/**
|
||||
* @see {@link https://www.w3.org/TR/credential-management-1/#dom-passwordcredential-passwordcredential-data}
|
||||
*/
|
||||
constructor(data: PasswordCredentialData);
|
||||
|
||||
/**
|
||||
* @see {@link https://www.w3.org/TR/credential-management-1/#dom-passwordcredential-passwordcredential}
|
||||
*/
|
||||
constructor(form: HTMLFormElement);
|
||||
constructor(data: PasswordCredentialData | HTMLFormElement);
|
||||
|
||||
readonly type: 'password';
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user