fix: use published fees for client phase2 acceptance
This commit is contained in:
@@ -52,7 +52,7 @@ const report = {
|
||||
expectedTerminalState: {
|
||||
processStatus: 'WAIT_SPLIT',
|
||||
measureReviewStatus: 'APPROVED',
|
||||
feeStatus: 'CONFIRMED',
|
||||
feeStatus: 'SENT',
|
||||
},
|
||||
resources: {
|
||||
tenantId: null,
|
||||
@@ -151,7 +151,7 @@ async function fixtureDiscoveryModule() {
|
||||
if (!terminalFixture) {
|
||||
throw new Error(forcedOrderId
|
||||
? `Configured orderId=${forcedOrderId} is not visible in tenant ${report.resources.tenantId}`
|
||||
: `Tenant ${report.resources.tenantId} has no WAIT_SPLIT + APPROVED + CONFIRMED fixture`)
|
||||
: `Tenant ${report.resources.tenantId} has no WAIT_SPLIT + APPROVED + SENT fixture`)
|
||||
}
|
||||
assertTerminalFixture(terminalFixture)
|
||||
report.resources.terminalInboundId = String(terminalFixture.id)
|
||||
@@ -165,7 +165,7 @@ async function fixtureDiscoveryModule() {
|
||||
await softApiStep('phase2-fixture', 'terminal state filters find selected inbound', {
|
||||
method: 'GET',
|
||||
path: `/api/platform/inbounds?tenantId=${report.resources.tenantId}`
|
||||
+ '&processStatus=WAIT_SPLIT&measureReviewStatus=APPROVED&feeStatus=CONFIRMED&page=1&size=200',
|
||||
+ '&processStatus=WAIT_SPLIT&measureReviewStatus=APPROVED&feeStatus=SENT&page=1&size=200',
|
||||
token: platformToken,
|
||||
}, ({ json }) => {
|
||||
requireSuccess(json)
|
||||
@@ -391,7 +391,7 @@ async function terminalBillingModule() {
|
||||
assertEqual(String(json.data.inbound.summary.id), report.resources.terminalInboundId, 'inbound id')
|
||||
assertEqual(String(json.data.inbound.summary.orderId), report.resources.terminalOrderId, 'order id')
|
||||
assertTerminalFixture(json.data.inbound.summary)
|
||||
assertEqual(json.data.latestFee.feeStatus, 'CONFIRMED', 'latest fee status')
|
||||
assertEqual(json.data.latestFee.feeStatus, 'SENT', 'latest fee status')
|
||||
}, ({ json }) => ({
|
||||
inboundId: json?.data?.inbound?.summary?.id,
|
||||
orderId: json?.data?.inbound?.summary?.orderId,
|
||||
@@ -669,7 +669,7 @@ async function unifiedOrderModule() {
|
||||
async function isolationModule() {
|
||||
if (!foreignFixture) {
|
||||
recordSkipped('phase2-isolation', 'cross-enterprise terminal billing is rejected',
|
||||
'No foreign WAIT_SPLIT + APPROVED + CONFIRMED fixture is visible to the platform account')
|
||||
'No foreign WAIT_SPLIT + APPROVED + SENT fixture is visible to the platform account')
|
||||
return
|
||||
}
|
||||
await apiStep('phase2-isolation', 'cross-enterprise terminal billing is rejected', {
|
||||
@@ -787,14 +787,14 @@ function requireSuccess(json) {
|
||||
function isTerminalFixture(row) {
|
||||
return row?.processStatus === 'WAIT_SPLIT'
|
||||
&& row?.measureReviewStatus === 'APPROVED'
|
||||
&& row?.feeStatus === 'CONFIRMED'
|
||||
&& row?.feeStatus === 'SENT'
|
||||
}
|
||||
|
||||
function assertTerminalFixture(row) {
|
||||
assertPresent(row, 'terminal inbound fixture')
|
||||
assertEqual(row.processStatus, 'WAIT_SPLIT', 'process status')
|
||||
assertEqual(row.measureReviewStatus, 'APPROVED', 'measurement review status')
|
||||
assertEqual(row.feeStatus, 'CONFIRMED', 'fee status')
|
||||
assertEqual(row.feeStatus, 'SENT', 'fee status')
|
||||
}
|
||||
|
||||
function assertDimensionRule(rule) {
|
||||
|
||||
Reference in New Issue
Block a user