|
|
@@ -21,6 +21,8 @@ def test_apply_create_accepts_fuel():
|
|
|
"licensePlate": "鄂A12345",
|
|
|
"rechargeType": "fuel",
|
|
|
"applyDate": "2026-09-12",
|
|
|
+ "odometerKm": "1000",
|
|
|
+ "attachmentUrls": "pl/vehicle-recharge/a.jpg",
|
|
|
}
|
|
|
)
|
|
|
assert obj.recharge_type == "fuel"
|
|
|
@@ -32,6 +34,8 @@ def test_apply_create_accepts_etc():
|
|
|
"licensePlate": "鄂A12345",
|
|
|
"rechargeType": "etc",
|
|
|
"applyDate": "2026-09-12",
|
|
|
+ "odometerKm": "1000",
|
|
|
+ "attachmentUrls": "pl/vehicle-recharge/a.jpg",
|
|
|
}
|
|
|
)
|
|
|
assert obj.recharge_type == "etc"
|
|
|
@@ -44,6 +48,8 @@ def test_apply_create_rejects_unknown_type():
|
|
|
"licensePlate": "鄂A12345",
|
|
|
"rechargeType": "other",
|
|
|
"applyDate": "2026-09-12",
|
|
|
+ "odometerKm": "1000",
|
|
|
+ "attachmentUrls": "pl/vehicle-recharge/a.jpg",
|
|
|
}
|
|
|
)
|
|
|
|