Fix timeout issues in Alpaca tests.
This commit is contained in:
@ -18,16 +18,11 @@ class AlpacaActivity {
|
||||
|
||||
export class AlpacaActionProvider {
|
||||
readonly alpaca: Alpaca;
|
||||
|
||||
|
||||
readonly fetchActions = (options: ActionFetchOptions): Promise<ActionFetchResponse> => {
|
||||
return (this.alpaca.getAccountActivities({
|
||||
activityTypes: "FILL",
|
||||
until: undefined as any,
|
||||
after: undefined as any,
|
||||
direction: "desc",
|
||||
date: undefined as any,
|
||||
pageSize: undefined as any,
|
||||
pageToken: undefined as any,
|
||||
}) as Promise<AlpacaActivity[]>).then((activities) => {
|
||||
return new ActionFetchResponse(
|
||||
activities
|
||||
@ -45,9 +40,9 @@ export class AlpacaActionProvider {
|
||||
}).catch((err) => {
|
||||
return err;
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
constructor(alpaca: Alpaca) {
|
||||
this.alpaca = alpaca;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -5,4 +5,4 @@ export * from './interface/actions';
|
||||
|
||||
export * from './alpaca/exchange';
|
||||
export * from './alpaca/portfolio';
|
||||
export * from './alpaca/quote';
|
||||
export * from './alpaca/quote';
|
||||
|
@ -100,7 +100,6 @@ export class ActionFetchOptions {
|
||||
* Represents the response of a fetch action request.
|
||||
*/
|
||||
export class ActionFetchResponse {
|
||||
|
||||
/**
|
||||
* An array of `Action` objects.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user