From 82d79008f1070bfd9bf9860bd2c15a508883fa6b Mon Sep 17 00:00:00 2001 From: Dario Russi <113150618+dariorussi@users.noreply.github.com> Date: Sat, 25 May 2024 12:38:15 +0200 Subject: [PATCH] =?UTF-8?q?Revert=20"Add=20quantity=5Fmin=5Ftick=20to=20De?= =?UTF-8?q?epBook.=20Quantity=20must=20be=20divisible=E2=80=A6=20(#17927)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit … by this amount, rather than lot_size. (#17335)" This reverts commit d2425d62253189ea81660a7964150e14531a1814. Describe the changes or additions included in this PR. How did you test the new or updated feature? --- Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required. For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates. - [ ] Protocol: - [ ] Nodes (Validators and Full nodes): - [ ] Indexer: - [ ] JSON-RPC: - [ ] GraphQL: - [ ] CLI: - [ ] Rust SDK: --------- Co-authored-by: Timothy Zakian --- crates/sui-framework/docs/deepbook/clob_v2.md | 69 +- .../packages/deepbook/sources/clob_v2.move | 70 +- .../packages/deepbook/tests/clob_tests.move | 675 +++++++----------- .../deepbook/tests/order_query_tests.move | 6 +- 4 files changed, 329 insertions(+), 491 deletions(-) diff --git a/crates/sui-framework/docs/deepbook/clob_v2.md b/crates/sui-framework/docs/deepbook/clob_v2.md index 2b23bac7715fc..a27130f823c94 100644 --- a/crates/sui-framework/docs/deepbook/clob_v2.md +++ b/crates/sui-framework/docs/deepbook/clob_v2.md @@ -1176,11 +1176,11 @@ do not have this capability: - + -
const EInvalidTickSizeMinSize: u64 = 20;
+
const EInvalidTickSizeLotSize: u64 = 20;
 
@@ -1203,15 +1203,6 @@ do not have this capability: - - - - -
const LOT_SIZE: u64 = 1000;
-
- - - @@ -1437,7 +1428,7 @@ Destroy the given pool_owner_cap object -
fun create_pool_<BaseAsset, QuoteAsset>(taker_fee_rate: u64, maker_rebate_rate: u64, tick_size: u64, min_size: u64, creation_fee: balance::Balance<sui::SUI>, ctx: &mut tx_context::TxContext)
+
fun create_pool_<BaseAsset, QuoteAsset>(taker_fee_rate: u64, maker_rebate_rate: u64, tick_size: u64, lot_size: u64, creation_fee: balance::Balance<sui::SUI>, ctx: &mut tx_context::TxContext)
 
@@ -1450,7 +1441,7 @@ Destroy the given pool_owner_cap object taker_fee_rate: u64, maker_rebate_rate: u64, tick_size: u64, - min_size: u64, + lot_size: u64, creation_fee: Balance<SUI>, ctx: &mut TxContext, ) { @@ -1458,7 +1449,7 @@ Destroy the given pool_owner_cap object taker_fee_rate, maker_rebate_rate, tick_size, - min_size, + lot_size, creation_fee, ctx ); @@ -1478,7 +1469,7 @@ Destroy the given pool_owner_cap object -
public fun create_pool<BaseAsset, QuoteAsset>(tick_size: u64, min_size: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext)
+
public fun create_pool<BaseAsset, QuoteAsset>(tick_size: u64, lot_size: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext)
 
