1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-08-08 15:05:22 +02:00

rollback plaid changes in specs

This commit is contained in:
Tyler Myracle 2024-01-19 19:29:18 -06:00
parent d4984fba31
commit 18562477bf
3 changed files with 12 additions and 12 deletions

View file

@ -1,5 +1,5 @@
import type { User } from '@prisma/client'
import { PrismaClient, InvestmentTransactionCategory } from '@prisma/client'
import { PrismaClient } from '@prisma/client'
import { createLogger, transports } from 'winston'
import { DateTime } from 'luxon'
import {
@ -130,7 +130,7 @@ describe('balance sync strategies', () => {
amount: 100,
quantity: 10,
price: 10,
category: InvestmentTransactionCategory.buy,
plaidType: 'buy',
},
{
date: DateTime.fromISO('2023-02-04').toJSDate(),
@ -139,7 +139,7 @@ describe('balance sync strategies', () => {
amount: -50,
quantity: 5,
price: 10,
category: InvestmentTransactionCategory.sell,
plaidType: 'sell',
},
{
date: DateTime.fromISO('2023-02-04').toJSDate(),
@ -147,7 +147,6 @@ describe('balance sync strategies', () => {
amount: 50,
quantity: 50,
price: 1,
category: InvestmentTransactionCategory.other,
},
],
},

View file

@ -15,9 +15,6 @@ import { resetUser } from './utils/user'
jest.mock('../lib/teller.ts')
// For TypeScript support
//const teller = jest.mocked(_teller)
const authId = '__TEST_USER_ID__'
let axios: AxiosInstance
let user: User | null

View file

@ -1,5 +1,5 @@
import type { User } from '@prisma/client'
import { Prisma, PrismaClient, InvestmentTransactionCategory } from '@prisma/client'
import { Prisma, PrismaClient } from '@prisma/client'
import { createLogger, transports } from 'winston'
import { DateTime } from 'luxon'
import type {
@ -305,7 +305,8 @@ describe('insight service', () => {
amount: 50 * 100,
quantity: 50,
price: 100,
category: InvestmentTransactionCategory.buy,
plaidType: 'buy',
plaidSubtype: 'buy',
},
{
accountId: account.id,
@ -315,7 +316,8 @@ describe('insight service', () => {
amount: 10 * 200,
quantity: 10,
price: 200,
category: InvestmentTransactionCategory.buy,
plaidType: 'buy',
plaidSubtype: 'buy',
},
{
accountId: account.id,
@ -325,7 +327,8 @@ describe('insight service', () => {
amount: -20.22,
quantity: 0,
price: 0,
category: InvestmentTransactionCategory.dividend,
plaidType: 'cash',
plaidSubtype: 'dividend',
},
{
accountId: account.id,
@ -335,7 +338,8 @@ describe('insight service', () => {
amount: -22.85,
quantity: 0,
price: 0,
category: InvestmentTransactionCategory.dividend,
plaidType: 'cash',
plaidSubtype: 'dividend',
},
],
})