chore: move to swc/jest (#7739)
* chore: move to swc * chore: fix tax rate tests * chore: undo failed test * chore: fix unit tests script * chore: use node 20 * Update scripts/run-workspace-unit-tests-in-chunks.sh
This commit is contained in:
@@ -19,6 +19,7 @@ import {
|
||||
OptionalProps,
|
||||
PrimaryKey,
|
||||
Property,
|
||||
Rel,
|
||||
} from "@mikro-orm/core"
|
||||
import Cart from "./cart"
|
||||
import ShippingMethodAdjustment from "./shipping-method-adjustment"
|
||||
@@ -68,7 +69,7 @@ export default class ShippingMethod {
|
||||
cart_id: string
|
||||
|
||||
@ManyToOne({ entity: () => Cart, persist: false })
|
||||
cart: Cart
|
||||
cart: Rel<Cart>
|
||||
|
||||
@Property({ columnType: "text" })
|
||||
name: string
|
||||
@@ -83,7 +84,7 @@ export default class ShippingMethod {
|
||||
raw_amount: BigNumberRawValue
|
||||
|
||||
@Property({ columnType: "boolean" })
|
||||
is_tax_inclusive = false
|
||||
is_tax_inclusive: boolean = false
|
||||
|
||||
@ShippingOptionIdIndex()
|
||||
@Property({ columnType: "text", nullable: true })
|
||||
@@ -102,7 +103,7 @@ export default class ShippingMethod {
|
||||
cascade: [Cascade.PERSIST, "soft-remove"] as any,
|
||||
}
|
||||
)
|
||||
tax_lines = new Collection<ShippingMethodTaxLine>(this)
|
||||
tax_lines = new Collection<Rel<ShippingMethodTaxLine>>(this)
|
||||
|
||||
@OneToMany(
|
||||
() => ShippingMethodAdjustment,
|
||||
@@ -111,7 +112,7 @@ export default class ShippingMethod {
|
||||
cascade: [Cascade.PERSIST, "soft-remove"] as any,
|
||||
}
|
||||
)
|
||||
adjustments = new Collection<ShippingMethodAdjustment>(this)
|
||||
adjustments = new Collection<Rel<ShippingMethodAdjustment>>(this)
|
||||
|
||||
@Property({
|
||||
onCreate: () => new Date(),
|
||||
|
||||
Reference in New Issue
Block a user