@@ -1489,13 +1480,13 @@ Destroy the given pool_owner_cap object
public fun create_pool<BaseAsset, QuoteAsset>(
     tick_size: u64,
-    min_size: u64,
+    lot_size: u64,
     creation_fee: Coin<SUI>,
     ctx: &mut TxContext,
 ) {
     create_customized_pool<BaseAsset, QuoteAsset>(
         tick_size,
-        min_size,
+        lot_size,
         REFERENCE_TAKER_FEE_RATE,
         REFERENCE_MAKER_REBATE_RATE,
         creation_fee,
@@ -1517,7 +1508,7 @@ The taker_fee_rate should be greater than or equal to the maker_rebate_rate, and
 Taker_fee_rate of 0.25% should be 2_500_000 for example
 
 
-
public fun create_customized_pool<BaseAsset, QuoteAsset>(tick_size: u64, min_size: u64, taker_fee_rate: u64, maker_rebate_rate: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext)
+
public fun create_customized_pool<BaseAsset, QuoteAsset>(tick_size: u64, lot_size: u64, taker_fee_rate: u64, maker_rebate_rate: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext)
 
@@ -1528,7 +1519,7 @@ Taker_fee_rate of 0.25% should be 2_500_000 for example
public fun create_customized_pool<BaseAsset, QuoteAsset>(
     tick_size: u64,
-    min_size: u64,
+    lot_size: u64,
     taker_fee_rate: u64,
     maker_rebate_rate: u64,
     creation_fee: Coin<SUI>,
@@ -1538,7 +1529,7 @@ Taker_fee_rate of 0.25% should be 2_500_000 for example
         taker_fee_rate,
         maker_rebate_rate,
         tick_size,
-        min_size,
+        lot_size,
         coin::into_balance(creation_fee),
         ctx
     )
@@ -1556,7 +1547,7 @@ Taker_fee_rate of 0.25% should be 2_500_000 for example
 Helper function that all the create pools now call to create pools.
 
 
-
fun create_pool_with_return_<BaseAsset, QuoteAsset>(taker_fee_rate: u64, maker_rebate_rate: u64, tick_size: u64, min_size: u64, creation_fee: balance::Balance<sui::SUI>, ctx: &mut tx_context::TxContext): (clob_v2::Pool<BaseAsset, QuoteAsset>, clob_v2::PoolOwnerCap)
+
fun create_pool_with_return_<BaseAsset, QuoteAsset>(taker_fee_rate: u64, maker_rebate_rate: u64, tick_size: u64, lot_size: u64, creation_fee: balance::Balance<sui::SUI>, ctx: &mut tx_context::TxContext): (clob_v2::Pool<BaseAsset, QuoteAsset>, clob_v2::PoolOwnerCap)
 
@@ -1569,7 +1560,7 @@ Helper function that all the create pools now call to create pools. taker_fee_rate: u64, maker_rebate_rate: u64, tick_size: u64, - min_size: u64, + lot_size: u64, creation_fee: Balance<SUI>, ctx: &mut TxContext, ): (Pool<BaseAsset, QuoteAsset>, PoolOwnerCap) { @@ -1578,7 +1569,7 @@ Helper function that all the create pools now call to create pools. let base_type_name = type_name::get<BaseAsset>(); let quote_type_name = type_name::get<QuoteAsset>(); - assert!(clob_math::unsafe_mul(min_size, tick_size) > 0, EInvalidTickSizeMinSize); + assert!(clob_math::unsafe_mul(lot_size, tick_size) > 0, EInvalidTickSizeLotSize); assert!(base_type_name != quote_type_name, EInvalidPair); assert!(taker_fee_rate >= maker_rebate_rate, EInvalidFeeRateRebateRate); @@ -1597,7 +1588,7 @@ Helper function that all the create pools now call to create pools. taker_fee_rate, maker_rebate_rate, tick_size, - lot_size: min_size, + lot_size, }); (Pool<BaseAsset, QuoteAsset> { id: pool_uid, @@ -1609,7 +1600,7 @@ Helper function that all the create pools now call to create pools. taker_fee_rate, maker_rebate_rate, tick_size, - lot_size: min_size, + lot_size, base_custodian: custodian::new<BaseAsset>(ctx), quote_custodian: custodian::new<QuoteAsset>(ctx), creation_fee, @@ -1630,7 +1621,7 @@ Helper function that all the create pools now call to create pools. Function for creating an external pool. This API can be used to wrap deepbook pools into other objects. -
public fun create_pool_with_return<BaseAsset, QuoteAsset>(tick_size: u64, min_size: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext): clob_v2::Pool<BaseAsset, QuoteAsset>
+
public fun create_pool_with_return<BaseAsset, QuoteAsset>(tick_size: u64, lot_size: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext): clob_v2::Pool<BaseAsset, QuoteAsset>
 
@@ -1641,13 +1632,13 @@ Function for creating an external pool. This API can be used to wrap deepbook po
public fun create_pool_with_return<BaseAsset, QuoteAsset>(
     tick_size: u64,
-    min_size: u64,
+    lot_size: u64,
     creation_fee: Coin<SUI>,
     ctx: &mut TxContext,
 ): Pool<BaseAsset, QuoteAsset> {
     create_customized_pool_with_return<BaseAsset, QuoteAsset>(
         tick_size,
-        min_size,
+        lot_size,
         REFERENCE_TAKER_FEE_RATE,
         REFERENCE_MAKER_REBATE_RATE,
         creation_fee,
@@ -1669,7 +1660,7 @@ The taker_fee_rate should be greater than or equal to the maker_rebate_rate, and
 Taker_fee_rate of 0.25% should be 2_500_000 for example
 
 
-
public fun create_customized_pool_with_return<BaseAsset, QuoteAsset>(tick_size: u64, min_size: u64, taker_fee_rate: u64, maker_rebate_rate: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext): clob_v2::Pool<BaseAsset, QuoteAsset>
+
public fun create_customized_pool_with_return<BaseAsset, QuoteAsset>(tick_size: u64, lot_size: u64, taker_fee_rate: u64, maker_rebate_rate: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext): clob_v2::Pool<BaseAsset, QuoteAsset>
 
@@ -1680,7 +1671,7 @@ Taker_fee_rate of 0.25% should be 2_500_000 for example
public fun create_customized_pool_with_return<BaseAsset, QuoteAsset>(
     tick_size: u64,
-    min_size: u64,
+    lot_size: u64,
     taker_fee_rate: u64,
     maker_rebate_rate: u64,
     creation_fee: Coin<SUI>,
@@ -1690,7 +1681,7 @@ Taker_fee_rate of 0.25% should be 2_500_000 for example
         taker_fee_rate,
         maker_rebate_rate,
         tick_size,
-        min_size,
+        lot_size,
         coin::into_balance(creation_fee),
         ctx
     );
@@ -1712,7 +1703,7 @@ If a user wants to create a pool and then destroy/lock the pool_owner_cap one ca
 so with this function.
 
 
-
public fun create_customized_pool_v2<BaseAsset, QuoteAsset>(tick_size: u64, min_size: u64, taker_fee_rate: u64, maker_rebate_rate: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext): (clob_v2::Pool<BaseAsset, QuoteAsset>, clob_v2::PoolOwnerCap)
+
public fun create_customized_pool_v2<BaseAsset, QuoteAsset>(tick_size: u64, lot_size: u64, taker_fee_rate: u64, maker_rebate_rate: u64, creation_fee: coin::Coin<sui::SUI>, ctx: &mut tx_context::TxContext): (clob_v2::Pool<BaseAsset, QuoteAsset>, clob_v2::PoolOwnerCap)
 
@@ -1723,7 +1714,7 @@ so with this function.
public fun create_customized_pool_v2<BaseAsset, QuoteAsset>(
     tick_size: u64,
-    min_size: u64,
+    lot_size: u64,
     taker_fee_rate: u64,
     maker_rebate_rate: u64,
     creation_fee: Coin<SUI>,
@@ -1733,7 +1724,7 @@ so with this function.
         taker_fee_rate,
         maker_rebate_rate,
         tick_size,
-        min_size,
+        lot_size,
         coin::into_balance(creation_fee),
         ctx
     )
@@ -2178,8 +2169,8 @@ so with this function.
                         filled_quote_quantity_without_commission,
                         maker_order.price
                     );
-                    let filled_base_lot = filled_base_quantity / LOT_SIZE;
-                    filled_base_quantity = filled_base_lot * LOT_SIZE;
+                    let filled_base_lot = filled_base_quantity / pool.lot_size;
+                    filled_base_quantity = filled_base_lot * pool.lot_size;
                     // filled_quote_quantity_without_commission = 0 is permitted here since filled_base_quantity could be 0
                     filled_quote_quantity_without_commission = clob_math::unsafe_mul(
                         filled_base_quantity,
@@ -2802,8 +2793,7 @@ Place a market order to the order book.
     // We start with the bid PriceLevel with the highest price by calling max_leaf on the bids Critbit Tree.
     // The inner loop for iterating over the open orders in ascending orders of order id is the same as above.
     // Then iterate over the price levels in descending order until the market order is completely filled.
-    let min_size = pool.lot_size;
-    assert!(quantity >= min_size && quantity % LOT_SIZE == 0, EInvalidQuantity);
+    assert!(quantity % pool.lot_size == 0, EInvalidQuantity);
     assert!(quantity != 0, EInvalidQuantity);
     let metadata;
     if (is_bid) {
@@ -3094,8 +3084,7 @@ So please check that boolean value first before using the order id.
     assert!(quantity > 0, EInvalidQuantity);
     assert!(price > 0, EInvalidPrice);
     assert!(price % pool.tick_size == 0, EInvalidPrice);
-    let min_size = pool.lot_size;
-    assert!(quantity >= min_size && quantity % LOT_SIZE == 0, EInvalidQuantity);
+    assert!(quantity % pool.lot_size == 0, EInvalidQuantity);
     assert!(expire_timestamp > clock::timestamp_ms(clock), EInvalidExpireTimestamp);
     let owner = account_owner(account_cap);
     let original_quantity = quantity;
diff --git a/crates/sui-framework/packages/deepbook/sources/clob_v2.move b/crates/sui-framework/packages/deepbook/sources/clob_v2.move
index 102c4f0999a35..1fac57595f7cf 100644
--- a/crates/sui-framework/packages/deepbook/sources/clob_v2.move
+++ b/crates/sui-framework/packages/deepbook/sources/clob_v2.move
@@ -36,7 +36,7 @@ module deepbook::clob_v2 {
     const EInvalidPair: u64 = 16;
     const EInvalidFee: u64 = 18;
     const EInvalidExpireTimestamp: u64 = 19;
-    const EInvalidTickSizeMinSize: u64 = 20;
+    const EInvalidTickSizeLotSize: u64 = 20;
     const EInvalidSelfMatchingPreventionArg: u64 = 21;
 
     // <<<<<<<<<<<<<<<<<<<<<<<< Error codes <<<<<<<<<<<<<<<<<<<<<<<<
@@ -58,8 +58,6 @@ module deepbook::clob_v2 {
     const MIN_ASK_ORDER_ID: u64 = 1 << 63;
     const MIN_PRICE: u64 = 0;
     const MAX_PRICE: u64 = (1u128 << 64 - 1) as u64;
-    // Trade quantities must be in multiples of 1000. The lot_size in the pool structs is used as min_size.
-    const LOT_SIZE: u64 = 1000;
     #[test_only]
     const TIMESTAMP_INF: u64 = (1u128 << 64 - 1) as u64;
     const REFERENCE_TAKER_FEE_RATE: u64 = 2_500_000;
@@ -82,7 +80,7 @@ module deepbook::clob_v2 {
         // 10^9 scaling
         maker_rebate_rate: u64,
         tick_size: u64,
-        lot_size: u64, // lot_size in this context is the minimum trade size.
+        lot_size: u64,
     }
 
     /// Emitted when a maker order is injected into the order book.
@@ -253,7 +251,7 @@ module deepbook::clob_v2 {
         // 10^9 scaling
         maker_rebate_rate: u64,
         tick_size: u64,
-        lot_size: u64, // lot_size in this context is the minimum trade size.
+        lot_size: u64,
         // other pool info
         base_custodian: Custodian,
         quote_custodian: Custodian,
@@ -344,7 +342,7 @@ module deepbook::clob_v2 {
         taker_fee_rate: u64,
         maker_rebate_rate: u64,
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         creation_fee: Balance,
         ctx: &mut TxContext,
     ) {
@@ -352,7 +350,7 @@ module deepbook::clob_v2 {
             taker_fee_rate,
             maker_rebate_rate,
             tick_size,
-            min_size,
+            lot_size,
             creation_fee,
             ctx
         );
@@ -363,13 +361,13 @@ module deepbook::clob_v2 {
 
     public fun create_pool(
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         creation_fee: Coin,
         ctx: &mut TxContext,
     ) {
         create_customized_pool(
             tick_size,
-            min_size,
+            lot_size,
             REFERENCE_TAKER_FEE_RATE,
             REFERENCE_MAKER_REBATE_RATE,
             creation_fee,
@@ -382,7 +380,7 @@ module deepbook::clob_v2 {
     /// Taker_fee_rate of 0.25% should be 2_500_000 for example
     public fun create_customized_pool(
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         taker_fee_rate: u64,
         maker_rebate_rate: u64,
         creation_fee: Coin,
@@ -392,7 +390,7 @@ module deepbook::clob_v2 {
             taker_fee_rate,
             maker_rebate_rate,
             tick_size,
-            min_size,
+            lot_size,
             coin::into_balance(creation_fee),
             ctx
         )
@@ -403,7 +401,7 @@ module deepbook::clob_v2 {
         taker_fee_rate: u64,
         maker_rebate_rate: u64,
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         creation_fee: Balance,
         ctx: &mut TxContext,
     ): (Pool, PoolOwnerCap) {
@@ -412,7 +410,7 @@ module deepbook::clob_v2 {
         let base_type_name = type_name::get();
         let quote_type_name = type_name::get();
 
-        assert!(clob_math::unsafe_mul(min_size, tick_size) > 0, EInvalidTickSizeMinSize);
+        assert!(clob_math::unsafe_mul(lot_size, tick_size) > 0, EInvalidTickSizeLotSize);
         assert!(base_type_name != quote_type_name, EInvalidPair);
         assert!(taker_fee_rate >= maker_rebate_rate, EInvalidFeeRateRebateRate);
 
@@ -431,7 +429,7 @@ module deepbook::clob_v2 {
             taker_fee_rate,
             maker_rebate_rate,
             tick_size,
-            lot_size: min_size,
+            lot_size,
         });
         (Pool {
             id: pool_uid,
@@ -443,7 +441,7 @@ module deepbook::clob_v2 {
             taker_fee_rate,
             maker_rebate_rate,
             tick_size,
-            lot_size: min_size,
+            lot_size,
             base_custodian: custodian::new(ctx),
             quote_custodian: custodian::new(ctx),
             creation_fee,
@@ -455,13 +453,13 @@ module deepbook::clob_v2 {
     /// Function for creating an external pool. This API can be used to wrap deepbook pools into other objects.
     public fun create_pool_with_return(
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         creation_fee: Coin,
         ctx: &mut TxContext,
     ): Pool {
         create_customized_pool_with_return(
             tick_size,
-            min_size,
+            lot_size,
             REFERENCE_TAKER_FEE_RATE,
             REFERENCE_MAKER_REBATE_RATE,
             creation_fee,
@@ -475,7 +473,7 @@ module deepbook::clob_v2 {
     /// Taker_fee_rate of 0.25% should be 2_500_000 for example
     public fun create_customized_pool_with_return(
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         taker_fee_rate: u64,
         maker_rebate_rate: u64,
         creation_fee: Coin,
@@ -485,7 +483,7 @@ module deepbook::clob_v2 {
             taker_fee_rate,
             maker_rebate_rate,
             tick_size,
-            min_size,
+            lot_size,
             coin::into_balance(creation_fee),
             ctx
         );
@@ -498,7 +496,7 @@ module deepbook::clob_v2 {
     /// so with this function.
     public fun create_customized_pool_v2(
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         taker_fee_rate: u64,
         maker_rebate_rate: u64,
         creation_fee: Coin,
@@ -508,7 +506,7 @@ module deepbook::clob_v2 {
             taker_fee_rate,
             maker_rebate_rate,
             tick_size,
-            min_size,
+            lot_size,
             coin::into_balance(creation_fee),
             ctx
         )
@@ -776,8 +774,8 @@ module deepbook::clob_v2 {
                             filled_quote_quantity_without_commission,
                             maker_order.price
                         );
-                        let filled_base_lot = filled_base_quantity / LOT_SIZE;
-                        filled_base_quantity = filled_base_lot * LOT_SIZE;
+                        let filled_base_lot = filled_base_quantity / pool.lot_size;
+                        filled_base_quantity = filled_base_lot * pool.lot_size;
                         // filled_quote_quantity_without_commission = 0 is permitted here since filled_base_quantity could be 0
                         filled_quote_quantity_without_commission = clob_math::unsafe_mul(
                             filled_base_quantity,
@@ -1300,8 +1298,7 @@ module deepbook::clob_v2 {
         // We start with the bid PriceLevel with the highest price by calling max_leaf on the bids Critbit Tree.
         // The inner loop for iterating over the open orders in ascending orders of order id is the same as above.
         // Then iterate over the price levels in descending order until the market order is completely filled.
-        let min_size = pool.lot_size;
-        assert!(quantity >= min_size && quantity % LOT_SIZE == 0, EInvalidQuantity);
+        assert!(quantity % pool.lot_size == 0, EInvalidQuantity);
         assert!(quantity != 0, EInvalidQuantity);
         let metadata;
         if (is_bid) {
@@ -1512,8 +1509,7 @@ module deepbook::clob_v2 {
         assert!(quantity > 0, EInvalidQuantity);
         assert!(price > 0, EInvalidPrice);
         assert!(price % pool.tick_size == 0, EInvalidPrice);
-        let min_size = pool.lot_size;
-        assert!(quantity >= min_size && quantity % LOT_SIZE == 0, EInvalidQuantity);
+        assert!(quantity % pool.lot_size == 0, EInvalidQuantity);
         assert!(expire_timestamp > clock::timestamp_ms(clock), EInvalidExpireTimestamp);
         let owner = account_owner(account_cap);
         let original_quantity = quantity;
@@ -2244,12 +2240,12 @@ module deepbook::clob_v2 {
     #[test_only] public struct USD {}
 
     #[test_only]
-    public fun setup_test_with_tick_min(
+    public fun setup_test_with_tick_lot(
         taker_fee_rate: u64,
         maker_rebate_rate: u64,
         // tick size with scaling
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         scenario: &mut Scenario,
         sender: address,
     ) {
@@ -2264,7 +2260,7 @@ module deepbook::clob_v2 {
                 taker_fee_rate,
                 maker_rebate_rate,
                 tick_size,
-                min_size,
+                lot_size,
                 balance::create_for_testing(FEE_AMOUNT_FOR_CREATE_POOL),
                 test_scenario::ctx(scenario)
             );
@@ -2286,12 +2282,12 @@ module deepbook::clob_v2 {
     }
 
     #[test_only]
-    public fun setup_test_with_tick_min_and_wrapped_pool(
+    public fun setup_test_with_tick_lot_and_wrapped_pool(
         taker_fee_rate: u64,
         maker_rebate_rate: u64,
         // tick size with scaling
         tick_size: u64,
-        min_size: u64,
+        lot_size: u64,
         scenario: &mut Scenario,
         sender: address,
     ) {
@@ -2306,7 +2302,7 @@ module deepbook::clob_v2 {
                 taker_fee_rate,
                 maker_rebate_rate,
                 tick_size,
-                min_size,
+                lot_size,
                 balance::create_for_testing(FEE_AMOUNT_FOR_CREATE_POOL),
                 test_scenario::ctx(scenario)
             );
@@ -2325,7 +2321,7 @@ module deepbook::clob_v2 {
         scenario: &mut Scenario,
         sender: address,
     ) {
-        setup_test_with_tick_min(
+        setup_test_with_tick_lot(
             taker_fee_rate,
             maker_rebate_rate,
             1 * FLOAT_SCALING,
@@ -2342,7 +2338,7 @@ module deepbook::clob_v2 {
         scenario: &mut Scenario,
         sender: address,
     ) {
-        setup_test_with_tick_min_and_wrapped_pool(
+        setup_test_with_tick_lot_and_wrapped_pool(
             taker_fee_rate,
             maker_rebate_rate,
             1 * FLOAT_SCALING,
@@ -3173,8 +3169,8 @@ module deepbook::clob_v2 {
     }
 
     #[test]
-    #[expected_failure(abort_code = EInvalidTickSizeMinSize)]
-    fun test_create_pool_invalid_tick_size_min_size() {
+    #[expected_failure(abort_code = EInvalidTickSizeLotSize)]
+    fun test_create_pool_invalid_tick_size_lot_size() {
         let owner: address = @0xAAAA;
         let mut test = test_scenario::begin(owner);
         test_scenario::next_tx(&mut test, owner);
diff --git a/crates/sui-framework/packages/deepbook/tests/clob_tests.move b/crates/sui-framework/packages/deepbook/tests/clob_tests.move
index 58563a1673fb5..f2771a2cdce98 100644
--- a/crates/sui-framework/packages/deepbook/tests/clob_tests.move
+++ b/crates/sui-framework/packages/deepbook/tests/clob_tests.move
@@ -65,12 +65,6 @@ module deepbook::clob_test {
     #[test] fun test_inject_and_match_taker_bid_with_quote_quantity_partial_lot(
     ) { let _ = test_inject_and_match_taker_bid_with_quote_quantity_partial_lot_(scenario()); }
 
-    #[test] fun test_swap_exact_base_for_quote_min_size(
-    ) { let _ = test_swap_exact_base_for_quote_min_size_(scenario()); }
-
-    #[test, expected_failure(abort_code = clob::EInvalidQuantity)] fun test_place_order_less_than_min_size_error(
-    ) { let _ = test_place_order_less_than_min_size_error_(scenario()); }
-
     #[test] fun test_inject_and_match_taker_bid() { let _ = test_inject_and_match_taker_bid_(scenario()); }
 
     #[test] fun test_inject_and_match_taker_bid_with_skip_self_matching() { let _ = test_inject_and_match_taker_bid_with_skipping_self_matching_(scenario()); }
@@ -1241,8 +1235,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -1257,7 +1251,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                2000,
+                200,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1270,7 +1264,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                3000,
+                300,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1283,7 +1277,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1296,7 +1290,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 20 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1310,13 +1304,13 @@ module deepbook::clob_test {
             assert!(next_ask_order_id == clob::order_id_for_test(1, false));
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 10000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 55000, 45000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 5500, 4500);
             let (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
             assert!(base_avail == 0);
-            assert!(base_locked == 10000);
-            assert!(quote_avail == 55000);
-            assert!(quote_locked == 45000);
+            assert!(base_locked == 1000);
+            assert!(quote_avail == 5500);
+            assert!(quote_locked == 4500);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -1336,14 +1330,14 @@ module deepbook::clob_test {
             let mut pool = test::take_shared>(&test);
             let clock = test::take_shared(&test);
             let account_cap = test::take_from_address(&test, bob);
-            let (coin1, coin2) = clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_BOB, 6000,
+            let (coin1, coin2) = clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_BOB, 600,
                 false,
-                mint_for_testing(6000, ctx(&mut test)),
+                mint_for_testing(600, ctx(&mut test)),
                 mint_for_testing(0, ctx(&mut test)),
                 &clock,
                 ctx(&mut test));
             assert!(coin::value(&coin1) == 0);
-            assert!(coin::value(&coin2) == 27000 - 135);
+            assert!(coin::value(&coin2) == 2700 - 14);
             burn_for_testing(coin1);
             burn_for_testing(coin2);
             test::return_shared(pool);
@@ -1359,14 +1353,14 @@ module deepbook::clob_test {
             let mut pool = test::take_shared>(&test);
             let clock = test::take_shared(&test);
             let account_cap = test::take_from_address(&test, bob);
-            let (coin1, coin2) =clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_BOB, 1000,
+            let (coin1, coin2) =clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_BOB, 100,
                 false,
-                mint_for_testing(6000, ctx(&mut test)),
+                mint_for_testing(600, ctx(&mut test)),
                 mint_for_testing(0, ctx(&mut test)),
                 &clock,
                 ctx(&mut test));
-            assert!(coin::value(&coin1) == 5000);
-            assert!(coin::value(&coin2) == 1990);
+            assert!(coin::value(&coin1) == 500);
+            assert!(coin::value(&coin2) == 199);
             burn_for_testing(coin1);
             burn_for_testing(coin2);
             test::return_shared(pool);
@@ -1399,8 +1393,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -1415,7 +1409,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                2000,
+                200,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1428,7 +1422,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                3000,
+                300,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1441,7 +1435,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1454,7 +1448,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 20 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1468,13 +1462,13 @@ module deepbook::clob_test {
             assert!(next_ask_order_id == clob::order_id_for_test(1, false));
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 10000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 55000, 45000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 5500, 4500);
             let (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
             assert!(base_avail == 0);
-            assert!(base_locked == 10000);
-            assert!(quote_avail == 55000);
-            assert!(quote_locked == 45000);
+            assert!(base_locked == 1000);
+            assert!(quote_avail == 5500);
+            assert!(quote_locked == 4500);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -1486,8 +1480,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -1502,7 +1496,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_BOB,
                 4 * FLOAT_SCALING,
-                4000,
+                400,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1511,8 +1505,8 @@ module deepbook::clob_test {
                 &account_cap,
                 ctx(&mut test)
             );
-            assert!(base_quantity_filled == 4000);
-            assert!(quote_quantity_filled == 19900);
+            assert!(base_quantity_filled == 400);
+            assert!(quote_quantity_filled == 1990);
             assert!(is_placed == false);
             assert!(order_id == 0);
 
@@ -1529,9 +1523,9 @@ module deepbook::clob_test {
             let clock = test::take_shared(&test);
 
             let  (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
-            assert!(base_avail == 6000);
+            assert!(base_avail == 600);
             assert!(base_locked == 0);
-            assert!(quote_avail == 119900);
+            assert!(quote_avail == 11990);
             assert!(quote_locked == 0);
 
             test::return_shared(pool);
@@ -1564,8 +1558,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -1580,7 +1574,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                2000,
+                200,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1593,7 +1587,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                3000,
+                300,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1606,7 +1600,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1619,7 +1613,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 20 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1633,13 +1627,13 @@ module deepbook::clob_test {
             assert!(next_ask_order_id == clob::order_id_for_test(1, false));
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 10000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 55000, 45000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 5500, 4500);
             let (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
             assert!(base_avail == 0);
-            assert!(base_locked == 10000);
-            assert!(quote_avail == 55000);
-            assert!(quote_locked == 45000);
+            assert!(base_locked == 1000);
+            assert!(quote_avail == 5500);
+            assert!(quote_locked == 4500);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -1651,8 +1645,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -1667,7 +1661,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_BOB,
                 6 * FLOAT_SCALING,
-                4000,
+                400,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1694,9 +1688,9 @@ module deepbook::clob_test {
             let clock = test::take_shared(&test);
 
             let  (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
-            assert!(base_avail == 6000);
-            assert!(base_locked == 4000);
-            assert!(quote_avail == 100000);
+            assert!(base_avail == 600);
+            assert!(base_locked == 400);
+            assert!(quote_avail == 10000);
             assert!(quote_locked == 0);
 
             test::return_shared(pool);
@@ -1712,7 +1706,7 @@ module deepbook::clob_test {
         let owner: address = @0xF;
         next_tx(&mut test, owner);
         {
-            clob::setup_test_with_tick_min(5000000, 2500000, 1_00_000_000, 10, &mut test, owner);
+            clob::setup_test_with_tick_lot(5000000, 2500000, 1_00_000_000, 10, &mut test, owner);
         };
         next_tx(&mut test, alice);
         {
@@ -1728,8 +1722,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -1744,7 +1738,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                2000,
+                200,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1757,7 +1751,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                3000,
+                300,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1770,7 +1764,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1783,7 +1777,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 20 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1793,17 +1787,17 @@ module deepbook::clob_test {
                 ctx(&mut test)
             );
             let (next_bid_order_id, next_ask_order_id, _, _) = clob::get_pool_stat(&pool);
-            assert!(next_bid_order_id == clob::order_id_for_test(3, true));
-            assert!(next_ask_order_id == clob::order_id_for_test(1, false));
+            assert!(next_bid_order_id == clob::order_id_for_test(3, true), 0);
+            assert!(next_ask_order_id == clob::order_id_for_test(1, false), 0);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 10000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 55000, 45000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 5500, 4500);
             let (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
-            assert!(base_avail == 0);
-            assert!(base_locked == 10000);
-            assert!(quote_avail == 55000);
-            assert!(quote_locked == 45000);
+            assert!(base_avail == 0, 0);
+            assert!(base_locked == 1000, 0);
+            assert!(quote_avail == 5500, 0);
+            assert!(quote_locked == 4500, 0);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -1815,13 +1809,13 @@ module deepbook::clob_test {
             let mut pool = test::take_shared>(&test);
             let clock = test::take_shared(&test);
             let account_cap = test::take_from_address(&test, bob);
-            let (coin1, coin2) = clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_BOB, 20000, false,
-                mint_for_testing(20000, ctx(&mut test)),
+            let (coin1, coin2) = clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_BOB, 2000, false,
+                mint_for_testing(2000, ctx(&mut test)),
                 mint_for_testing(0, ctx(&mut test)),
                 &clock,
                 ctx(&mut test));
-            assert!(coin::value(&coin1) == 5000);
-            assert!(coin::value(&coin2) == 44775);
+            assert!(coin::value(&coin1) == 500, 0);
+            assert!(coin::value(&coin2) == 4477, 0);
             burn_for_testing(coin1);
             burn_for_testing(coin2);
             test::return_shared(pool);
@@ -1837,7 +1831,7 @@ module deepbook::clob_test {
         // setup pool and custodian
         next_tx(&mut test, owner);
         {
-            clob::setup_test_with_tick_min(5000000, 2500000, 1_00_000_000, 10, &mut test, owner);
+            clob::setup_test_with_tick_lot(5000000, 2500000, 1_00_000_000, 10, &mut test, owner);
         };
         next_tx(&mut test, alice);
         {
@@ -1853,8 +1847,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -1869,7 +1863,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                5000,
+                500,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1882,7 +1876,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                5000,
+                500,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1895,7 +1889,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -1908,7 +1902,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 1 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -1922,13 +1916,13 @@ module deepbook::clob_test {
             assert!(next_ask_order_id == clob::order_id_for_test(3, false));
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 80000, 20000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 90000, 10000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 8000, 2000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 9000, 1000);
             let (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
-            assert!(base_avail == 80000);
-            assert!(base_locked == 20000);
-            assert!(quote_avail == 90000);
-            assert!(quote_locked == 10000);
+            assert!(base_avail == 8000);
+            assert!(base_locked == 2000);
+            assert!(quote_avail == 9000);
+            assert!(quote_locked == 1000);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -1940,13 +1934,13 @@ module deepbook::clob_test {
             let mut pool = test::take_shared>(&test);
             let clock = test::take_shared(&test);
             let account_cap = test::take_from_address(&test, bob);
-            let (coin1, coin2) = clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_BOB, 50000, true,
-                mint_for_testing(100000, ctx(&mut test)),
-                mint_for_testing(100000, ctx(&mut test)),
+            let (coin1, coin2) = clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_BOB, 5000, true,
+                mint_for_testing(10000, ctx(&mut test)),
+                mint_for_testing(10000, ctx(&mut test)),
                 &clock,
                 ctx(&mut test));
-            assert!(coin::value(&coin1) == 120000);
-            assert!(coin::value(&coin2) == 100000 - (70000 + 350));
+            assert!(coin::value(&coin1) == 12000);
+            assert!(coin::value(&coin2) == 10000 - (7000 + 36));
             burn_for_testing(coin1);
             burn_for_testing(coin2);
             test::return_shared(pool);
@@ -1978,17 +1972,17 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 10000, 10000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 1000, 1000, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,1 * FLOAT_SCALING, 100000, 100000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,1 * FLOAT_SCALING, 10000, 10000, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
 
             test::return_shared(pool);
@@ -2004,13 +1998,13 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_BOB,
                 &account_cap,
-                45000,
+                4500,
                 &clock,
-                mint_for_testing(45000, ctx(&mut test)),
+                mint_for_testing(4500, ctx(&mut test)),
                 ctx(&mut test)
             );
-            assert!(coin::value(&base_coin) == 10000 + 4000);
-            assert!(coin::value("e_coin) == 4800);
+            assert!(coin::value(&base_coin) == 1000 + 495);
+            assert!(coin::value("e_coin) == 2);
             burn_for_testing(base_coin);
             burn_for_testing(quote_coin);
 
@@ -2048,17 +2042,17 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,5 * FLOAT_SCALING, 5000, 5000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,5 * FLOAT_SCALING, 500, 500, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,5 * FLOAT_SCALING, 5000, 5000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,5 * FLOAT_SCALING, 500, 500, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,2 * FLOAT_SCALING, 10000, 10000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,2 * FLOAT_SCALING, 1000, 1000, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,10 * FLOAT_SCALING, 100000, 100000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,10 * FLOAT_SCALING, 10000, 10000, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
             test::return_shared(pool);
             test::return_to_address(alice, account_cap);
@@ -2073,8 +2067,8 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_BOB,
                 &account_cap,
-                15000,
-                mint_for_testing(15000, ctx(&mut test)),
+                1500,
+                mint_for_testing(1500, ctx(&mut test)),
                 mint_for_testing(0,  ctx(&mut test)),
                 &clock,
                 ctx(&mut test)
@@ -2084,7 +2078,7 @@ module deepbook::clob_test {
             clob::check_balance_invariants_for_account(&alice_account_cap, quote_custodian, base_custodian, &pool);
 
             assert!(coin::value(&base_coin) == 0);
-            assert!(coin::value("e_coin) == 59700);
+            assert!(coin::value("e_coin) == 5969);
             burn_for_testing(base_coin);
             burn_for_testing(quote_coin);
 
@@ -2667,7 +2661,7 @@ module deepbook::clob_test {
         {
             let mut pool = test::take_shared>(&test);
             let account_cap = test::take_from_address(&test, bob);
-            let (base_quantity_filled, quote_quantity_filled) = clob::test_match_bid_with_quote_quantity(&mut pool, &account_cap, CLIENT_ID_BOB, 5000, MAX_PRICE, 0);
+            let (base_quantity_filled, quote_quantity_filled) = clob::test_match_bid_with_quote_quantity(&mut pool, &account_cap, CLIENT_ID_BOB, 500, MAX_PRICE, 0);
             assert_eq(base_quantity_filled, 0);
             assert_eq(quote_quantity_filled, 0);
             test::return_to_address(bob, account_cap);
@@ -2679,17 +2673,17 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,  2 * FLOAT_SCALING, 10000, 10000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,  2 * FLOAT_SCALING, 1000, 1000, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,  1 * FLOAT_SCALING, 100000, 100000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,  1 * FLOAT_SCALING, 10000, 10000, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
             test::return_shared(pool);
             test::return_to_address(alice, account_cap);
@@ -2703,8 +2697,8 @@ module deepbook::clob_test {
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
 
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 0, 100000);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 80000, 20000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 0, 10000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 8000, 2000);
             let (next_bid_order_id, next_ask_order_id, _, _) = clob::get_pool_stat(&pool);
             assert!(next_bid_order_id == clob::order_id_for_test(1, true));
             assert!(next_ask_order_id == clob::order_id_for_test(3, false));
@@ -2713,11 +2707,11 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false, account_cap_user)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false, account_cap_user)
                 );
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(1, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false, account_cap_user)
+                    clob::test_construct_order(1, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false, account_cap_user)
                 );
                 let (_, _, _, asks) = get_pool_stat(&pool);
                 clob::check_tick_level(asks, 5 * FLOAT_SCALING, &open_orders);
@@ -2727,7 +2721,7 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(2, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 10000, 10000, false, account_cap_user)
+                    clob::test_construct_order(2, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 1000, 1000, false, account_cap_user)
                 );
                 let (_, _, _, asks) = get_pool_stat(&pool);
                 clob::check_tick_level(asks, 2 * FLOAT_SCALING, &open_orders);
@@ -2737,7 +2731,7 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 100000, 100000, true, account_cap_user)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 10000, 10000, true, account_cap_user)
                 );
                 let (_, _, bid, _) = get_pool_stat(&pool);
                 clob::check_tick_level(bid, 1 * FLOAT_SCALING, &open_orders);
@@ -2755,17 +2749,17 @@ module deepbook::clob_test {
                 &mut pool,
                 &account_cap,
                 CLIENT_ID_BOB,
-                45000,
+                4500,
                 MAX_PRICE,
                 0,
             );
-            assert!(base_quantity_filled == 10000 + 4000);
-            assert!(quote_quantity_filled == 40200);
+            assert!(base_quantity_filled == 1000 + 495);
+            assert!(quote_quantity_filled == 4498);
             let (base_quantity_filled, quote_quantity_filled) = clob::test_match_bid_with_quote_quantity(
                 &mut pool,
                 &account_cap,
                 CLIENT_ID_BOB,
-                5000,
+                500,
                 0,
                 0,
             );
@@ -2781,8 +2775,8 @@ module deepbook::clob_test {
             let account_cap_user_alice = account_owner(&account_cap_alice);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
 
-            custodian::assert_user_balance(quote_custodian, account_cap_user_alice, 40200 - 100 - 100 + 50 + 50, 100000);
-            custodian::assert_user_balance(base_custodian, account_cap_user_alice, 80000, 6000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user_alice, 4498 - 10 - 13 + 5 + 6, 10000);
+            custodian::assert_user_balance(base_custodian, account_cap_user_alice, 8000, 500 + 5);
             {
                 let (_, _, _, asks) = get_pool_stat(&pool);
                 clob::check_empty_tick_level(asks, 2 * FLOAT_SCALING);
@@ -2791,11 +2785,11 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE,  5 * FLOAT_SCALING, 5000, 1000, false, account_cap_user_alice)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE,  5 * FLOAT_SCALING, 5, 5, false, account_cap_user_alice)
                 );
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(1, CLIENT_ID_ALICE,  5 * FLOAT_SCALING, 5000, 5000, false, account_cap_user_alice)
+                    clob::test_construct_order(1, CLIENT_ID_ALICE,  5 * FLOAT_SCALING, 500, 500, false, account_cap_user_alice)
                 );
                 let (_, _, _, asks) = get_pool_stat(&pool);
                 clob::check_tick_level(asks, 5 * FLOAT_SCALING, &open_orders);
@@ -2805,7 +2799,7 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 100000, 100000, true, account_cap_user_alice)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 10000, 10000, true, account_cap_user_alice)
                 );
                 let (_, _, bid, _) = get_pool_stat(&pool);
                 clob::check_tick_level(bid, 1 * FLOAT_SCALING, &open_orders);
@@ -2815,15 +2809,15 @@ module deepbook::clob_test {
             let mut open_orders_cmp = vector::empty();
             vector::push_back(
                 &mut open_orders_cmp,
-                clob::test_construct_order(0, CLIENT_ID_ALICE,  5 * FLOAT_SCALING, 5000, 1000, false, account_cap_user_alice)
+                clob::test_construct_order(0, CLIENT_ID_ALICE,  5 * FLOAT_SCALING, 500, 5, false, account_cap_user_alice)
             );
             vector::push_back(
                 &mut open_orders_cmp,
-                clob::test_construct_order(1, CLIENT_ID_ALICE,  5 * FLOAT_SCALING, 5000, 5000, false, account_cap_user_alice)
+                clob::test_construct_order(1, CLIENT_ID_ALICE,  5 * FLOAT_SCALING, 500, 500, false, account_cap_user_alice)
             );
             vector::push_back(
                 &mut open_orders_cmp,
-                clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 100000, 100000, true, account_cap_user_alice)
+                clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 10000, 10000, true, account_cap_user_alice)
             );
             assert!(open_orders == open_orders_cmp);
             test::return_shared(pool);
@@ -2839,12 +2833,12 @@ module deepbook::clob_test {
                 &mut pool,
                &account_cap,
                 CLIENT_ID_BOB,
-                40000,
+                3000,
                 MAX_PRICE,
                 0,
             );
-            assert_eq(base_quantity_filled, 6000);
-            assert_eq(quote_quantity_filled, 30150);
+            assert_eq(base_quantity_filled, 505);
+            assert_eq(quote_quantity_filled, 2539);
             test::return_shared(pool);
             test::return_to_address(bob, account_cap);
         };
@@ -2873,7 +2867,7 @@ module deepbook::clob_test {
         // setup pool and custodian
         next_tx(&mut test, owner);
         {
-            clob::setup_test_with_tick_min(5000000, 2500000, 1 * FLOAT_SCALING, 100, &mut test, owner);
+            clob::setup_test_with_tick_lot(5000000, 2500000, 1 * FLOAT_SCALING, 100, &mut test, owner);
         };
         next_tx(&mut test, alice);
         {
@@ -2996,7 +2990,7 @@ module deepbook::clob_test {
         // setup pool and custodian
         next_tx(&mut test, owner);
         {
-            clob::setup_test_with_tick_min(5000000, 2500000, 1 * FLOAT_SCALING, 10, &mut test, owner);
+            clob::setup_test_with_tick_lot(5000000, 2500000, 1 * FLOAT_SCALING, 10, &mut test, owner);
         };
         next_tx(&mut test, alice);
         {
@@ -3012,17 +3006,17 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 10000, 10000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 1000, 1000, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 100000, 100000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 10000, 10000, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
             test::return_shared(pool);
             test::return_to_address(alice, account_cap);
@@ -3035,12 +3029,12 @@ module deepbook::clob_test {
                 &mut pool,
                 &account_cap,
                 CLIENT_ID_BOB,
-                45000,
+                4500,
                 MAX_PRICE,
                 0,
             );
-            assert!(base_quantity_filled == 10000 + 4000);
-            assert!(quote_quantity_filled == 40200);
+            assert!(base_quantity_filled == 1000 + 490);
+            assert!(quote_quantity_filled == 4473);
             test::return_shared(pool);
             test::return_to_address(bob, account_cap);
         };
@@ -3051,8 +3045,8 @@ module deepbook::clob_test {
             let account_cap_user_alice = account_owner(&account_cap_alice);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
 
-            custodian::assert_user_balance(quote_custodian, account_cap_user_alice, 40200 - 100 - 100 + 50 + 50, 100000);
-            custodian::assert_user_balance(base_custodian, account_cap_user_alice, 80000, 5000 + 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user_alice, 4473 - 10 - 13 + 5 + 6, 10000);
+            custodian::assert_user_balance(base_custodian, account_cap_user_alice, 8000, 500 + 10);
             {
                 let (_, _, _, asks) = get_pool_stat(&pool);
                 clob::check_empty_tick_level(asks, 2 * FLOAT_SCALING);
@@ -3061,11 +3055,11 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 1000, false, account_cap_user_alice)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 10, 10, false, account_cap_user_alice)
                 );
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(1, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false, account_cap_user_alice)
+                    clob::test_construct_order(1, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false, account_cap_user_alice)
                 );
                 let (_, _, _, asks) = get_pool_stat(&pool);
                 clob::check_tick_level(asks, 5 * FLOAT_SCALING, &open_orders);
@@ -3075,7 +3069,7 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 100000, 100000, true, account_cap_user_alice)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 10000, 10000, true, account_cap_user_alice)
                 );
                 let (_, _, bid, _) = get_pool_stat(&pool);
                 clob::check_tick_level(bid, 1 * FLOAT_SCALING, &open_orders);
@@ -3085,15 +3079,15 @@ module deepbook::clob_test {
             let mut open_orders_cmp = vector::empty();
             vector::push_back(
                 &mut open_orders_cmp,
-                clob::test_construct_order(0, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 1000, false, account_cap_user_alice)
+                clob::test_construct_order(0, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 10, false, account_cap_user_alice)
             );
             vector::push_back(
                 &mut open_orders_cmp,
-                clob::test_construct_order(1, CLIENT_ID_ALICE, 5 * FLOAT_SCALING,5000, 5000, false, account_cap_user_alice)
+                clob::test_construct_order(1, CLIENT_ID_ALICE, 5 * FLOAT_SCALING,500, 500, false, account_cap_user_alice)
             );
             vector::push_back(
                 &mut open_orders_cmp,
-                clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 100000, 100000, true, account_cap_user_alice)
+                clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 10000, 10000, true, account_cap_user_alice)
             );
             assert!(open_orders == open_orders_cmp);
             test::return_shared(pool);
@@ -3102,147 +3096,6 @@ module deepbook::clob_test {
         end(test)
     }
 
-    // This scenario tests a user trying to place an order that's greater than lot_size but less than min_size.
-    fun test_place_order_less_than_min_size_error_(mut test: Scenario): TransactionEffects {
-        let (alice, _) = people();
-        let owner: address = @0xF;
-        let min_size = 100000000; // 0.1 SUI
-        // setup pool and custodian
-        next_tx(&mut test, owner);
-        {
-            clob::setup_test_with_tick_min(0, 0, 1 * FLOAT_SCALING, min_size, &mut test, owner);
-        };
-        next_tx(&mut test, alice);
-        {
-            mint_account_cap_transfer(alice, test::ctx(&mut test));
-        };
-        next_tx(&mut test, alice);
-        {
-            let mut pool = test::take_shared>(&test);
-            let account_cap = test::take_from_sender(&test);
-            let account_cap_user = account_owner(&account_cap);
-            let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(10000000, ctx(&mut test)), account_cap_user);
-            test::return_shared(pool);
-            test::return_to_sender(&test, account_cap);
-        };
-
-        // alice places limit orders
-        next_tx(&mut test, alice);
-        {
-            let mut pool = test::take_shared>(&test);
-            let account_cap = test::take_from_address(&test, alice);
-            let clock = test::take_shared(&test);
-            clob::place_limit_order(
-                &mut pool,
-                CLIENT_ID_ALICE,
-                5 * FLOAT_SCALING,
-                10000000,
-                CANCEL_OLDEST,
-                true,
-                TIMESTAMP_INF,
-                0,
-                &clock,
-                &account_cap,
-                ctx(&mut test)
-            );
-            test::return_shared(pool);
-            test::return_shared(clock);
-            test::return_to_address(alice, account_cap);
-        };
-        end(test)
-    }
-
-    fun test_swap_exact_base_for_quote_min_size_(mut test: Scenario): TransactionEffects {
-        let (alice, bob) = people();
-        let owner = @0xF;
-        let min_size = 100000000; // 0.1 SUI
-        let lot_size = 1000;
-        // setup pool and custodian
-        next_tx(&mut test, owner);
-        {
-            clob::setup_test_with_tick_min(0, 0, 1 * FLOAT_SCALING, min_size, &mut test, owner);
-        };
-        next_tx(&mut test, alice);
-        {
-            mint_account_cap_transfer(alice, test::ctx(&mut test));
-        };
-        next_tx(&mut test, bob);
-        {
-            mint_account_cap_transfer(bob, test::ctx(&mut test));
-        };
-        next_tx(&mut test, alice);
-        {
-            // assuming 9 decimal points, alice gets 5 SUI and 5 USDC
-            // alice places a limit buy of 0.2 SUI at $4, costing her 0.8 USDC
-            // alice places a limit sell of 0.2 SUI at $5, costing her 0.2 SUI
-            let mut pool = test::take_shared>(&test);
-            let account_cap = test::take_from_address(&test, alice);
-            let account_cap_user = account_owner(&account_cap);
-            let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 50 * min_size;
-            let alice_deposit_USDC: u64 = 50 * min_size;
-            custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
-            custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 4 * FLOAT_SCALING, 2 * min_size, 2 * min_size, true,
-                CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 2 * min_size, 2 * min_size, false,
-                CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            test::return_shared(pool);
-            test::return_to_address(alice, account_cap);
-        };
-        next_tx(&mut test, bob);
-        {
-            let pool = test::take_shared>(&test);
-            let account_cap_alice = test::take_from_address(&test, alice);
-            let account_cap_user_alice = account_owner(&account_cap_alice);
-            let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-
-            // alice has 4.2 USDC available and 0.8 USDC locked
-            custodian::assert_user_balance(quote_custodian, account_cap_user_alice, 4_200_000_000, 800_000_000);
-            // alice has 4.8 SUI available and 0.2 SUI locked
-            custodian::assert_user_balance(base_custodian, account_cap_user_alice, 4_800_000_000, 200_000_000);
-            test::return_shared(pool);
-            test::return_to_address(alice, account_cap_alice);
-        };
-        next_tx(&mut test, bob);
-        {
-            // bob pays 0.5001 USDC to buy as much SUI from the market as possible. He is matched against alice's $5 limit order.
-            let mut pool = test::take_shared>(&test);
-            let account_cap = test::take_from_address(&test, bob);
-            let (base_quantity_filled, quote_quantity_filled) = clob::test_match_bid_with_quote_quantity(
-                &mut pool,
-                &account_cap,
-                CLIENT_ID_BOB,
-                500_100_000,
-                MAX_PRICE,
-                0,
-            );
-            // bob's 0.5 USDC fills the minimum of 0.1 SUI and an additional 20 lots, 0.0002 at $5.
-            assert!(base_quantity_filled == 1 * min_size + (20 * lot_size));
-            // all of bob's quote asset was filled.
-            assert!(quote_quantity_filled == 500_100_000);
-            test::return_shared(pool);
-            test::return_to_address(bob, account_cap);
-        };
-        next_tx(&mut test, bob);
-        {
-            let pool = test::take_shared>(&test);
-            let account_cap_alice = test::take_from_address(&test, alice);
-            let account_cap_user_alice = account_owner(&account_cap_alice);
-            let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-
-            // alice received bob's 0.5001 USDC, increasing the available balance to 4.7001 USDC
-            custodian::assert_user_balance(quote_custodian, account_cap_user_alice, 4_700_100_000, 800_000_000);
-            // alice's locked SUI was reduced by 0.10002 SUI
-            custodian::assert_user_balance(base_custodian, account_cap_user_alice, 4_800_000_000, 99_980_000);
-            test::return_shared(pool);
-            test::return_to_address(alice, account_cap_alice);
-        };
-        end(test)
-    }
-
     fun test_inject_and_match_taker_bid_(mut test: Scenario): TransactionEffects {
         let (alice, bob) = people();
         let owner = @0xF;
@@ -3705,16 +3558,16 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
             clob::test_inject_limit_order_with_expiration(
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                5000,
-                5000,
+                500,
+                500,
                 false,
                 CANCEL_OLDEST,
                 TIMESTAMP_INF,
@@ -3725,8 +3578,8 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                5000,
-                5000,
+                500,
+                500,
                 false,
                 CANCEL_OLDEST,
                 0,
@@ -3737,8 +3590,8 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
-                10000,
+                1000,
+                1000,
                 false,
                 CANCEL_OLDEST,
                 TIMESTAMP_INF,
@@ -3749,8 +3602,8 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 1 * FLOAT_SCALING,
-                100000,
-                100000,
+                10000,
+                10000,
                 true,
                 CANCEL_OLDEST,
                 0,
@@ -3767,8 +3620,8 @@ module deepbook::clob_test {
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
 
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 0, 100000);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 80000, 20000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 0, 10000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 8000, 2000);
             let (next_bid_order_id, next_ask_order_id, _, _) = clob::get_pool_stat(&pool);
             assert!(next_bid_order_id == clob::order_id_for_test(1, true));
             assert!(next_ask_order_id == clob::order_id_for_test(3, false));
@@ -3781,8 +3634,8 @@ module deepbook::clob_test {
                         0,
                         CLIENT_ID_ALICE,
                         5 * FLOAT_SCALING,
-                        5000,
-                        5000,
+                        500,
+                        500,
                         false,
                         account_cap_user,
                         TIMESTAMP_INF
@@ -3796,7 +3649,7 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order_with_expiration(1, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 5000, 5000, false, account_cap_user, 0)
+                    clob::test_construct_order_with_expiration(1, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 500, 500, false, account_cap_user, 0)
                 );
                 vector::push_back(
                     &mut open_orders,
@@ -3804,8 +3657,8 @@ module deepbook::clob_test {
                         2,
                         CLIENT_ID_ALICE,
                         2 * FLOAT_SCALING,
-                        10000,
-                        10000,
+                        1000,
+                        1000,
                         false,
                         account_cap_user,
                         TIMESTAMP_INF
@@ -3819,7 +3672,7 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 100000, 100000, true, account_cap_user)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 10000, 10000, true, account_cap_user)
                 );
                 let (_, _, bid, _) = get_pool_stat(&pool);
                 clob::check_tick_level(bid, 1 * FLOAT_SCALING, &open_orders);
@@ -3837,12 +3690,12 @@ module deepbook::clob_test {
                 &mut pool,
                 &account_cap,
                 CLIENT_ID_BOB,
-                45000,
+                4500,
                 MAX_PRICE,
                 1,
             );
-            assert!(base_quantity_filled == 10000 + 4000);
-            assert!(quote_quantity_filled == 40200);
+            assert!(base_quantity_filled == 1000 + 495);
+            assert!(quote_quantity_filled == 4498);
             test::return_shared(pool);
             test::return_to_address(bob, account_cap);
         };
@@ -3853,8 +3706,8 @@ module deepbook::clob_test {
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
             // rebate fee in base asset 3
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 40200 - 100 - 100 + 50 + 50, 100000);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 85000, 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 4498 - 10 - 13 + 5 + 6, 10000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 8500, 5);
             {
                 let (_, _, _, asks) = get_pool_stat(&pool);
                 clob::check_empty_tick_level(asks, 2 * FLOAT_SCALING);
@@ -3863,7 +3716,7 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 1000, false, account_cap_user)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5, 5, false, account_cap_user)
                 );
                 let (_, _, _, asks) = get_pool_stat(&pool);
                 clob::check_tick_level(asks, 5 * FLOAT_SCALING, &open_orders);
@@ -3873,7 +3726,7 @@ module deepbook::clob_test {
                 let mut open_orders = vector::empty();
                 vector::push_back(
                     &mut open_orders,
-                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 100000, 100000, true, account_cap_user)
+                    clob::test_construct_order(0, CLIENT_ID_ALICE, 1 * FLOAT_SCALING, 10000, 10000, true, account_cap_user)
                 );
                 let (_, _, bid, _) = get_pool_stat(&pool);
                 clob::check_tick_level(bid, 1 * FLOAT_SCALING, &open_orders);
@@ -5087,8 +4940,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -5103,7 +4956,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                2000,
+                200,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -5116,7 +4969,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                3000,
+                300,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -5129,7 +4982,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -5142,7 +4995,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 20 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -5156,13 +5009,13 @@ module deepbook::clob_test {
             assert!(next_ask_order_id == clob::order_id_for_test(1, false));
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 10000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 55000, 45000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 5500, 4500);
             let (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
             assert!(base_avail == 0);
-            assert!(base_locked == 10000);
-            assert!(quote_avail == 55000);
-            assert!(quote_locked == 45000);
+            assert!(base_locked == 1000);
+            assert!(quote_avail == 5500);
+            assert!(quote_locked == 4500);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -5174,21 +5027,21 @@ module deepbook::clob_test {
             let mut pool = test::take_shared>(&test);
             let clock = test::take_shared(&test);
             let account_cap = test::take_from_address(&test, alice);
-            let (coin1, coin2) =clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_ALICE, 6000,
+            let (coin1, coin2) =clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_ALICE, 600,
                 false,
-                mint_for_testing(6000, ctx(&mut test)),
+                mint_for_testing(600, ctx(&mut test)),
                 mint_for_testing(0, ctx(&mut test)),
                 &clock,
                 ctx(&mut test));
-            assert!(coin::value(&coin1) == 6000);
+            assert!(coin::value(&coin1) == 600);
             assert!(coin::value(&coin2) == 0);
             burn_for_testing(coin1);
             burn_for_testing(coin2);
 
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 10000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 100000, 0);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 10000, 0);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -5220,8 +5073,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(15000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1500, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -5236,7 +5089,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                2000,
+                200,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -5249,7 +5102,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                3000,
+                300,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -5262,7 +5115,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -5275,7 +5128,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 1 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -5289,13 +5142,13 @@ module deepbook::clob_test {
             assert!(next_ask_order_id == clob::order_id_for_test(3, false));
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 15000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 90000, 10000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 1500);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 9000, 1000);
             let (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
             assert!(base_avail == 0);
-            assert!(base_locked == 15000);
-            assert!(quote_avail == 90000);
-            assert!(quote_locked == 10000);
+            assert!(base_locked == 1500);
+            assert!(quote_avail == 9000);
+            assert!(quote_locked == 1000);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -5307,21 +5160,21 @@ module deepbook::clob_test {
             let mut pool = test::take_shared>(&test);
             let clock = test::take_shared(&test);
             let account_cap = test::take_from_address(&test, alice);
-            let (coin1, coin2) =clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_ALICE, 1000,
+            let (coin1, coin2) =clob::place_market_order(&mut pool, &account_cap, CLIENT_ID_ALICE, 1,
                 true,
                 mint_for_testing(0, ctx(&mut test)),
-                mint_for_testing(1000, ctx(&mut test)),
+                mint_for_testing(1, ctx(&mut test)),
                 &clock,
                 ctx(&mut test));
             assert!(coin::value(&coin1) == 0);
-            assert!(coin::value(&coin2) == 1000);
+            assert!(coin::value(&coin2) == 1);
             burn_for_testing(coin1);
             burn_for_testing(coin2);
 
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 15000, 0);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 90000, 10000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 1500, 0);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 9000, 1000);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -5353,8 +5206,8 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
-            custodian::deposit(quote_custodian, mint_for_testing(100000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(1000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(quote_custodian, mint_for_testing(10000, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -5368,7 +5221,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                2000,
+                200,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -5381,7 +5234,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 5 * FLOAT_SCALING,
-                3000,
+                300,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -5394,7 +5247,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 2 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 true,
                 TIMESTAMP_INF,
@@ -5407,7 +5260,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 20 * FLOAT_SCALING,
-                10000,
+                1000,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -5421,13 +5274,13 @@ module deepbook::clob_test {
             assert!(next_ask_order_id == clob::order_id_for_test(1, false));
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 10000);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 55000, 45000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 0, 1000);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 5500, 4500);
             let (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
             assert!(base_avail == 0);
-            assert!(base_locked == 10000);
-            assert!(quote_avail == 55000);
-            assert!(quote_locked == 45000);
+            assert!(base_locked == 1000);
+            assert!(quote_avail == 5500);
+            assert!(quote_locked == 4500);
             test::return_shared(pool);
             test::return_shared(clock);
             test::return_to_address(alice, account_cap);
@@ -5438,7 +5291,7 @@ module deepbook::clob_test {
             let account_cap = test::take_from_sender(&test);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, _) = clob::borrow_mut_custodian(&mut pool);
-            custodian::deposit(base_custodian, mint_for_testing(4000, ctx(&mut test)), account_cap_user);
+            custodian::deposit(base_custodian, mint_for_testing(400, ctx(&mut test)), account_cap_user);
             test::return_shared(pool);
             test::return_to_sender(&test, account_cap);
         };
@@ -5452,7 +5305,7 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 4 * FLOAT_SCALING,
-                4000,
+                400,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -5480,9 +5333,9 @@ module deepbook::clob_test {
 
             let  (base_avail, base_locked, quote_avail, quote_locked) = account_balance(&pool, &account_cap);
             assert!(base_avail == 0);
-            assert!(base_locked == 10000 + 4000);
-            assert!(quote_avail == 80000);
-            assert!(quote_locked == 20000);
+            assert!(base_locked == 1000 + 400);
+            assert!(quote_avail == 8000);
+            assert!(quote_locked == 2000);
 
             test::return_shared(pool);
             test::return_shared(clock);
@@ -5511,17 +5364,17 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 10000, 10000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 2 * FLOAT_SCALING, 1000, 1000, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,1 * FLOAT_SCALING, 100000, 100000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE,1 * FLOAT_SCALING, 10000, 10000, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
             test::return_shared(pool);
             test::return_to_address(alice, account_cap);
@@ -5536,20 +5389,20 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 &account_cap,
-                45000,
+                4500,
                 &clock,
-                mint_for_testing(45000, ctx(&mut test)),
+                mint_for_testing(4500, ctx(&mut test)),
                 ctx(&mut test)
             );
             assert!(coin::value(&base_coin) == 0);
-            assert!(coin::value("e_coin) == 45000);
+            assert!(coin::value("e_coin) == 4500);
             burn_for_testing(base_coin);
             burn_for_testing(quote_coin);
 
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_custodian(&pool);
-            custodian::assert_user_balance(base_custodian, account_cap_user, 100000, 0);
-            custodian::assert_user_balance(quote_custodian, account_cap_user, 0, 100000);
+            custodian::assert_user_balance(base_custodian, account_cap_user, 10000, 0);
+            custodian::assert_user_balance(quote_custodian, account_cap_user, 0, 10000);
 
             test::return_shared(clock);
             test::return_shared(pool);
@@ -6095,11 +5948,11 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 50000, 50000, false,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, false,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
             test::return_shared(pool);
             test::return_to_address(alice, account_cap);
@@ -6114,16 +5967,16 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_BOB,
                 &account_cap,
-                50000,
+                5000,
                 &clock,
-                mint_for_testing(50000, ctx(&mut test)),
+                mint_for_testing(5000, ctx(&mut test)),
                 ctx(&mut test)
             );
 
             let of_event = vector::borrow(&of_events, 0);
             let (_, _, is_bid, _, _, base_asset_quantity_filled, price, _ , _) = clob::matched_order_metadata_info(of_event);
             assert!(is_bid == false);
-            assert!(base_asset_quantity_filled == 9000);
+            assert!(base_asset_quantity_filled == 500);
             assert!(price == 5 * FLOAT_SCALING);
 
             burn_for_testing(base_coin);
@@ -6157,11 +6010,11 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
             test::return_shared(pool);
             test::return_to_address(alice, account_cap);
@@ -6176,8 +6029,8 @@ module deepbook::clob_test {
                 &mut pool,
                 CLIENT_ID_BOB,
                 &account_cap,
-                5000,
-                mint_for_testing(5000, ctx(&mut test)),
+                500,
+                mint_for_testing(500, ctx(&mut test)),
                 mint_for_testing(0, ctx(&mut test)),
                 &clock,
                 ctx(&mut test)
@@ -6186,7 +6039,7 @@ module deepbook::clob_test {
             let of_event = vector::borrow(&of_events, 0);
             let (_, _, is_bid, _, _, base_asset_quantity_filled, price, _ , _) = clob::matched_order_metadata_info(of_event);
             assert!(is_bid == true);
-            assert!(base_asset_quantity_filled == 5000);
+            assert!(base_asset_quantity_filled == 500);
             assert!(price == 5 * FLOAT_SCALING);
 
             burn_for_testing(base_coin);
@@ -6220,11 +6073,11 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
             test::return_shared(pool);
             test::return_to_address(alice, account_cap);
@@ -6239,9 +6092,9 @@ module deepbook::clob_test {
                 &mut pool,
                 &account_cap,
                 CLIENT_ID_BOB,
-                5000,
+                500,
                 false,
-                mint_for_testing(5000, ctx(&mut test)),
+                mint_for_testing(500, ctx(&mut test)),
                 mint_for_testing(0, ctx(&mut test)),
                 &clock,
                 ctx(&mut test)
@@ -6250,7 +6103,7 @@ module deepbook::clob_test {
             let of_event = vector::borrow(&of_events, 0);
             let (_, _, is_bid, _, _, base_asset_quantity_filled, price, _ , _) = clob::matched_order_metadata_info(of_event);
             assert!(is_bid == true);
-            assert!(base_asset_quantity_filled == 5000);
+            assert!(base_asset_quantity_filled == 500);
             assert!(price == 5 * FLOAT_SCALING);
 
             burn_for_testing(base_coin);
@@ -6284,11 +6137,11 @@ module deepbook::clob_test {
             let account_cap = test::take_from_address(&test, alice);
             let account_cap_user = account_owner(&account_cap);
             let (base_custodian, quote_custodian) = clob::borrow_mut_custodian(&mut pool);
-            let alice_deposit_WSUI: u64 = 100000;
-            let alice_deposit_USDC: u64 = 100000;
+            let alice_deposit_WSUI: u64 = 10000;
+            let alice_deposit_USDC: u64 = 10000;
             custodian::test_increase_user_available_balance(base_custodian, account_cap_user, alice_deposit_WSUI);
             custodian::test_increase_user_available_balance(quote_custodian, account_cap_user, alice_deposit_USDC);
-            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 5000, 5000, true,
+            clob::test_inject_limit_order(&mut pool, CLIENT_ID_ALICE, 5 * FLOAT_SCALING, 500, 500, true,
                 CANCEL_OLDEST, &account_cap, ctx(&mut test));
             test::return_shared(pool);
             test::return_to_address(alice, account_cap);
@@ -6299,14 +6152,14 @@ module deepbook::clob_test {
             let mut pool = test::take_shared>(&test);
             let clock = test::take_shared(&test);
             let account_cap = test::take_from_address(&test, bob);
-            let bob_deposit_WSUI: u64 = 100000;
+            let bob_deposit_WSUI: u64 = 10000;
             let (base_custodian, _) = clob::borrow_mut_custodian(&mut pool);
             custodian::test_increase_user_available_balance(base_custodian, account_owner(&account_cap), bob_deposit_WSUI);
             let (_, _, _, _, of_events) = clob::place_limit_order_with_metadata(
                 &mut pool,
                 CLIENT_ID_BOB,
                 5 * FLOAT_SCALING,
-                5000,
+                500,
                 CANCEL_OLDEST,
                 false,
                 TIMESTAMP_INF,
@@ -6319,7 +6172,7 @@ module deepbook::clob_test {
             let of_event = vector::borrow(&of_events, 0);
             let (_, _, is_bid, _, _, base_asset_quantity_filled, price, _ , _) = clob::matched_order_metadata_info(of_event);
             assert!(is_bid == true);
-            assert!(base_asset_quantity_filled == 5000);
+            assert!(base_asset_quantity_filled == 500);
             assert!(price == 5 * FLOAT_SCALING);
 
             test::return_shared(clock);
diff --git a/crates/sui-framework/packages/deepbook/tests/order_query_tests.move b/crates/sui-framework/packages/deepbook/tests/order_query_tests.move
index bb0adc6d3067e..e280b2708684e 100644
--- a/crates/sui-framework/packages/deepbook/tests/order_query_tests.move
+++ b/crates/sui-framework/packages/deepbook/tests/order_query_tests.move
@@ -306,10 +306,10 @@ module deepbook::order_query_tests {
         let account_cap = test_scenario::take_from_sender(&scenario);
         let account_cap_user = account_owner(&account_cap);
         let (base_custodian, quote_custodian) = clob_v2::borrow_mut_custodian(&mut pool);
-        custodian_v2::deposit(base_custodian, mint_for_testing(10000000, ctx(&mut scenario)), account_cap_user);
+        custodian_v2::deposit(base_custodian, mint_for_testing(1000000, ctx(&mut scenario)), account_cap_user);
         custodian_v2::deposit(
             quote_custodian,
-            mint_for_testing(100000000, ctx(&mut scenario)),
+            mint_for_testing(10000000, ctx(&mut scenario)),
             account_cap_user
         );
         test_scenario::return_shared(pool);
@@ -334,7 +334,7 @@ module deepbook::order_query_tests {
                 &mut pool,
                 CLIENT_ID_ALICE,
                 price,
-                2000,
+                200,
                 CANCEL_OLDEST,
                 true,
                 timestamp,