diff --git a/.release-please-manifest.json b/.release-please-manifest.json
index 1b77f506..6538ca91 100644
--- a/.release-please-manifest.json
+++ b/.release-please-manifest.json
@@ -1,3 +1,3 @@
{
- ".": "0.7.0"
+ ".": "0.8.0"
}
\ No newline at end of file
diff --git a/.stats.yml b/.stats.yml
index 6a74fe0f..49b2f4a1 100644
--- a/.stats.yml
+++ b/.stats.yml
@@ -1,2 +1,2 @@
configured_endpoints: 97
-openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-0f43f737c6520ed2a2407628511350362959997f89a868c50aa38d47d5791171.yml
+openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-40a4e23dd482299a046fb62fd2b5a1e03d455156cb8cd4573e92e4132d74b243.yml
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 86c25819..6bddb226 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,18 @@
# Changelog
+## 0.8.0 (2024-11-25)
+
+Full Changelog: [v0.7.0...v0.8.0](https://github.com/orbcorp/orb-java/compare/v0.7.0...v0.8.0)
+
+### Features
+
+* **api:** api update ([#129](https://github.com/orbcorp/orb-java/issues/129)) ([4f1e414](https://github.com/orbcorp/orb-java/commit/4f1e4143bedf579fc5dcd17d0872ab64d23962e2))
+
+
+### Chores
+
+* **internal:** update example values ([#127](https://github.com/orbcorp/orb-java/issues/127)) ([6323bfd](https://github.com/orbcorp/orb-java/commit/6323bfda070264b781803fb7fcc29b9711cda006))
+
## 0.7.0 (2024-11-25)
Full Changelog: [v0.6.1...v0.7.0](https://github.com/orbcorp/orb-java/compare/v0.6.1...v0.7.0)
diff --git a/README.md b/README.md
index 95895667..78f853ab 100644
--- a/README.md
+++ b/README.md
@@ -2,7 +2,7 @@
-[](https://central.sonatype.com/artifact/com.withorb.api/orb-java/0.7.0)
+[](https://central.sonatype.com/artifact/com.withorb.api/orb-java/0.8.0)
@@ -25,7 +25,7 @@ The REST API documentation can be foundĀ on [docs.withorb.com](https://docs.with
```kotlin
-implementation("com.withorb.api:orb-java:0.7.0")
+implementation("com.withorb.api:orb-java:0.8.0")
```
#### Maven
@@ -34,7 +34,7 @@ implementation("com.withorb.api:orb-java:0.7.0")
com.withorb.api
orb-java
- 0.7.0
+ 0.8.0
```
diff --git a/build.gradle.kts b/build.gradle.kts
index ae7b1bc9..f9036d28 100644
--- a/build.gradle.kts
+++ b/build.gradle.kts
@@ -4,7 +4,7 @@ plugins {
allprojects {
group = "com.withorb.api"
- version = "0.7.0" // x-release-please-version
+ version = "0.8.0" // x-release-please-version
}
diff --git a/orb-java-core/src/main/kotlin/com/withorb/api/models/SubscriptionCreateParams.kt b/orb-java-core/src/main/kotlin/com/withorb/api/models/SubscriptionCreateParams.kt
index 3a5fe063..d1b6f51f 100644
--- a/orb-java-core/src/main/kotlin/com/withorb/api/models/SubscriptionCreateParams.kt
+++ b/orb-java-core/src/main/kotlin/com/withorb/api/models/SubscriptionCreateParams.kt
@@ -49,6 +49,7 @@ constructor(
private val externalMarketplace: ExternalMarketplace?,
private val externalMarketplaceReportingId: String?,
private val externalPlanId: String?,
+ private val filter: String?,
private val initialPhaseOrder: Long?,
private val invoicingThreshold: String?,
private val metadata: Metadata?,
@@ -102,6 +103,8 @@ constructor(
fun externalPlanId(): Optional = Optional.ofNullable(externalPlanId)
+ fun filter(): Optional = Optional.ofNullable(filter)
+
fun initialPhaseOrder(): Optional = Optional.ofNullable(initialPhaseOrder)
fun invoicingThreshold(): Optional = Optional.ofNullable(invoicingThreshold)
@@ -156,6 +159,7 @@ constructor(
externalMarketplace,
externalMarketplaceReportingId,
externalPlanId,
+ filter,
initialPhaseOrder,
invoicingThreshold,
metadata,
@@ -197,6 +201,7 @@ constructor(
private val externalMarketplace: ExternalMarketplace?,
private val externalMarketplaceReportingId: String?,
private val externalPlanId: String?,
+ private val filter: String?,
private val initialPhaseOrder: Long?,
private val invoicingThreshold: String?,
private val metadata: Metadata?,
@@ -277,6 +282,14 @@ constructor(
*/
@JsonProperty("external_plan_id") fun externalPlanId(): String? = externalPlanId
+ /**
+ * An additional filter to apply to usage queries. This filter must be expressed as a
+ * boolean
+ * [computed property](../guides/extensibility/advanced-metrics#computed-properties). If
+ * null, usage queries will not include any additional filter.
+ */
+ @JsonProperty("filter") fun filter(): String? = filter
+
/** The phase of the plan to start with */
@JsonProperty("initial_phase_order") fun initialPhaseOrder(): Long? = initialPhaseOrder
@@ -381,6 +394,7 @@ constructor(
private var externalMarketplace: ExternalMarketplace? = null
private var externalMarketplaceReportingId: String? = null
private var externalPlanId: String? = null
+ private var filter: String? = null
private var initialPhaseOrder: Long? = null
private var invoicingThreshold: String? = null
private var metadata: Metadata? = null
@@ -417,6 +431,7 @@ constructor(
this.externalMarketplaceReportingId =
subscriptionCreateBody.externalMarketplaceReportingId
this.externalPlanId = subscriptionCreateBody.externalPlanId
+ this.filter = subscriptionCreateBody.filter
this.initialPhaseOrder = subscriptionCreateBody.initialPhaseOrder
this.invoicingThreshold = subscriptionCreateBody.invoicingThreshold
this.metadata = subscriptionCreateBody.metadata
@@ -529,6 +544,14 @@ constructor(
this.externalPlanId = externalPlanId
}
+ /**
+ * An additional filter to apply to usage queries. This filter must be expressed as a
+ * boolean
+ * [computed property](../guides/extensibility/advanced-metrics#computed-properties). If
+ * null, usage queries will not include any additional filter.
+ */
+ @JsonProperty("filter") fun filter(filter: String) = apply { this.filter = filter }
+
/** The phase of the plan to start with */
@JsonProperty("initial_phase_order")
fun initialPhaseOrder(initialPhaseOrder: Long) = apply {
@@ -666,6 +689,7 @@ constructor(
externalMarketplace,
externalMarketplaceReportingId,
externalPlanId,
+ filter,
initialPhaseOrder,
invoicingThreshold,
metadata,
@@ -689,17 +713,17 @@ constructor(
return true
}
- return /* spotless:off */ other is SubscriptionCreateBody && addAdjustments == other.addAdjustments && addPrices == other.addPrices && alignBillingWithSubscriptionStartDate == other.alignBillingWithSubscriptionStartDate && autoCollection == other.autoCollection && awsRegion == other.awsRegion && billingCycleAnchorConfiguration == other.billingCycleAnchorConfiguration && couponRedemptionCode == other.couponRedemptionCode && creditsOverageRate == other.creditsOverageRate && customerId == other.customerId && defaultInvoiceMemo == other.defaultInvoiceMemo && endDate == other.endDate && externalCustomerId == other.externalCustomerId && externalMarketplace == other.externalMarketplace && externalMarketplaceReportingId == other.externalMarketplaceReportingId && externalPlanId == other.externalPlanId && initialPhaseOrder == other.initialPhaseOrder && invoicingThreshold == other.invoicingThreshold && metadata == other.metadata && netTerms == other.netTerms && perCreditOverageAmount == other.perCreditOverageAmount && planId == other.planId && planVersionNumber == other.planVersionNumber && priceOverrides == other.priceOverrides && removeAdjustments == other.removeAdjustments && removePrices == other.removePrices && replaceAdjustments == other.replaceAdjustments && replacePrices == other.replacePrices && startDate == other.startDate && trialDurationDays == other.trialDurationDays && additionalProperties == other.additionalProperties /* spotless:on */
+ return /* spotless:off */ other is SubscriptionCreateBody && addAdjustments == other.addAdjustments && addPrices == other.addPrices && alignBillingWithSubscriptionStartDate == other.alignBillingWithSubscriptionStartDate && autoCollection == other.autoCollection && awsRegion == other.awsRegion && billingCycleAnchorConfiguration == other.billingCycleAnchorConfiguration && couponRedemptionCode == other.couponRedemptionCode && creditsOverageRate == other.creditsOverageRate && customerId == other.customerId && defaultInvoiceMemo == other.defaultInvoiceMemo && endDate == other.endDate && externalCustomerId == other.externalCustomerId && externalMarketplace == other.externalMarketplace && externalMarketplaceReportingId == other.externalMarketplaceReportingId && externalPlanId == other.externalPlanId && filter == other.filter && initialPhaseOrder == other.initialPhaseOrder && invoicingThreshold == other.invoicingThreshold && metadata == other.metadata && netTerms == other.netTerms && perCreditOverageAmount == other.perCreditOverageAmount && planId == other.planId && planVersionNumber == other.planVersionNumber && priceOverrides == other.priceOverrides && removeAdjustments == other.removeAdjustments && removePrices == other.removePrices && replaceAdjustments == other.replaceAdjustments && replacePrices == other.replacePrices && startDate == other.startDate && trialDurationDays == other.trialDurationDays && additionalProperties == other.additionalProperties /* spotless:on */
}
/* spotless:off */
- private val hashCode: Int by lazy { Objects.hash(addAdjustments, addPrices, alignBillingWithSubscriptionStartDate, autoCollection, awsRegion, billingCycleAnchorConfiguration, couponRedemptionCode, creditsOverageRate, customerId, defaultInvoiceMemo, endDate, externalCustomerId, externalMarketplace, externalMarketplaceReportingId, externalPlanId, initialPhaseOrder, invoicingThreshold, metadata, netTerms, perCreditOverageAmount, planId, planVersionNumber, priceOverrides, removeAdjustments, removePrices, replaceAdjustments, replacePrices, startDate, trialDurationDays, additionalProperties) }
+ private val hashCode: Int by lazy { Objects.hash(addAdjustments, addPrices, alignBillingWithSubscriptionStartDate, autoCollection, awsRegion, billingCycleAnchorConfiguration, couponRedemptionCode, creditsOverageRate, customerId, defaultInvoiceMemo, endDate, externalCustomerId, externalMarketplace, externalMarketplaceReportingId, externalPlanId, filter, initialPhaseOrder, invoicingThreshold, metadata, netTerms, perCreditOverageAmount, planId, planVersionNumber, priceOverrides, removeAdjustments, removePrices, replaceAdjustments, replacePrices, startDate, trialDurationDays, additionalProperties) }
/* spotless:on */
override fun hashCode(): Int = hashCode
override fun toString() =
- "SubscriptionCreateBody{addAdjustments=$addAdjustments, addPrices=$addPrices, alignBillingWithSubscriptionStartDate=$alignBillingWithSubscriptionStartDate, autoCollection=$autoCollection, awsRegion=$awsRegion, billingCycleAnchorConfiguration=$billingCycleAnchorConfiguration, couponRedemptionCode=$couponRedemptionCode, creditsOverageRate=$creditsOverageRate, customerId=$customerId, defaultInvoiceMemo=$defaultInvoiceMemo, endDate=$endDate, externalCustomerId=$externalCustomerId, externalMarketplace=$externalMarketplace, externalMarketplaceReportingId=$externalMarketplaceReportingId, externalPlanId=$externalPlanId, initialPhaseOrder=$initialPhaseOrder, invoicingThreshold=$invoicingThreshold, metadata=$metadata, netTerms=$netTerms, perCreditOverageAmount=$perCreditOverageAmount, planId=$planId, planVersionNumber=$planVersionNumber, priceOverrides=$priceOverrides, removeAdjustments=$removeAdjustments, removePrices=$removePrices, replaceAdjustments=$replaceAdjustments, replacePrices=$replacePrices, startDate=$startDate, trialDurationDays=$trialDurationDays, additionalProperties=$additionalProperties}"
+ "SubscriptionCreateBody{addAdjustments=$addAdjustments, addPrices=$addPrices, alignBillingWithSubscriptionStartDate=$alignBillingWithSubscriptionStartDate, autoCollection=$autoCollection, awsRegion=$awsRegion, billingCycleAnchorConfiguration=$billingCycleAnchorConfiguration, couponRedemptionCode=$couponRedemptionCode, creditsOverageRate=$creditsOverageRate, customerId=$customerId, defaultInvoiceMemo=$defaultInvoiceMemo, endDate=$endDate, externalCustomerId=$externalCustomerId, externalMarketplace=$externalMarketplace, externalMarketplaceReportingId=$externalMarketplaceReportingId, externalPlanId=$externalPlanId, filter=$filter, initialPhaseOrder=$initialPhaseOrder, invoicingThreshold=$invoicingThreshold, metadata=$metadata, netTerms=$netTerms, perCreditOverageAmount=$perCreditOverageAmount, planId=$planId, planVersionNumber=$planVersionNumber, priceOverrides=$priceOverrides, removeAdjustments=$removeAdjustments, removePrices=$removePrices, replaceAdjustments=$replaceAdjustments, replacePrices=$replacePrices, startDate=$startDate, trialDurationDays=$trialDurationDays, additionalProperties=$additionalProperties}"
}
fun toBuilder() = Builder().from(this)
@@ -727,6 +751,7 @@ constructor(
private var externalMarketplace: ExternalMarketplace? = null
private var externalMarketplaceReportingId: String? = null
private var externalPlanId: String? = null
+ private var filter: String? = null
private var initialPhaseOrder: Long? = null
private var invoicingThreshold: String? = null
private var metadata: Metadata? = null
@@ -765,6 +790,7 @@ constructor(
externalMarketplace = subscriptionCreateParams.externalMarketplace
externalMarketplaceReportingId = subscriptionCreateParams.externalMarketplaceReportingId
externalPlanId = subscriptionCreateParams.externalPlanId
+ filter = subscriptionCreateParams.filter
initialPhaseOrder = subscriptionCreateParams.initialPhaseOrder
invoicingThreshold = subscriptionCreateParams.invoicingThreshold
metadata = subscriptionCreateParams.metadata
@@ -882,6 +908,14 @@ constructor(
*/
fun externalPlanId(externalPlanId: String) = apply { this.externalPlanId = externalPlanId }
+ /**
+ * An additional filter to apply to usage queries. This filter must be expressed as a
+ * boolean
+ * [computed property](../guides/extensibility/advanced-metrics#computed-properties). If
+ * null, usage queries will not include any additional filter.
+ */
+ fun filter(filter: String) = apply { this.filter = filter }
+
/** The phase of the plan to start with */
fun initialPhaseOrder(initialPhaseOrder: Long) = apply {
this.initialPhaseOrder = initialPhaseOrder
@@ -1152,6 +1186,7 @@ constructor(
externalMarketplace,
externalMarketplaceReportingId,
externalPlanId,
+ filter,
initialPhaseOrder,
invoicingThreshold,
metadata,
@@ -51542,11 +51577,11 @@ constructor(
return true
}
- return /* spotless:off */ other is SubscriptionCreateParams && addAdjustments == other.addAdjustments && addPrices == other.addPrices && alignBillingWithSubscriptionStartDate == other.alignBillingWithSubscriptionStartDate && autoCollection == other.autoCollection && awsRegion == other.awsRegion && billingCycleAnchorConfiguration == other.billingCycleAnchorConfiguration && couponRedemptionCode == other.couponRedemptionCode && creditsOverageRate == other.creditsOverageRate && customerId == other.customerId && defaultInvoiceMemo == other.defaultInvoiceMemo && endDate == other.endDate && externalCustomerId == other.externalCustomerId && externalMarketplace == other.externalMarketplace && externalMarketplaceReportingId == other.externalMarketplaceReportingId && externalPlanId == other.externalPlanId && initialPhaseOrder == other.initialPhaseOrder && invoicingThreshold == other.invoicingThreshold && metadata == other.metadata && netTerms == other.netTerms && perCreditOverageAmount == other.perCreditOverageAmount && planId == other.planId && planVersionNumber == other.planVersionNumber && priceOverrides == other.priceOverrides && removeAdjustments == other.removeAdjustments && removePrices == other.removePrices && replaceAdjustments == other.replaceAdjustments && replacePrices == other.replacePrices && startDate == other.startDate && trialDurationDays == other.trialDurationDays && additionalHeaders == other.additionalHeaders && additionalQueryParams == other.additionalQueryParams && additionalBodyProperties == other.additionalBodyProperties /* spotless:on */
+ return /* spotless:off */ other is SubscriptionCreateParams && addAdjustments == other.addAdjustments && addPrices == other.addPrices && alignBillingWithSubscriptionStartDate == other.alignBillingWithSubscriptionStartDate && autoCollection == other.autoCollection && awsRegion == other.awsRegion && billingCycleAnchorConfiguration == other.billingCycleAnchorConfiguration && couponRedemptionCode == other.couponRedemptionCode && creditsOverageRate == other.creditsOverageRate && customerId == other.customerId && defaultInvoiceMemo == other.defaultInvoiceMemo && endDate == other.endDate && externalCustomerId == other.externalCustomerId && externalMarketplace == other.externalMarketplace && externalMarketplaceReportingId == other.externalMarketplaceReportingId && externalPlanId == other.externalPlanId && filter == other.filter && initialPhaseOrder == other.initialPhaseOrder && invoicingThreshold == other.invoicingThreshold && metadata == other.metadata && netTerms == other.netTerms && perCreditOverageAmount == other.perCreditOverageAmount && planId == other.planId && planVersionNumber == other.planVersionNumber && priceOverrides == other.priceOverrides && removeAdjustments == other.removeAdjustments && removePrices == other.removePrices && replaceAdjustments == other.replaceAdjustments && replacePrices == other.replacePrices && startDate == other.startDate && trialDurationDays == other.trialDurationDays && additionalHeaders == other.additionalHeaders && additionalQueryParams == other.additionalQueryParams && additionalBodyProperties == other.additionalBodyProperties /* spotless:on */
}
- override fun hashCode(): Int = /* spotless:off */ Objects.hash(addAdjustments, addPrices, alignBillingWithSubscriptionStartDate, autoCollection, awsRegion, billingCycleAnchorConfiguration, couponRedemptionCode, creditsOverageRate, customerId, defaultInvoiceMemo, endDate, externalCustomerId, externalMarketplace, externalMarketplaceReportingId, externalPlanId, initialPhaseOrder, invoicingThreshold, metadata, netTerms, perCreditOverageAmount, planId, planVersionNumber, priceOverrides, removeAdjustments, removePrices, replaceAdjustments, replacePrices, startDate, trialDurationDays, additionalHeaders, additionalQueryParams, additionalBodyProperties) /* spotless:on */
+ override fun hashCode(): Int = /* spotless:off */ Objects.hash(addAdjustments, addPrices, alignBillingWithSubscriptionStartDate, autoCollection, awsRegion, billingCycleAnchorConfiguration, couponRedemptionCode, creditsOverageRate, customerId, defaultInvoiceMemo, endDate, externalCustomerId, externalMarketplace, externalMarketplaceReportingId, externalPlanId, filter, initialPhaseOrder, invoicingThreshold, metadata, netTerms, perCreditOverageAmount, planId, planVersionNumber, priceOverrides, removeAdjustments, removePrices, replaceAdjustments, replacePrices, startDate, trialDurationDays, additionalHeaders, additionalQueryParams, additionalBodyProperties) /* spotless:on */
override fun toString() =
- "SubscriptionCreateParams{addAdjustments=$addAdjustments, addPrices=$addPrices, alignBillingWithSubscriptionStartDate=$alignBillingWithSubscriptionStartDate, autoCollection=$autoCollection, awsRegion=$awsRegion, billingCycleAnchorConfiguration=$billingCycleAnchorConfiguration, couponRedemptionCode=$couponRedemptionCode, creditsOverageRate=$creditsOverageRate, customerId=$customerId, defaultInvoiceMemo=$defaultInvoiceMemo, endDate=$endDate, externalCustomerId=$externalCustomerId, externalMarketplace=$externalMarketplace, externalMarketplaceReportingId=$externalMarketplaceReportingId, externalPlanId=$externalPlanId, initialPhaseOrder=$initialPhaseOrder, invoicingThreshold=$invoicingThreshold, metadata=$metadata, netTerms=$netTerms, perCreditOverageAmount=$perCreditOverageAmount, planId=$planId, planVersionNumber=$planVersionNumber, priceOverrides=$priceOverrides, removeAdjustments=$removeAdjustments, removePrices=$removePrices, replaceAdjustments=$replaceAdjustments, replacePrices=$replacePrices, startDate=$startDate, trialDurationDays=$trialDurationDays, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams, additionalBodyProperties=$additionalBodyProperties}"
+ "SubscriptionCreateParams{addAdjustments=$addAdjustments, addPrices=$addPrices, alignBillingWithSubscriptionStartDate=$alignBillingWithSubscriptionStartDate, autoCollection=$autoCollection, awsRegion=$awsRegion, billingCycleAnchorConfiguration=$billingCycleAnchorConfiguration, couponRedemptionCode=$couponRedemptionCode, creditsOverageRate=$creditsOverageRate, customerId=$customerId, defaultInvoiceMemo=$defaultInvoiceMemo, endDate=$endDate, externalCustomerId=$externalCustomerId, externalMarketplace=$externalMarketplace, externalMarketplaceReportingId=$externalMarketplaceReportingId, externalPlanId=$externalPlanId, filter=$filter, initialPhaseOrder=$initialPhaseOrder, invoicingThreshold=$invoicingThreshold, metadata=$metadata, netTerms=$netTerms, perCreditOverageAmount=$perCreditOverageAmount, planId=$planId, planVersionNumber=$planVersionNumber, priceOverrides=$priceOverrides, removeAdjustments=$removeAdjustments, removePrices=$removePrices, replaceAdjustments=$replaceAdjustments, replacePrices=$replacePrices, startDate=$startDate, trialDurationDays=$trialDurationDays, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams, additionalBodyProperties=$additionalBodyProperties}"
}
diff --git a/orb-java-core/src/main/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeParams.kt b/orb-java-core/src/main/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeParams.kt
index 0356f54b..2a19ccbc 100644
--- a/orb-java-core/src/main/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeParams.kt
+++ b/orb-java-core/src/main/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeParams.kt
@@ -47,6 +47,7 @@ constructor(
private val creditsOverageRate: Double?,
private val defaultInvoiceMemo: String?,
private val externalPlanId: String?,
+ private val filter: String?,
private val initialPhaseOrder: Long?,
private val invoicingThreshold: String?,
private val netTerms: Long?,
@@ -93,6 +94,8 @@ constructor(
fun externalPlanId(): Optional = Optional.ofNullable(externalPlanId)
+ fun filter(): Optional = Optional.ofNullable(filter)
+
fun initialPhaseOrder(): Optional = Optional.ofNullable(initialPhaseOrder)
fun invoicingThreshold(): Optional = Optional.ofNullable(invoicingThreshold)
@@ -140,6 +143,7 @@ constructor(
creditsOverageRate,
defaultInvoiceMemo,
externalPlanId,
+ filter,
initialPhaseOrder,
invoicingThreshold,
netTerms,
@@ -183,6 +187,7 @@ constructor(
private val creditsOverageRate: Double?,
private val defaultInvoiceMemo: String?,
private val externalPlanId: String?,
+ private val filter: String?,
private val initialPhaseOrder: Long?,
private val invoicingThreshold: String?,
private val netTerms: Long?,
@@ -266,6 +271,14 @@ constructor(
*/
@JsonProperty("external_plan_id") fun externalPlanId(): String? = externalPlanId
+ /**
+ * An additional filter to apply to usage queries. This filter must be expressed as a
+ * boolean
+ * [computed property](../guides/extensibility/advanced-metrics#computed-properties). If
+ * null, usage queries will not include any additional filter.
+ */
+ @JsonProperty("filter") fun filter(): String? = filter
+
/** The phase of the plan to start with */
@JsonProperty("initial_phase_order") fun initialPhaseOrder(): Long? = initialPhaseOrder
@@ -358,6 +371,7 @@ constructor(
private var creditsOverageRate: Double? = null
private var defaultInvoiceMemo: String? = null
private var externalPlanId: String? = null
+ private var filter: String? = null
private var initialPhaseOrder: Long? = null
private var invoicingThreshold: String? = null
private var netTerms: Long? = null
@@ -391,6 +405,7 @@ constructor(
this.creditsOverageRate = subscriptionSchedulePlanChangeBody.creditsOverageRate
this.defaultInvoiceMemo = subscriptionSchedulePlanChangeBody.defaultInvoiceMemo
this.externalPlanId = subscriptionSchedulePlanChangeBody.externalPlanId
+ this.filter = subscriptionSchedulePlanChangeBody.filter
this.initialPhaseOrder = subscriptionSchedulePlanChangeBody.initialPhaseOrder
this.invoicingThreshold = subscriptionSchedulePlanChangeBody.invoicingThreshold
this.netTerms = subscriptionSchedulePlanChangeBody.netTerms
@@ -502,6 +517,14 @@ constructor(
this.externalPlanId = externalPlanId
}
+ /**
+ * An additional filter to apply to usage queries. This filter must be expressed as a
+ * boolean
+ * [computed property](../guides/extensibility/advanced-metrics#computed-properties). If
+ * null, usage queries will not include any additional filter.
+ */
+ @JsonProperty("filter") fun filter(filter: String) = apply { this.filter = filter }
+
/** The phase of the plan to start with */
@JsonProperty("initial_phase_order")
fun initialPhaseOrder(initialPhaseOrder: Long) = apply {
@@ -625,6 +648,7 @@ constructor(
creditsOverageRate,
defaultInvoiceMemo,
externalPlanId,
+ filter,
initialPhaseOrder,
invoicingThreshold,
netTerms,
@@ -646,17 +670,17 @@ constructor(
return true
}
- return /* spotless:off */ other is SubscriptionSchedulePlanChangeBody && changeOption == other.changeOption && addAdjustments == other.addAdjustments && addPrices == other.addPrices && alignBillingWithPlanChangeDate == other.alignBillingWithPlanChangeDate && autoCollection == other.autoCollection && billingCycleAlignment == other.billingCycleAlignment && billingCycleAnchorConfiguration == other.billingCycleAnchorConfiguration && changeDate == other.changeDate && couponRedemptionCode == other.couponRedemptionCode && creditsOverageRate == other.creditsOverageRate && defaultInvoiceMemo == other.defaultInvoiceMemo && externalPlanId == other.externalPlanId && initialPhaseOrder == other.initialPhaseOrder && invoicingThreshold == other.invoicingThreshold && netTerms == other.netTerms && perCreditOverageAmount == other.perCreditOverageAmount && planId == other.planId && planVersionNumber == other.planVersionNumber && priceOverrides == other.priceOverrides && removeAdjustments == other.removeAdjustments && removePrices == other.removePrices && replaceAdjustments == other.replaceAdjustments && replacePrices == other.replacePrices && trialDurationDays == other.trialDurationDays && additionalProperties == other.additionalProperties /* spotless:on */
+ return /* spotless:off */ other is SubscriptionSchedulePlanChangeBody && changeOption == other.changeOption && addAdjustments == other.addAdjustments && addPrices == other.addPrices && alignBillingWithPlanChangeDate == other.alignBillingWithPlanChangeDate && autoCollection == other.autoCollection && billingCycleAlignment == other.billingCycleAlignment && billingCycleAnchorConfiguration == other.billingCycleAnchorConfiguration && changeDate == other.changeDate && couponRedemptionCode == other.couponRedemptionCode && creditsOverageRate == other.creditsOverageRate && defaultInvoiceMemo == other.defaultInvoiceMemo && externalPlanId == other.externalPlanId && filter == other.filter && initialPhaseOrder == other.initialPhaseOrder && invoicingThreshold == other.invoicingThreshold && netTerms == other.netTerms && perCreditOverageAmount == other.perCreditOverageAmount && planId == other.planId && planVersionNumber == other.planVersionNumber && priceOverrides == other.priceOverrides && removeAdjustments == other.removeAdjustments && removePrices == other.removePrices && replaceAdjustments == other.replaceAdjustments && replacePrices == other.replacePrices && trialDurationDays == other.trialDurationDays && additionalProperties == other.additionalProperties /* spotless:on */
}
/* spotless:off */
- private val hashCode: Int by lazy { Objects.hash(changeOption, addAdjustments, addPrices, alignBillingWithPlanChangeDate, autoCollection, billingCycleAlignment, billingCycleAnchorConfiguration, changeDate, couponRedemptionCode, creditsOverageRate, defaultInvoiceMemo, externalPlanId, initialPhaseOrder, invoicingThreshold, netTerms, perCreditOverageAmount, planId, planVersionNumber, priceOverrides, removeAdjustments, removePrices, replaceAdjustments, replacePrices, trialDurationDays, additionalProperties) }
+ private val hashCode: Int by lazy { Objects.hash(changeOption, addAdjustments, addPrices, alignBillingWithPlanChangeDate, autoCollection, billingCycleAlignment, billingCycleAnchorConfiguration, changeDate, couponRedemptionCode, creditsOverageRate, defaultInvoiceMemo, externalPlanId, filter, initialPhaseOrder, invoicingThreshold, netTerms, perCreditOverageAmount, planId, planVersionNumber, priceOverrides, removeAdjustments, removePrices, replaceAdjustments, replacePrices, trialDurationDays, additionalProperties) }
/* spotless:on */
override fun hashCode(): Int = hashCode
override fun toString() =
- "SubscriptionSchedulePlanChangeBody{changeOption=$changeOption, addAdjustments=$addAdjustments, addPrices=$addPrices, alignBillingWithPlanChangeDate=$alignBillingWithPlanChangeDate, autoCollection=$autoCollection, billingCycleAlignment=$billingCycleAlignment, billingCycleAnchorConfiguration=$billingCycleAnchorConfiguration, changeDate=$changeDate, couponRedemptionCode=$couponRedemptionCode, creditsOverageRate=$creditsOverageRate, defaultInvoiceMemo=$defaultInvoiceMemo, externalPlanId=$externalPlanId, initialPhaseOrder=$initialPhaseOrder, invoicingThreshold=$invoicingThreshold, netTerms=$netTerms, perCreditOverageAmount=$perCreditOverageAmount, planId=$planId, planVersionNumber=$planVersionNumber, priceOverrides=$priceOverrides, removeAdjustments=$removeAdjustments, removePrices=$removePrices, replaceAdjustments=$replaceAdjustments, replacePrices=$replacePrices, trialDurationDays=$trialDurationDays, additionalProperties=$additionalProperties}"
+ "SubscriptionSchedulePlanChangeBody{changeOption=$changeOption, addAdjustments=$addAdjustments, addPrices=$addPrices, alignBillingWithPlanChangeDate=$alignBillingWithPlanChangeDate, autoCollection=$autoCollection, billingCycleAlignment=$billingCycleAlignment, billingCycleAnchorConfiguration=$billingCycleAnchorConfiguration, changeDate=$changeDate, couponRedemptionCode=$couponRedemptionCode, creditsOverageRate=$creditsOverageRate, defaultInvoiceMemo=$defaultInvoiceMemo, externalPlanId=$externalPlanId, filter=$filter, initialPhaseOrder=$initialPhaseOrder, invoicingThreshold=$invoicingThreshold, netTerms=$netTerms, perCreditOverageAmount=$perCreditOverageAmount, planId=$planId, planVersionNumber=$planVersionNumber, priceOverrides=$priceOverrides, removeAdjustments=$removeAdjustments, removePrices=$removePrices, replaceAdjustments=$replaceAdjustments, replacePrices=$replacePrices, trialDurationDays=$trialDurationDays, additionalProperties=$additionalProperties}"
}
fun toBuilder() = Builder().from(this)
@@ -682,6 +706,7 @@ constructor(
private var creditsOverageRate: Double? = null
private var defaultInvoiceMemo: String? = null
private var externalPlanId: String? = null
+ private var filter: String? = null
private var initialPhaseOrder: Long? = null
private var invoicingThreshold: String? = null
private var netTerms: Long? = null
@@ -720,6 +745,7 @@ constructor(
creditsOverageRate = subscriptionSchedulePlanChangeParams.creditsOverageRate
defaultInvoiceMemo = subscriptionSchedulePlanChangeParams.defaultInvoiceMemo
externalPlanId = subscriptionSchedulePlanChangeParams.externalPlanId
+ filter = subscriptionSchedulePlanChangeParams.filter
initialPhaseOrder = subscriptionSchedulePlanChangeParams.initialPhaseOrder
invoicingThreshold = subscriptionSchedulePlanChangeParams.invoicingThreshold
netTerms = subscriptionSchedulePlanChangeParams.netTerms
@@ -846,6 +872,14 @@ constructor(
*/
fun externalPlanId(externalPlanId: String) = apply { this.externalPlanId = externalPlanId }
+ /**
+ * An additional filter to apply to usage queries. This filter must be expressed as a
+ * boolean
+ * [computed property](../guides/extensibility/advanced-metrics#computed-properties). If
+ * null, usage queries will not include any additional filter.
+ */
+ fun filter(filter: String) = apply { this.filter = filter }
+
/** The phase of the plan to start with */
fun initialPhaseOrder(initialPhaseOrder: Long) = apply {
this.initialPhaseOrder = initialPhaseOrder
@@ -1105,6 +1139,7 @@ constructor(
creditsOverageRate,
defaultInvoiceMemo,
externalPlanId,
+ filter,
initialPhaseOrder,
invoicingThreshold,
netTerms,
@@ -51491,11 +51526,11 @@ constructor(
return true
}
- return /* spotless:off */ other is SubscriptionSchedulePlanChangeParams && subscriptionId == other.subscriptionId && changeOption == other.changeOption && addAdjustments == other.addAdjustments && addPrices == other.addPrices && alignBillingWithPlanChangeDate == other.alignBillingWithPlanChangeDate && autoCollection == other.autoCollection && billingCycleAlignment == other.billingCycleAlignment && billingCycleAnchorConfiguration == other.billingCycleAnchorConfiguration && changeDate == other.changeDate && couponRedemptionCode == other.couponRedemptionCode && creditsOverageRate == other.creditsOverageRate && defaultInvoiceMemo == other.defaultInvoiceMemo && externalPlanId == other.externalPlanId && initialPhaseOrder == other.initialPhaseOrder && invoicingThreshold == other.invoicingThreshold && netTerms == other.netTerms && perCreditOverageAmount == other.perCreditOverageAmount && planId == other.planId && planVersionNumber == other.planVersionNumber && priceOverrides == other.priceOverrides && removeAdjustments == other.removeAdjustments && removePrices == other.removePrices && replaceAdjustments == other.replaceAdjustments && replacePrices == other.replacePrices && trialDurationDays == other.trialDurationDays && additionalHeaders == other.additionalHeaders && additionalQueryParams == other.additionalQueryParams && additionalBodyProperties == other.additionalBodyProperties /* spotless:on */
+ return /* spotless:off */ other is SubscriptionSchedulePlanChangeParams && subscriptionId == other.subscriptionId && changeOption == other.changeOption && addAdjustments == other.addAdjustments && addPrices == other.addPrices && alignBillingWithPlanChangeDate == other.alignBillingWithPlanChangeDate && autoCollection == other.autoCollection && billingCycleAlignment == other.billingCycleAlignment && billingCycleAnchorConfiguration == other.billingCycleAnchorConfiguration && changeDate == other.changeDate && couponRedemptionCode == other.couponRedemptionCode && creditsOverageRate == other.creditsOverageRate && defaultInvoiceMemo == other.defaultInvoiceMemo && externalPlanId == other.externalPlanId && filter == other.filter && initialPhaseOrder == other.initialPhaseOrder && invoicingThreshold == other.invoicingThreshold && netTerms == other.netTerms && perCreditOverageAmount == other.perCreditOverageAmount && planId == other.planId && planVersionNumber == other.planVersionNumber && priceOverrides == other.priceOverrides && removeAdjustments == other.removeAdjustments && removePrices == other.removePrices && replaceAdjustments == other.replaceAdjustments && replacePrices == other.replacePrices && trialDurationDays == other.trialDurationDays && additionalHeaders == other.additionalHeaders && additionalQueryParams == other.additionalQueryParams && additionalBodyProperties == other.additionalBodyProperties /* spotless:on */
}
- override fun hashCode(): Int = /* spotless:off */ Objects.hash(subscriptionId, changeOption, addAdjustments, addPrices, alignBillingWithPlanChangeDate, autoCollection, billingCycleAlignment, billingCycleAnchorConfiguration, changeDate, couponRedemptionCode, creditsOverageRate, defaultInvoiceMemo, externalPlanId, initialPhaseOrder, invoicingThreshold, netTerms, perCreditOverageAmount, planId, planVersionNumber, priceOverrides, removeAdjustments, removePrices, replaceAdjustments, replacePrices, trialDurationDays, additionalHeaders, additionalQueryParams, additionalBodyProperties) /* spotless:on */
+ override fun hashCode(): Int = /* spotless:off */ Objects.hash(subscriptionId, changeOption, addAdjustments, addPrices, alignBillingWithPlanChangeDate, autoCollection, billingCycleAlignment, billingCycleAnchorConfiguration, changeDate, couponRedemptionCode, creditsOverageRate, defaultInvoiceMemo, externalPlanId, filter, initialPhaseOrder, invoicingThreshold, netTerms, perCreditOverageAmount, planId, planVersionNumber, priceOverrides, removeAdjustments, removePrices, replaceAdjustments, replacePrices, trialDurationDays, additionalHeaders, additionalQueryParams, additionalBodyProperties) /* spotless:on */
override fun toString() =
- "SubscriptionSchedulePlanChangeParams{subscriptionId=$subscriptionId, changeOption=$changeOption, addAdjustments=$addAdjustments, addPrices=$addPrices, alignBillingWithPlanChangeDate=$alignBillingWithPlanChangeDate, autoCollection=$autoCollection, billingCycleAlignment=$billingCycleAlignment, billingCycleAnchorConfiguration=$billingCycleAnchorConfiguration, changeDate=$changeDate, couponRedemptionCode=$couponRedemptionCode, creditsOverageRate=$creditsOverageRate, defaultInvoiceMemo=$defaultInvoiceMemo, externalPlanId=$externalPlanId, initialPhaseOrder=$initialPhaseOrder, invoicingThreshold=$invoicingThreshold, netTerms=$netTerms, perCreditOverageAmount=$perCreditOverageAmount, planId=$planId, planVersionNumber=$planVersionNumber, priceOverrides=$priceOverrides, removeAdjustments=$removeAdjustments, removePrices=$removePrices, replaceAdjustments=$replaceAdjustments, replacePrices=$replacePrices, trialDurationDays=$trialDurationDays, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams, additionalBodyProperties=$additionalBodyProperties}"
+ "SubscriptionSchedulePlanChangeParams{subscriptionId=$subscriptionId, changeOption=$changeOption, addAdjustments=$addAdjustments, addPrices=$addPrices, alignBillingWithPlanChangeDate=$alignBillingWithPlanChangeDate, autoCollection=$autoCollection, billingCycleAlignment=$billingCycleAlignment, billingCycleAnchorConfiguration=$billingCycleAnchorConfiguration, changeDate=$changeDate, couponRedemptionCode=$couponRedemptionCode, creditsOverageRate=$creditsOverageRate, defaultInvoiceMemo=$defaultInvoiceMemo, externalPlanId=$externalPlanId, filter=$filter, initialPhaseOrder=$initialPhaseOrder, invoicingThreshold=$invoicingThreshold, netTerms=$netTerms, perCreditOverageAmount=$perCreditOverageAmount, planId=$planId, planVersionNumber=$planVersionNumber, priceOverrides=$priceOverrides, removeAdjustments=$removeAdjustments, removePrices=$removePrices, replaceAdjustments=$replaceAdjustments, replacePrices=$replacePrices, trialDurationDays=$trialDurationDays, additionalHeaders=$additionalHeaders, additionalQueryParams=$additionalQueryParams, additionalBodyProperties=$additionalBodyProperties}"
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForCustomerParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForCustomerParamsTest.kt
index 432f1227..0d95b3b9 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForCustomerParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForCustomerParamsTest.kt
@@ -14,9 +14,7 @@ class AlertCreateForCustomerParamsTest {
.customerId("customer_id")
.currency("currency")
.type(AlertCreateForCustomerParams.Type.USAGE_EXCEEDED)
- .thresholds(
- listOf(AlertCreateForCustomerParams.Threshold.builder().value(42.23).build())
- )
+ .thresholds(listOf(AlertCreateForCustomerParams.Threshold.builder().value(0.0).build()))
.build()
}
@@ -28,7 +26,7 @@ class AlertCreateForCustomerParamsTest {
.currency("currency")
.type(AlertCreateForCustomerParams.Type.USAGE_EXCEEDED)
.thresholds(
- listOf(AlertCreateForCustomerParams.Threshold.builder().value(42.23).build())
+ listOf(AlertCreateForCustomerParams.Threshold.builder().value(0.0).build())
)
.build()
val body = params.getBody()
@@ -36,9 +34,7 @@ class AlertCreateForCustomerParamsTest {
assertThat(body.currency()).isEqualTo("currency")
assertThat(body.type()).isEqualTo(AlertCreateForCustomerParams.Type.USAGE_EXCEEDED)
assertThat(body.thresholds())
- .isEqualTo(
- listOf(AlertCreateForCustomerParams.Threshold.builder().value(42.23).build())
- )
+ .isEqualTo(listOf(AlertCreateForCustomerParams.Threshold.builder().value(0.0).build()))
}
@Test
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForExternalCustomerParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForExternalCustomerParamsTest.kt
index 7d28dea3..9c1d6c7a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForExternalCustomerParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForExternalCustomerParamsTest.kt
@@ -15,9 +15,7 @@ class AlertCreateForExternalCustomerParamsTest {
.currency("currency")
.type(AlertCreateForExternalCustomerParams.Type.USAGE_EXCEEDED)
.thresholds(
- listOf(
- AlertCreateForExternalCustomerParams.Threshold.builder().value(42.23).build()
- )
+ listOf(AlertCreateForExternalCustomerParams.Threshold.builder().value(0.0).build())
)
.build()
}
@@ -31,9 +29,7 @@ class AlertCreateForExternalCustomerParamsTest {
.type(AlertCreateForExternalCustomerParams.Type.USAGE_EXCEEDED)
.thresholds(
listOf(
- AlertCreateForExternalCustomerParams.Threshold.builder()
- .value(42.23)
- .build()
+ AlertCreateForExternalCustomerParams.Threshold.builder().value(0.0).build()
)
)
.build()
@@ -43,9 +39,7 @@ class AlertCreateForExternalCustomerParamsTest {
assertThat(body.type()).isEqualTo(AlertCreateForExternalCustomerParams.Type.USAGE_EXCEEDED)
assertThat(body.thresholds())
.isEqualTo(
- listOf(
- AlertCreateForExternalCustomerParams.Threshold.builder().value(42.23).build()
- )
+ listOf(AlertCreateForExternalCustomerParams.Threshold.builder().value(0.0).build())
)
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForSubscriptionParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForSubscriptionParamsTest.kt
index 9a90faa6..7de63891 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForSubscriptionParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertCreateForSubscriptionParamsTest.kt
@@ -13,7 +13,7 @@ class AlertCreateForSubscriptionParamsTest {
AlertCreateForSubscriptionParams.builder()
.subscriptionId("subscription_id")
.thresholds(
- listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(42.23).build())
+ listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(0.0).build())
)
.type(AlertCreateForSubscriptionParams.Type.USAGE_EXCEEDED)
.metricId("metric_id")
@@ -26,9 +26,7 @@ class AlertCreateForSubscriptionParamsTest {
AlertCreateForSubscriptionParams.builder()
.subscriptionId("subscription_id")
.thresholds(
- listOf(
- AlertCreateForSubscriptionParams.Threshold.builder().value(42.23).build()
- )
+ listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(0.0).build())
)
.type(AlertCreateForSubscriptionParams.Type.USAGE_EXCEEDED)
.metricId("metric_id")
@@ -37,7 +35,7 @@ class AlertCreateForSubscriptionParamsTest {
assertThat(body).isNotNull
assertThat(body.thresholds())
.isEqualTo(
- listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(42.23).build())
+ listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(0.0).build())
)
assertThat(body.type()).isEqualTo(AlertCreateForSubscriptionParams.Type.USAGE_EXCEEDED)
assertThat(body.metricId()).isEqualTo("metric_id")
@@ -49,9 +47,7 @@ class AlertCreateForSubscriptionParamsTest {
AlertCreateForSubscriptionParams.builder()
.subscriptionId("subscription_id")
.thresholds(
- listOf(
- AlertCreateForSubscriptionParams.Threshold.builder().value(42.23).build()
- )
+ listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(0.0).build())
)
.type(AlertCreateForSubscriptionParams.Type.USAGE_EXCEEDED)
.build()
@@ -59,7 +55,7 @@ class AlertCreateForSubscriptionParamsTest {
assertThat(body).isNotNull
assertThat(body.thresholds())
.isEqualTo(
- listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(42.23).build())
+ listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(0.0).build())
)
assertThat(body.type()).isEqualTo(AlertCreateForSubscriptionParams.Type.USAGE_EXCEEDED)
}
@@ -70,9 +66,7 @@ class AlertCreateForSubscriptionParamsTest {
AlertCreateForSubscriptionParams.builder()
.subscriptionId("subscription_id")
.thresholds(
- listOf(
- AlertCreateForSubscriptionParams.Threshold.builder().value(42.23).build()
- )
+ listOf(AlertCreateForSubscriptionParams.Threshold.builder().value(0.0).build())
)
.type(AlertCreateForSubscriptionParams.Type.USAGE_EXCEEDED)
.build()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertListParamsTest.kt
index cbf74f5d..0e92fefc 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertListParamsTest.kt
@@ -20,7 +20,7 @@ class AlertListParamsTest {
.cursor("cursor")
.customerId("customer_id")
.externalCustomerId("external_customer_id")
- .limit(123L)
+ .limit(1L)
.subscriptionId("subscription_id")
.build()
}
@@ -36,7 +36,7 @@ class AlertListParamsTest {
.cursor("cursor")
.customerId("customer_id")
.externalCustomerId("external_customer_id")
- .limit(123L)
+ .limit(1L)
.subscriptionId("subscription_id")
.build()
val expected = QueryParams.builder()
@@ -47,7 +47,7 @@ class AlertListParamsTest {
expected.put("cursor", "cursor")
expected.put("customer_id", "customer_id")
expected.put("external_customer_id", "external_customer_id")
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("subscription_id", "subscription_id")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertTest.kt
index 56db7974..a9786d6a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertTest.kt
@@ -20,7 +20,7 @@ class AlertTest {
.metric(Alert.Metric.builder().build())
.plan(Alert.Plan.builder().build())
.subscription(Alert.Subscription.builder().build())
- .thresholds(listOf(Alert.Threshold.builder().value(42.23).build()))
+ .thresholds(listOf(Alert.Threshold.builder().value(0.0).build()))
.type(Alert.Type.USAGE_EXCEEDED)
.build()
assertThat(alert).isNotNull
@@ -33,7 +33,7 @@ class AlertTest {
assertThat(alert.plan()).contains(Alert.Plan.builder().build())
assertThat(alert.subscription()).contains(Alert.Subscription.builder().build())
assertThat(alert.thresholds().get())
- .containsExactly(Alert.Threshold.builder().value(42.23).build())
+ .containsExactly(Alert.Threshold.builder().value(0.0).build())
assertThat(alert.type()).isEqualTo(Alert.Type.USAGE_EXCEEDED)
}
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertUpdateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertUpdateParamsTest.kt
index bdfa128c..4e54d478 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertUpdateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/AlertUpdateParamsTest.kt
@@ -12,7 +12,7 @@ class AlertUpdateParamsTest {
fun createAlertUpdateParams() {
AlertUpdateParams.builder()
.alertConfigurationId("alert_configuration_id")
- .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(42.23).build()))
+ .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(0.0).build()))
.build()
}
@@ -21,12 +21,12 @@ class AlertUpdateParamsTest {
val params =
AlertUpdateParams.builder()
.alertConfigurationId("alert_configuration_id")
- .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(42.23).build()))
+ .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(0.0).build()))
.build()
val body = params.getBody()
assertThat(body).isNotNull
assertThat(body.thresholds())
- .isEqualTo(listOf(AlertUpdateParams.Threshold.builder().value(42.23).build()))
+ .isEqualTo(listOf(AlertUpdateParams.Threshold.builder().value(0.0).build()))
}
@Test
@@ -34,12 +34,12 @@ class AlertUpdateParamsTest {
val params =
AlertUpdateParams.builder()
.alertConfigurationId("alert_configuration_id")
- .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(42.23).build()))
+ .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(0.0).build()))
.build()
val body = params.getBody()
assertThat(body).isNotNull
assertThat(body.thresholds())
- .isEqualTo(listOf(AlertUpdateParams.Threshold.builder().value(42.23).build()))
+ .isEqualTo(listOf(AlertUpdateParams.Threshold.builder().value(0.0).build()))
}
@Test
@@ -47,7 +47,7 @@ class AlertUpdateParamsTest {
val params =
AlertUpdateParams.builder()
.alertConfigurationId("alert_configuration_id")
- .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(42.23).build()))
+ .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(0.0).build()))
.build()
assertThat(params).isNotNull
// path param "alertConfigurationId"
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponCreateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponCreateParamsTest.kt
index e082143c..10e34bc2 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponCreateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponCreateParamsTest.kt
@@ -18,13 +18,13 @@ class CouponCreateParamsTest {
CouponCreateParams.Discount.NewCouponPercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.redemptionCode("HALFOFF")
- .durationInMonths(120L)
- .maxRedemptions(123L)
+ .durationInMonths(12L)
+ .maxRedemptions(1L)
.build()
}
@@ -39,13 +39,13 @@ class CouponCreateParamsTest {
CouponCreateParams.Discount.NewCouponPercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.redemptionCode("HALFOFF")
- .durationInMonths(120L)
- .maxRedemptions(123L)
+ .durationInMonths(12L)
+ .maxRedemptions(1L)
.build()
val body = params.getBody()
assertThat(body).isNotNull
@@ -57,13 +57,13 @@ class CouponCreateParamsTest {
CouponCreateParams.Discount.NewCouponPercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
assertThat(body.redemptionCode()).isEqualTo("HALFOFF")
- assertThat(body.durationInMonths()).isEqualTo(120L)
- assertThat(body.maxRedemptions()).isEqualTo(123L)
+ assertThat(body.durationInMonths()).isEqualTo(12L)
+ assertThat(body.maxRedemptions()).isEqualTo(1L)
}
@Test
@@ -77,7 +77,7 @@ class CouponCreateParamsTest {
CouponCreateParams.Discount.NewCouponPercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -93,7 +93,7 @@ class CouponCreateParamsTest {
CouponCreateParams.Discount.NewCouponPercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponListParamsTest.kt
index 1600ca5b..bafce926 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponListParamsTest.kt
@@ -13,7 +13,7 @@ class CouponListParamsTest {
fun createCouponListParams() {
CouponListParams.builder()
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.redemptionCode("redemption_code")
.showArchived(true)
.build()
@@ -24,13 +24,13 @@ class CouponListParamsTest {
val params =
CouponListParams.builder()
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.redemptionCode("redemption_code")
.showArchived(true)
.build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("redemption_code", "redemption_code")
expected.put("show_archived", "true")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponSubscriptionListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponSubscriptionListParamsTest.kt
index 298aebb8..98731d73 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponSubscriptionListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponSubscriptionListParamsTest.kt
@@ -14,7 +14,7 @@ class CouponSubscriptionListParamsTest {
CouponSubscriptionListParams.builder()
.couponId("coupon_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
}
@@ -24,11 +24,11 @@ class CouponSubscriptionListParamsTest {
CouponSubscriptionListParams.builder()
.couponId("coupon_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponTest.kt
index 9e2dbca5..47ff455c 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CouponTest.kt
@@ -19,15 +19,15 @@ class CouponTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .durationInMonths(123L)
- .maxRedemptions(123L)
+ .durationInMonths(12L)
+ .maxRedemptions(0L)
.redemptionCode("HALFOFF")
- .timesRedeemed(123L)
+ .timesRedeemed(0L)
.build()
assertThat(coupon).isNotNull
assertThat(coupon.id()).isEqualTo("7iz2yanVjQoBZhyH")
@@ -38,14 +38,14 @@ class CouponTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- assertThat(coupon.durationInMonths()).contains(123L)
- assertThat(coupon.maxRedemptions()).contains(123L)
+ assertThat(coupon.durationInMonths()).contains(12L)
+ assertThat(coupon.maxRedemptions()).contains(0L)
assertThat(coupon.redemptionCode()).isEqualTo("HALFOFF")
- assertThat(coupon.timesRedeemed()).isEqualTo(123L)
+ assertThat(coupon.timesRedeemed()).isEqualTo(0L)
}
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CreditNoteListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CreditNoteListParamsTest.kt
index 27660706..029d8844 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CreditNoteListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CreditNoteListParamsTest.kt
@@ -11,15 +11,15 @@ class CreditNoteListParamsTest {
@Test
fun createCreditNoteListParams() {
- CreditNoteListParams.builder().cursor("cursor").limit(123L).build()
+ CreditNoteListParams.builder().cursor("cursor").limit(1L).build()
}
@Test
fun getQueryParams() {
- val params = CreditNoteListParams.builder().cursor("cursor").limit(123L).build()
+ val params = CreditNoteListParams.builder().cursor("cursor").limit(1L).build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CreditNoteTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CreditNoteTest.kt
index 9f045f4d..b33c5721 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CreditNoteTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CreditNoteTest.kt
@@ -29,7 +29,7 @@ class CreditNoteTest {
.id("id")
.amount("amount")
.name("name")
- .quantity(42.23)
+ .quantity(0.0)
.subtotal("subtotal")
.taxAmounts(
listOf(
@@ -49,7 +49,7 @@ class CreditNoteTest {
.discountType(
CreditNote.LineItem.Discount.DiscountType.PERCENTAGE
)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.amountDiscount("amount_discount")
.reason("reason")
.build()
@@ -62,7 +62,7 @@ class CreditNoteTest {
CreditNote.MaximumAmountAdjustment.builder()
.amountApplied("amount_applied")
.discountType(CreditNote.MaximumAmountAdjustment.DiscountType.PERCENTAGE)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.appliesToPrices(
listOf(
CreditNote.MaximumAmountAdjustment.AppliesToPrice.builder()
@@ -86,7 +86,7 @@ class CreditNoteTest {
CreditNote.Discount.builder()
.amountApplied("amount_applied")
.discountType(CreditNote.Discount.DiscountType.PERCENTAGE)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.appliesToPrices(
listOf(
CreditNote.Discount.AppliesToPrice.builder()
@@ -120,7 +120,7 @@ class CreditNoteTest {
.id("id")
.amount("amount")
.name("name")
- .quantity(42.23)
+ .quantity(0.0)
.subtotal("subtotal")
.taxAmounts(
listOf(
@@ -138,7 +138,7 @@ class CreditNoteTest {
.amountApplied("amount_applied")
.appliesToPriceIds(listOf("string"))
.discountType(CreditNote.LineItem.Discount.DiscountType.PERCENTAGE)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.amountDiscount("amount_discount")
.reason("reason")
.build()
@@ -151,7 +151,7 @@ class CreditNoteTest {
CreditNote.MaximumAmountAdjustment.builder()
.amountApplied("amount_applied")
.discountType(CreditNote.MaximumAmountAdjustment.DiscountType.PERCENTAGE)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.appliesToPrices(
listOf(
CreditNote.MaximumAmountAdjustment.AppliesToPrice.builder()
@@ -175,7 +175,7 @@ class CreditNoteTest {
CreditNote.Discount.builder()
.amountApplied("amount_applied")
.discountType(CreditNote.Discount.DiscountType.PERCENTAGE)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.appliesToPrices(
listOf(
CreditNote.Discount.AppliesToPrice.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerBalanceTransactionListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerBalanceTransactionListParamsTest.kt
index 5afe2ed4..babe8e00 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerBalanceTransactionListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerBalanceTransactionListParamsTest.kt
@@ -15,7 +15,7 @@ class CustomerBalanceTransactionListParamsTest {
CustomerBalanceTransactionListParams.builder()
.customerId("customer_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.operationTimeGt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.operationTimeGte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.operationTimeLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -29,7 +29,7 @@ class CustomerBalanceTransactionListParamsTest {
CustomerBalanceTransactionListParams.builder()
.customerId("customer_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.operationTimeGt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.operationTimeGte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.operationTimeLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -37,7 +37,7 @@ class CustomerBalanceTransactionListParamsTest {
.build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("operation_time[gt]", "2019-12-27T18:11:19.117Z")
expected.put("operation_time[gte]", "2019-12-27T18:11:19.117Z")
expected.put("operation_time[lt]", "2019-12-27T18:11:19.117Z")
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCostListByExternalIdResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCostListByExternalIdResponseTest.kt
index 45062e25..cba3cf3b 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCostListByExternalIdResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCostListByExternalIdResponseTest.kt
@@ -30,7 +30,7 @@ class CustomerCostListByExternalIdResponseTest {
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.BillingCycleConfiguration
@@ -40,7 +40,7 @@ class CustomerCostListByExternalIdResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse(
"2019-12-27T18:11:19.117Z"
@@ -61,17 +61,17 @@ class CustomerCostListByExternalIdResponseTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.InvoicingCycleConfiguration
@@ -105,7 +105,7 @@ class CustomerCostListByExternalIdResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(
Price.UnitPrice.PriceType.USAGE_PRICE
)
@@ -119,7 +119,7 @@ class CustomerCostListByExternalIdResponseTest {
)
.subtotal("subtotal")
.total("total")
- .quantity(42.23)
+ .quantity(0.0)
.build()
)
)
@@ -149,7 +149,7 @@ class CustomerCostListByExternalIdResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -158,7 +158,7 @@ class CustomerCostListByExternalIdResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -177,17 +177,17 @@ class CustomerCostListByExternalIdResponseTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -218,7 +218,7 @@ class CustomerCostListByExternalIdResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -230,7 +230,7 @@ class CustomerCostListByExternalIdResponseTest {
)
.subtotal("subtotal")
.total("total")
- .quantity(42.23)
+ .quantity(0.0)
.build()
)
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCostListResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCostListResponseTest.kt
index ef53dd66..6a5fc463 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCostListResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCostListResponseTest.kt
@@ -30,7 +30,7 @@ class CustomerCostListResponseTest {
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.BillingCycleConfiguration
@@ -40,7 +40,7 @@ class CustomerCostListResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse(
"2019-12-27T18:11:19.117Z"
@@ -61,17 +61,17 @@ class CustomerCostListResponseTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.InvoicingCycleConfiguration
@@ -105,7 +105,7 @@ class CustomerCostListResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(
Price.UnitPrice.PriceType.USAGE_PRICE
)
@@ -119,7 +119,7 @@ class CustomerCostListResponseTest {
)
.subtotal("subtotal")
.total("total")
- .quantity(42.23)
+ .quantity(0.0)
.build()
)
)
@@ -149,7 +149,7 @@ class CustomerCostListResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -158,7 +158,7 @@ class CustomerCostListResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -177,17 +177,17 @@ class CustomerCostListResponseTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -218,7 +218,7 @@ class CustomerCostListResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -230,7 +230,7 @@ class CustomerCostListResponseTest {
)
.subtotal("subtotal")
.total("total")
- .quantity(42.23)
+ .quantity(0.0)
.build()
)
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerCreateEntryByExternalIdParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerCreateEntryByExternalIdParamsTest.kt
index 5da952a2..f21ee9c3 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerCreateEntryByExternalIdParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerCreateEntryByExternalIdParamsTest.kt
@@ -17,7 +17,7 @@ class CustomerCreditLedgerCreateEntryByExternalIdParamsTest {
CustomerCreditLedgerCreateEntryByExternalIdParams
.AddIncrementCreditLedgerEntryRequestParams
.builder()
- .amount(42.23)
+ .amount(0.0)
.entryType(
CustomerCreditLedgerCreateEntryByExternalIdParams
.AddIncrementCreditLedgerEntryRequestParams
@@ -34,7 +34,7 @@ class CustomerCreditLedgerCreateEntryByExternalIdParamsTest {
.InvoiceSettings
.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerCreateEntryParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerCreateEntryParamsTest.kt
index 26ab271c..43f21cbc 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerCreateEntryParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerCreateEntryParamsTest.kt
@@ -16,7 +16,7 @@ class CustomerCreditLedgerCreateEntryParamsTest {
.forAddIncrementCreditLedgerEntryRequestParams(
CustomerCreditLedgerCreateEntryParams.AddIncrementCreditLedgerEntryRequestParams
.builder()
- .amount(42.23)
+ .amount(0.0)
.entryType(
CustomerCreditLedgerCreateEntryParams
.AddIncrementCreditLedgerEntryRequestParams
@@ -33,7 +33,7 @@ class CustomerCreditLedgerCreateEntryParamsTest {
.InvoiceSettings
.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerListByExternalIdParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerListByExternalIdParamsTest.kt
index 266a4c08..f7bd3066 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerListByExternalIdParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerListByExternalIdParamsTest.kt
@@ -22,7 +22,7 @@ class CustomerCreditLedgerListByExternalIdParamsTest {
.cursor("cursor")
.entryStatus(CustomerCreditLedgerListByExternalIdParams.EntryStatus.COMMITTED)
.entryType(CustomerCreditLedgerListByExternalIdParams.EntryType.INCREMENT)
- .limit(123L)
+ .limit(1L)
.minimumAmount("minimum_amount")
.build()
}
@@ -40,7 +40,7 @@ class CustomerCreditLedgerListByExternalIdParamsTest {
.cursor("cursor")
.entryStatus(CustomerCreditLedgerListByExternalIdParams.EntryStatus.COMMITTED)
.entryType(CustomerCreditLedgerListByExternalIdParams.EntryType.INCREMENT)
- .limit(123L)
+ .limit(1L)
.minimumAmount("minimum_amount")
.build()
val expected = QueryParams.builder()
@@ -58,7 +58,7 @@ class CustomerCreditLedgerListByExternalIdParamsTest {
"entry_type",
CustomerCreditLedgerListByExternalIdParams.EntryType.INCREMENT.toString()
)
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("minimum_amount", "minimum_amount")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerListParamsTest.kt
index 72a47036..98dd3a7d 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditLedgerListParamsTest.kt
@@ -22,7 +22,7 @@ class CustomerCreditLedgerListParamsTest {
.cursor("cursor")
.entryStatus(CustomerCreditLedgerListParams.EntryStatus.COMMITTED)
.entryType(CustomerCreditLedgerListParams.EntryType.INCREMENT)
- .limit(123L)
+ .limit(1L)
.minimumAmount("minimum_amount")
.build()
}
@@ -40,7 +40,7 @@ class CustomerCreditLedgerListParamsTest {
.cursor("cursor")
.entryStatus(CustomerCreditLedgerListParams.EntryStatus.COMMITTED)
.entryType(CustomerCreditLedgerListParams.EntryType.INCREMENT)
- .limit(123L)
+ .limit(1L)
.minimumAmount("minimum_amount")
.build()
val expected = QueryParams.builder()
@@ -55,7 +55,7 @@ class CustomerCreditLedgerListParamsTest {
CustomerCreditLedgerListParams.EntryStatus.COMMITTED.toString()
)
expected.put("entry_type", CustomerCreditLedgerListParams.EntryType.INCREMENT.toString())
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("minimum_amount", "minimum_amount")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListByExternalIdParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListByExternalIdParamsTest.kt
index 5becab64..0880d599 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListByExternalIdParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListByExternalIdParamsTest.kt
@@ -16,7 +16,7 @@ class CustomerCreditListByExternalIdParamsTest {
.currency("currency")
.cursor("cursor")
.includeAllBlocks(true)
- .limit(123L)
+ .limit(1L)
.build()
}
@@ -28,13 +28,13 @@ class CustomerCreditListByExternalIdParamsTest {
.currency("currency")
.cursor("cursor")
.includeAllBlocks(true)
- .limit(123L)
+ .limit(1L)
.build()
val expected = QueryParams.builder()
expected.put("currency", "currency")
expected.put("cursor", "cursor")
expected.put("include_all_blocks", "true")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListByExternalIdResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListByExternalIdResponseTest.kt
index 7cc47144..32664946 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListByExternalIdResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListByExternalIdResponseTest.kt
@@ -13,21 +13,21 @@ class CustomerCreditListByExternalIdResponseTest {
val customerCreditListByExternalIdResponse =
CustomerCreditListByExternalIdResponse.builder()
.id("id")
- .balance(42.23)
+ .balance(0.0)
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.expiryDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .maximumInitialBalance(42.23)
+ .maximumInitialBalance(0.0)
.perUnitCostBasis("per_unit_cost_basis")
.status(CustomerCreditListByExternalIdResponse.Status.ACTIVE)
.build()
assertThat(customerCreditListByExternalIdResponse).isNotNull
assertThat(customerCreditListByExternalIdResponse.id()).isEqualTo("id")
- assertThat(customerCreditListByExternalIdResponse.balance()).isEqualTo(42.23)
+ assertThat(customerCreditListByExternalIdResponse.balance()).isEqualTo(0.0)
assertThat(customerCreditListByExternalIdResponse.effectiveDate())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(customerCreditListByExternalIdResponse.expiryDate())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- assertThat(customerCreditListByExternalIdResponse.maximumInitialBalance()).contains(42.23)
+ assertThat(customerCreditListByExternalIdResponse.maximumInitialBalance()).contains(0.0)
assertThat(customerCreditListByExternalIdResponse.perUnitCostBasis())
.contains("per_unit_cost_basis")
assertThat(customerCreditListByExternalIdResponse.status())
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListParamsTest.kt
index cee59270..8c82d989 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListParamsTest.kt
@@ -16,7 +16,7 @@ class CustomerCreditListParamsTest {
.currency("currency")
.cursor("cursor")
.includeAllBlocks(true)
- .limit(123L)
+ .limit(1L)
.build()
}
@@ -28,13 +28,13 @@ class CustomerCreditListParamsTest {
.currency("currency")
.cursor("cursor")
.includeAllBlocks(true)
- .limit(123L)
+ .limit(1L)
.build()
val expected = QueryParams.builder()
expected.put("currency", "currency")
expected.put("cursor", "cursor")
expected.put("include_all_blocks", "true")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListResponseTest.kt
index 7440f079..f4130161 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditListResponseTest.kt
@@ -13,21 +13,21 @@ class CustomerCreditListResponseTest {
val customerCreditListResponse =
CustomerCreditListResponse.builder()
.id("id")
- .balance(42.23)
+ .balance(0.0)
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.expiryDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .maximumInitialBalance(42.23)
+ .maximumInitialBalance(0.0)
.perUnitCostBasis("per_unit_cost_basis")
.status(CustomerCreditListResponse.Status.ACTIVE)
.build()
assertThat(customerCreditListResponse).isNotNull
assertThat(customerCreditListResponse.id()).isEqualTo("id")
- assertThat(customerCreditListResponse.balance()).isEqualTo(42.23)
+ assertThat(customerCreditListResponse.balance()).isEqualTo(0.0)
assertThat(customerCreditListResponse.effectiveDate())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(customerCreditListResponse.expiryDate())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- assertThat(customerCreditListResponse.maximumInitialBalance()).contains(42.23)
+ assertThat(customerCreditListResponse.maximumInitialBalance()).contains(0.0)
assertThat(customerCreditListResponse.perUnitCostBasis()).contains("per_unit_cost_basis")
assertThat(customerCreditListResponse.status())
.isEqualTo(CustomerCreditListResponse.Status.ACTIVE)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateByExternalIdParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateByExternalIdParamsTest.kt
index 6a5e4a98..2bd7664f 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateByExternalIdParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateByExternalIdParamsTest.kt
@@ -17,14 +17,14 @@ class CustomerCreditTopUpCreateByExternalIdParamsTest {
.invoiceSettings(
CustomerCreditTopUpCreateByExternalIdParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(CustomerCreditTopUpCreateByExternalIdParams.ExpiresAfterUnit.DAY)
.build()
}
@@ -39,14 +39,14 @@ class CustomerCreditTopUpCreateByExternalIdParamsTest {
.invoiceSettings(
CustomerCreditTopUpCreateByExternalIdParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(CustomerCreditTopUpCreateByExternalIdParams.ExpiresAfterUnit.DAY)
.build()
val body = params.getBody()
@@ -57,14 +57,14 @@ class CustomerCreditTopUpCreateByExternalIdParamsTest {
.isEqualTo(
CustomerCreditTopUpCreateByExternalIdParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
assertThat(body.perUnitCostBasis()).isEqualTo("per_unit_cost_basis")
assertThat(body.threshold()).isEqualTo("threshold")
- assertThat(body.expiresAfter()).isEqualTo(123L)
+ assertThat(body.expiresAfter()).isEqualTo(0L)
assertThat(body.expiresAfterUnit())
.isEqualTo(CustomerCreditTopUpCreateByExternalIdParams.ExpiresAfterUnit.DAY)
}
@@ -79,7 +79,7 @@ class CustomerCreditTopUpCreateByExternalIdParamsTest {
.invoiceSettings(
CustomerCreditTopUpCreateByExternalIdParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
@@ -93,7 +93,7 @@ class CustomerCreditTopUpCreateByExternalIdParamsTest {
.isEqualTo(
CustomerCreditTopUpCreateByExternalIdParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.build()
)
assertThat(body.perUnitCostBasis()).isEqualTo("per_unit_cost_basis")
@@ -110,7 +110,7 @@ class CustomerCreditTopUpCreateByExternalIdParamsTest {
.invoiceSettings(
CustomerCreditTopUpCreateByExternalIdParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateByExternalIdResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateByExternalIdResponseTest.kt
index b7edd381..b79e220e 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateByExternalIdResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateByExternalIdResponseTest.kt
@@ -17,14 +17,14 @@ class CustomerCreditTopUpCreateByExternalIdResponseTest {
.invoiceSettings(
CustomerCreditTopUpCreateByExternalIdResponse.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(
CustomerCreditTopUpCreateByExternalIdResponse.ExpiresAfterUnit.DAY
)
@@ -37,7 +37,7 @@ class CustomerCreditTopUpCreateByExternalIdResponseTest {
.isEqualTo(
CustomerCreditTopUpCreateByExternalIdResponse.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
@@ -45,7 +45,7 @@ class CustomerCreditTopUpCreateByExternalIdResponseTest {
assertThat(customerCreditTopUpCreateByExternalIdResponse.perUnitCostBasis())
.isEqualTo("per_unit_cost_basis")
assertThat(customerCreditTopUpCreateByExternalIdResponse.threshold()).isEqualTo("threshold")
- assertThat(customerCreditTopUpCreateByExternalIdResponse.expiresAfter()).contains(123L)
+ assertThat(customerCreditTopUpCreateByExternalIdResponse.expiresAfter()).contains(0L)
assertThat(customerCreditTopUpCreateByExternalIdResponse.expiresAfterUnit())
.contains(CustomerCreditTopUpCreateByExternalIdResponse.ExpiresAfterUnit.DAY)
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateParamsTest.kt
index 836315bc..c54031ba 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateParamsTest.kt
@@ -17,14 +17,14 @@ class CustomerCreditTopUpCreateParamsTest {
.invoiceSettings(
CustomerCreditTopUpCreateParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(CustomerCreditTopUpCreateParams.ExpiresAfterUnit.DAY)
.build()
}
@@ -39,14 +39,14 @@ class CustomerCreditTopUpCreateParamsTest {
.invoiceSettings(
CustomerCreditTopUpCreateParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(CustomerCreditTopUpCreateParams.ExpiresAfterUnit.DAY)
.build()
val body = params.getBody()
@@ -57,14 +57,14 @@ class CustomerCreditTopUpCreateParamsTest {
.isEqualTo(
CustomerCreditTopUpCreateParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
assertThat(body.perUnitCostBasis()).isEqualTo("per_unit_cost_basis")
assertThat(body.threshold()).isEqualTo("threshold")
- assertThat(body.expiresAfter()).isEqualTo(123L)
+ assertThat(body.expiresAfter()).isEqualTo(0L)
assertThat(body.expiresAfterUnit())
.isEqualTo(CustomerCreditTopUpCreateParams.ExpiresAfterUnit.DAY)
}
@@ -79,7 +79,7 @@ class CustomerCreditTopUpCreateParamsTest {
.invoiceSettings(
CustomerCreditTopUpCreateParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
@@ -93,7 +93,7 @@ class CustomerCreditTopUpCreateParamsTest {
.isEqualTo(
CustomerCreditTopUpCreateParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.build()
)
assertThat(body.perUnitCostBasis()).isEqualTo("per_unit_cost_basis")
@@ -110,7 +110,7 @@ class CustomerCreditTopUpCreateParamsTest {
.invoiceSettings(
CustomerCreditTopUpCreateParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateResponseTest.kt
index 92267cc6..7cfe9318 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpCreateResponseTest.kt
@@ -17,14 +17,14 @@ class CustomerCreditTopUpCreateResponseTest {
.invoiceSettings(
CustomerCreditTopUpCreateResponse.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(CustomerCreditTopUpCreateResponse.ExpiresAfterUnit.DAY)
.build()
assertThat(customerCreditTopUpCreateResponse).isNotNull
@@ -35,7 +35,7 @@ class CustomerCreditTopUpCreateResponseTest {
.isEqualTo(
CustomerCreditTopUpCreateResponse.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
@@ -43,7 +43,7 @@ class CustomerCreditTopUpCreateResponseTest {
assertThat(customerCreditTopUpCreateResponse.perUnitCostBasis())
.isEqualTo("per_unit_cost_basis")
assertThat(customerCreditTopUpCreateResponse.threshold()).isEqualTo("threshold")
- assertThat(customerCreditTopUpCreateResponse.expiresAfter()).contains(123L)
+ assertThat(customerCreditTopUpCreateResponse.expiresAfter()).contains(0L)
assertThat(customerCreditTopUpCreateResponse.expiresAfterUnit())
.contains(CustomerCreditTopUpCreateResponse.ExpiresAfterUnit.DAY)
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListByExternalIdParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListByExternalIdParamsTest.kt
index 5053b841..7dbb5df8 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListByExternalIdParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListByExternalIdParamsTest.kt
@@ -14,7 +14,7 @@ class CustomerCreditTopUpListByExternalIdParamsTest {
CustomerCreditTopUpListByExternalIdParams.builder()
.externalCustomerId("external_customer_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
}
@@ -24,11 +24,11 @@ class CustomerCreditTopUpListByExternalIdParamsTest {
CustomerCreditTopUpListByExternalIdParams.builder()
.externalCustomerId("external_customer_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListByExternalIdResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListByExternalIdResponseTest.kt
index 0d6e131f..e0e17805 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListByExternalIdResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListByExternalIdResponseTest.kt
@@ -17,14 +17,14 @@ class CustomerCreditTopUpListByExternalIdResponseTest {
.invoiceSettings(
CustomerCreditTopUpListByExternalIdResponse.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(CustomerCreditTopUpListByExternalIdResponse.ExpiresAfterUnit.DAY)
.build()
assertThat(customerCreditTopUpListByExternalIdResponse).isNotNull
@@ -35,7 +35,7 @@ class CustomerCreditTopUpListByExternalIdResponseTest {
.isEqualTo(
CustomerCreditTopUpListByExternalIdResponse.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
@@ -43,7 +43,7 @@ class CustomerCreditTopUpListByExternalIdResponseTest {
assertThat(customerCreditTopUpListByExternalIdResponse.perUnitCostBasis())
.isEqualTo("per_unit_cost_basis")
assertThat(customerCreditTopUpListByExternalIdResponse.threshold()).isEqualTo("threshold")
- assertThat(customerCreditTopUpListByExternalIdResponse.expiresAfter()).contains(123L)
+ assertThat(customerCreditTopUpListByExternalIdResponse.expiresAfter()).contains(0L)
assertThat(customerCreditTopUpListByExternalIdResponse.expiresAfterUnit())
.contains(CustomerCreditTopUpListByExternalIdResponse.ExpiresAfterUnit.DAY)
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListParamsTest.kt
index 478d0112..d9b3e8d8 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListParamsTest.kt
@@ -14,7 +14,7 @@ class CustomerCreditTopUpListParamsTest {
CustomerCreditTopUpListParams.builder()
.customerId("customer_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
}
@@ -24,11 +24,11 @@ class CustomerCreditTopUpListParamsTest {
CustomerCreditTopUpListParams.builder()
.customerId("customer_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListResponseTest.kt
index 32cb08d4..1bba8d29 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerCreditTopUpListResponseTest.kt
@@ -17,14 +17,14 @@ class CustomerCreditTopUpListResponseTest {
.invoiceSettings(
CustomerCreditTopUpListResponse.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(CustomerCreditTopUpListResponse.ExpiresAfterUnit.DAY)
.build()
assertThat(customerCreditTopUpListResponse).isNotNull
@@ -35,7 +35,7 @@ class CustomerCreditTopUpListResponseTest {
.isEqualTo(
CustomerCreditTopUpListResponse.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
@@ -43,7 +43,7 @@ class CustomerCreditTopUpListResponseTest {
assertThat(customerCreditTopUpListResponse.perUnitCostBasis())
.isEqualTo("per_unit_cost_basis")
assertThat(customerCreditTopUpListResponse.threshold()).isEqualTo("threshold")
- assertThat(customerCreditTopUpListResponse.expiresAfter()).contains(123L)
+ assertThat(customerCreditTopUpListResponse.expiresAfter()).contains(0L)
assertThat(customerCreditTopUpListResponse.expiresAfterUnit())
.contains(CustomerCreditTopUpListResponse.ExpiresAfterUnit.DAY)
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerListParamsTest.kt
index 63e66d4e..023f3f9a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/CustomerListParamsTest.kt
@@ -18,7 +18,7 @@ class CustomerListParamsTest {
.createdAtLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAtLte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
}
@@ -31,7 +31,7 @@ class CustomerListParamsTest {
.createdAtLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAtLte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
val expected = QueryParams.builder()
expected.put("created_at[gt]", "2019-12-27T18:11:19.117Z")
@@ -39,7 +39,7 @@ class CustomerListParamsTest {
expected.put("created_at[lt]", "2019-12-27T18:11:19.117Z")
expected.put("created_at[lte]", "2019-12-27T18:11:19.117Z")
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EvaluatePriceGroupTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EvaluatePriceGroupTest.kt
index 1bfd2513..cc5c9fdf 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EvaluatePriceGroupTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EvaluatePriceGroupTest.kt
@@ -13,12 +13,12 @@ class EvaluatePriceGroupTest {
EvaluatePriceGroup.builder()
.amount("amount")
.groupingValues(listOf(EvaluatePriceGroup.GroupingValue.ofString("string")))
- .quantity(42.23)
+ .quantity(0.0)
.build()
assertThat(evaluatePriceGroup).isNotNull
assertThat(evaluatePriceGroup.amount()).isEqualTo("amount")
assertThat(evaluatePriceGroup.groupingValues())
.containsExactly(EvaluatePriceGroup.GroupingValue.ofString("string"))
- assertThat(evaluatePriceGroup.quantity()).isEqualTo(42.23)
+ assertThat(evaluatePriceGroup.quantity()).isEqualTo(0.0)
}
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillCloseResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillCloseResponseTest.kt
index 8233a85c..56c5257e 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillCloseResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillCloseResponseTest.kt
@@ -16,7 +16,7 @@ class EventBackfillCloseResponseTest {
.closeTime(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.customerId("customer_id")
- .eventsIngested(123L)
+ .eventsIngested(0L)
.revertedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.status(EventBackfillCloseResponse.Status.PENDING)
.timeframeEnd(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -30,7 +30,7 @@ class EventBackfillCloseResponseTest {
assertThat(eventBackfillCloseResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillCloseResponse.customerId()).contains("customer_id")
- assertThat(eventBackfillCloseResponse.eventsIngested()).isEqualTo(123L)
+ assertThat(eventBackfillCloseResponse.eventsIngested()).isEqualTo(0L)
assertThat(eventBackfillCloseResponse.revertedAt())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillCloseResponse.status())
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillCreateResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillCreateResponseTest.kt
index cb9a31d1..bf54358f 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillCreateResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillCreateResponseTest.kt
@@ -16,7 +16,7 @@ class EventBackfillCreateResponseTest {
.closeTime(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.customerId("customer_id")
- .eventsIngested(123L)
+ .eventsIngested(0L)
.revertedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.status(EventBackfillCreateResponse.Status.PENDING)
.timeframeEnd(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -30,7 +30,7 @@ class EventBackfillCreateResponseTest {
assertThat(eventBackfillCreateResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillCreateResponse.customerId()).contains("customer_id")
- assertThat(eventBackfillCreateResponse.eventsIngested()).isEqualTo(123L)
+ assertThat(eventBackfillCreateResponse.eventsIngested()).isEqualTo(0L)
assertThat(eventBackfillCreateResponse.revertedAt())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillCreateResponse.status())
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillFetchResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillFetchResponseTest.kt
index d8f638a0..4d15aeff 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillFetchResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillFetchResponseTest.kt
@@ -16,7 +16,7 @@ class EventBackfillFetchResponseTest {
.closeTime(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.customerId("customer_id")
- .eventsIngested(123L)
+ .eventsIngested(0L)
.revertedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.status(EventBackfillFetchResponse.Status.PENDING)
.timeframeEnd(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -30,7 +30,7 @@ class EventBackfillFetchResponseTest {
assertThat(eventBackfillFetchResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillFetchResponse.customerId()).contains("customer_id")
- assertThat(eventBackfillFetchResponse.eventsIngested()).isEqualTo(123L)
+ assertThat(eventBackfillFetchResponse.eventsIngested()).isEqualTo(0L)
assertThat(eventBackfillFetchResponse.revertedAt())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillFetchResponse.status())
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillListParamsTest.kt
index fd34634a..eb6c6b28 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillListParamsTest.kt
@@ -11,15 +11,15 @@ class EventBackfillListParamsTest {
@Test
fun createEventBackfillListParams() {
- EventBackfillListParams.builder().cursor("cursor").limit(123L).build()
+ EventBackfillListParams.builder().cursor("cursor").limit(1L).build()
}
@Test
fun getQueryParams() {
- val params = EventBackfillListParams.builder().cursor("cursor").limit(123L).build()
+ val params = EventBackfillListParams.builder().cursor("cursor").limit(1L).build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillListResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillListResponseTest.kt
index 508d2d5f..f9ca8d6a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillListResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillListResponseTest.kt
@@ -16,7 +16,7 @@ class EventBackfillListResponseTest {
.closeTime(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.customerId("customer_id")
- .eventsIngested(123L)
+ .eventsIngested(0L)
.revertedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.status(EventBackfillListResponse.Status.PENDING)
.timeframeEnd(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -30,7 +30,7 @@ class EventBackfillListResponseTest {
assertThat(eventBackfillListResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillListResponse.customerId()).contains("customer_id")
- assertThat(eventBackfillListResponse.eventsIngested()).isEqualTo(123L)
+ assertThat(eventBackfillListResponse.eventsIngested()).isEqualTo(0L)
assertThat(eventBackfillListResponse.revertedAt())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillListResponse.status())
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillRevertResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillRevertResponseTest.kt
index 684ce8d9..1cc59511 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillRevertResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventBackfillRevertResponseTest.kt
@@ -16,7 +16,7 @@ class EventBackfillRevertResponseTest {
.closeTime(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.customerId("customer_id")
- .eventsIngested(123L)
+ .eventsIngested(0L)
.revertedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.status(EventBackfillRevertResponse.Status.PENDING)
.timeframeEnd(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -30,7 +30,7 @@ class EventBackfillRevertResponseTest {
assertThat(eventBackfillRevertResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillRevertResponse.customerId()).contains("customer_id")
- assertThat(eventBackfillRevertResponse.eventsIngested()).isEqualTo(123L)
+ assertThat(eventBackfillRevertResponse.eventsIngested()).isEqualTo(0L)
assertThat(eventBackfillRevertResponse.revertedAt())
.contains(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(eventBackfillRevertResponse.status())
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventVolumeListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventVolumeListParamsTest.kt
index 3104308a..db58bf95 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventVolumeListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventVolumeListParamsTest.kt
@@ -15,7 +15,7 @@ class EventVolumeListParamsTest {
EventVolumeListParams.builder()
.timeframeStart(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.timeframeEnd(OffsetDateTime.parse("2024-10-11T06:00:00Z"))
.build()
}
@@ -26,13 +26,13 @@ class EventVolumeListParamsTest {
EventVolumeListParams.builder()
.timeframeStart(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.timeframeEnd(OffsetDateTime.parse("2024-10-11T06:00:00Z"))
.build()
val expected = QueryParams.builder()
expected.put("timeframe_start", "2019-12-27T18:11:19.117Z")
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("timeframe_end", "2024-10-11T06:00:00Z")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventVolumesTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventVolumesTest.kt
index f632b653..7e6a4630 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/EventVolumesTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/EventVolumesTest.kt
@@ -15,7 +15,7 @@ class EventVolumesTest {
.data(
listOf(
EventVolumes.Data.builder()
- .count(123L)
+ .count(0L)
.timeframeEnd(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.timeframeStart(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
@@ -26,7 +26,7 @@ class EventVolumesTest {
assertThat(eventVolumes.data())
.containsExactly(
EventVolumes.Data.builder()
- .count(123L)
+ .count(0L)
.timeframeEnd(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.timeframeStart(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceCreateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceCreateParamsTest.kt
index d6a92dd7..6610f74c 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceCreateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceCreateParamsTest.kt
@@ -22,7 +22,7 @@ class InvoiceCreateParamsTest {
.itemId("4khy3nwzktxv7")
.modelType(InvoiceCreateParams.LineItem.ModelType.UNIT)
.name("Line Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.unitConfig(
InvoiceCreateParams.LineItem.UnitConfig.builder()
@@ -32,14 +32,14 @@ class InvoiceCreateParamsTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.customerId("4khy3nwzktxv7")
.discount(
Discount.ofPercentageDiscount(
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -47,7 +47,7 @@ class InvoiceCreateParamsTest {
.externalCustomerId("external-customer-id")
.memo("An optional memo for my invoice.")
.metadata(InvoiceCreateParams.Metadata.builder().build())
- .willAutoIssue(true)
+ .willAutoIssue(false)
.build()
}
@@ -64,7 +64,7 @@ class InvoiceCreateParamsTest {
.itemId("4khy3nwzktxv7")
.modelType(InvoiceCreateParams.LineItem.ModelType.UNIT)
.name("Line Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.unitConfig(
InvoiceCreateParams.LineItem.UnitConfig.builder()
@@ -74,14 +74,14 @@ class InvoiceCreateParamsTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.customerId("4khy3nwzktxv7")
.discount(
Discount.ofPercentageDiscount(
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -89,7 +89,7 @@ class InvoiceCreateParamsTest {
.externalCustomerId("external-customer-id")
.memo("An optional memo for my invoice.")
.metadata(InvoiceCreateParams.Metadata.builder().build())
- .willAutoIssue(true)
+ .willAutoIssue(false)
.build()
val body = params.getBody()
assertThat(body).isNotNull
@@ -103,7 +103,7 @@ class InvoiceCreateParamsTest {
.itemId("4khy3nwzktxv7")
.modelType(InvoiceCreateParams.LineItem.ModelType.UNIT)
.name("Line Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.unitConfig(
InvoiceCreateParams.LineItem.UnitConfig.builder()
@@ -113,7 +113,7 @@ class InvoiceCreateParamsTest {
.build()
)
)
- assertThat(body.netTerms()).isEqualTo(123L)
+ assertThat(body.netTerms()).isEqualTo(0L)
assertThat(body.customerId()).isEqualTo("4khy3nwzktxv7")
assertThat(body.discount())
.isEqualTo(
@@ -121,7 +121,7 @@ class InvoiceCreateParamsTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -129,7 +129,7 @@ class InvoiceCreateParamsTest {
assertThat(body.externalCustomerId()).isEqualTo("external-customer-id")
assertThat(body.memo()).isEqualTo("An optional memo for my invoice.")
assertThat(body.metadata()).isEqualTo(InvoiceCreateParams.Metadata.builder().build())
- assertThat(body.willAutoIssue()).isEqualTo(true)
+ assertThat(body.willAutoIssue()).isEqualTo(false)
}
@Test
@@ -145,7 +145,7 @@ class InvoiceCreateParamsTest {
.itemId("4khy3nwzktxv7")
.modelType(InvoiceCreateParams.LineItem.ModelType.UNIT)
.name("Line Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.unitConfig(
InvoiceCreateParams.LineItem.UnitConfig.builder()
@@ -155,7 +155,7 @@ class InvoiceCreateParamsTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.build()
val body = params.getBody()
assertThat(body).isNotNull
@@ -169,7 +169,7 @@ class InvoiceCreateParamsTest {
.itemId("4khy3nwzktxv7")
.modelType(InvoiceCreateParams.LineItem.ModelType.UNIT)
.name("Line Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.unitConfig(
InvoiceCreateParams.LineItem.UnitConfig.builder()
@@ -179,6 +179,6 @@ class InvoiceCreateParamsTest {
.build()
)
)
- assertThat(body.netTerms()).isEqualTo(123L)
+ assertThat(body.netTerms()).isEqualTo(0L)
}
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponseTest.kt
index 81e61796..e9b4e748 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceFetchUpcomingResponseTest.kt
@@ -19,7 +19,7 @@ class InvoiceFetchUpcomingResponseTest {
InvoiceFetchUpcomingResponse.AutoCollection.builder()
.enabled(true)
.nextAttemptAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .numAttempts(123L)
+ .numAttempts(0L)
.previouslyAttemptedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -100,7 +100,7 @@ class InvoiceFetchUpcomingResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -124,7 +124,7 @@ class InvoiceFetchUpcomingResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -157,7 +157,7 @@ class InvoiceFetchUpcomingResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -166,7 +166,7 @@ class InvoiceFetchUpcomingResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -182,16 +182,16 @@ class InvoiceFetchUpcomingResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -222,7 +222,7 @@ class InvoiceFetchUpcomingResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -232,7 +232,7 @@ class InvoiceFetchUpcomingResponseTest {
.build()
)
)
- .quantity(42.23)
+ .quantity(1.0)
.startDate(OffsetDateTime.parse("2022-02-01T08:00:00+00:00"))
.subLineItems(
listOf(
@@ -262,7 +262,7 @@ class InvoiceFetchUpcomingResponseTest {
.build()
)
.name("Tier One")
- .quantity(42.23)
+ .quantity(5.0)
.type(
InvoiceFetchUpcomingResponse.LineItem
.SubLineItem
@@ -352,7 +352,7 @@ class InvoiceFetchUpcomingResponseTest {
InvoiceFetchUpcomingResponse.AutoCollection.builder()
.enabled(true)
.nextAttemptAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .numAttempts(123L)
+ .numAttempts(0L)
.previouslyAttemptedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -430,7 +430,7 @@ class InvoiceFetchUpcomingResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -459,7 +459,7 @@ class InvoiceFetchUpcomingResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -490,7 +490,7 @@ class InvoiceFetchUpcomingResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -498,7 +498,7 @@ class InvoiceFetchUpcomingResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -514,16 +514,16 @@ class InvoiceFetchUpcomingResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -548,7 +548,7 @@ class InvoiceFetchUpcomingResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -558,7 +558,7 @@ class InvoiceFetchUpcomingResponseTest {
.build()
)
)
- .quantity(42.23)
+ .quantity(1.0)
.startDate(OffsetDateTime.parse("2022-02-01T08:00:00+00:00"))
.subLineItems(
listOf(
@@ -584,7 +584,7 @@ class InvoiceFetchUpcomingResponseTest {
.build()
)
.name("Tier One")
- .quantity(42.23)
+ .quantity(5.0)
.type(
InvoiceFetchUpcomingResponse.LineItem.SubLineItem
.MatrixSubLineItem
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceLineItemCreateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceLineItemCreateParamsTest.kt
index 0daafd3c..ce6cff78 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceLineItemCreateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceLineItemCreateParamsTest.kt
@@ -16,7 +16,7 @@ class InvoiceLineItemCreateParamsTest {
.endDate(LocalDate.parse("2023-09-22"))
.invoiceId("4khy3nwzktxv7")
.name("Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.build()
}
@@ -29,7 +29,7 @@ class InvoiceLineItemCreateParamsTest {
.endDate(LocalDate.parse("2023-09-22"))
.invoiceId("4khy3nwzktxv7")
.name("Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.build()
val body = params.getBody()
@@ -38,7 +38,7 @@ class InvoiceLineItemCreateParamsTest {
assertThat(body.endDate()).isEqualTo(LocalDate.parse("2023-09-22"))
assertThat(body.invoiceId()).isEqualTo("4khy3nwzktxv7")
assertThat(body.name()).isEqualTo("Item Name")
- assertThat(body.quantity()).isEqualTo(42.23)
+ assertThat(body.quantity()).isEqualTo(1.0)
assertThat(body.startDate()).isEqualTo(LocalDate.parse("2023-09-22"))
}
@@ -50,7 +50,7 @@ class InvoiceLineItemCreateParamsTest {
.endDate(LocalDate.parse("2023-09-22"))
.invoiceId("4khy3nwzktxv7")
.name("Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.build()
val body = params.getBody()
@@ -59,7 +59,7 @@ class InvoiceLineItemCreateParamsTest {
assertThat(body.endDate()).isEqualTo(LocalDate.parse("2023-09-22"))
assertThat(body.invoiceId()).isEqualTo("4khy3nwzktxv7")
assertThat(body.name()).isEqualTo("Item Name")
- assertThat(body.quantity()).isEqualTo(42.23)
+ assertThat(body.quantity()).isEqualTo(1.0)
assertThat(body.startDate()).isEqualTo(LocalDate.parse("2023-09-22"))
}
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceLineItemCreateResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceLineItemCreateResponseTest.kt
index ec2f9a72..b1c99f76 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceLineItemCreateResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceLineItemCreateResponseTest.kt
@@ -19,7 +19,7 @@ class InvoiceLineItemCreateResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -50,14 +50,14 @@ class InvoiceLineItemCreateResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit.DAY
)
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -71,16 +71,16 @@ class InvoiceLineItemCreateResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit.DAY
)
@@ -104,7 +104,7 @@ class InvoiceLineItemCreateResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -114,7 +114,7 @@ class InvoiceLineItemCreateResponseTest {
.build()
)
)
- .quantity(42.23)
+ .quantity(1.0)
.startDate(OffsetDateTime.parse("2022-02-01T08:00:00+00:00"))
.subLineItems(
listOf(
@@ -137,7 +137,7 @@ class InvoiceLineItemCreateResponseTest {
.build()
)
.name("Tier One")
- .quantity(42.23)
+ .quantity(5.0)
.type(
InvoiceLineItemCreateResponse.SubLineItem.MatrixSubLineItem.Type
.MATRIX
@@ -166,7 +166,7 @@ class InvoiceLineItemCreateResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -199,14 +199,14 @@ class InvoiceLineItemCreateResponseTest {
.billableMetric(Price.UnitPrice.BillableMetric.builder().id("id").build())
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit.DAY
)
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -220,16 +220,16 @@ class InvoiceLineItemCreateResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit.DAY
)
@@ -253,7 +253,7 @@ class InvoiceLineItemCreateResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder().unitAmount("unit_amount").build()
@@ -261,7 +261,7 @@ class InvoiceLineItemCreateResponseTest {
.build()
)
)
- assertThat(invoiceLineItemCreateResponse.quantity()).isEqualTo(42.23)
+ assertThat(invoiceLineItemCreateResponse.quantity()).isEqualTo(1.0)
assertThat(invoiceLineItemCreateResponse.startDate())
.isEqualTo(OffsetDateTime.parse("2022-02-01T08:00:00+00:00"))
assertThat(invoiceLineItemCreateResponse.subLineItems())
@@ -283,7 +283,7 @@ class InvoiceLineItemCreateResponseTest {
.build()
)
.name("Tier One")
- .quantity(42.23)
+ .quantity(5.0)
.type(
InvoiceLineItemCreateResponse.SubLineItem.MatrixSubLineItem.Type.MATRIX
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceListParamsTest.kt
index 2cae690d..6cb5c94f 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceListParamsTest.kt
@@ -30,7 +30,7 @@ class InvoiceListParamsTest {
.invoiceDateLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.invoiceDateLte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.isRecurring(true)
- .limit(123L)
+ .limit(1L)
.status(listOf(InvoiceListParams.Status.DRAFT))
.subscriptionId("subscription_id")
.build()
@@ -56,7 +56,7 @@ class InvoiceListParamsTest {
.invoiceDateLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.invoiceDateLte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.isRecurring(true)
- .limit(123L)
+ .limit(1L)
.status(listOf(InvoiceListParams.Status.DRAFT))
.subscriptionId("subscription_id")
.build()
@@ -77,7 +77,7 @@ class InvoiceListParamsTest {
expected.put("invoice_date[lt]", "2019-12-27T18:11:19.117Z")
expected.put("invoice_date[lte]", "2019-12-27T18:11:19.117Z")
expected.put("is_recurring", "true")
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("status[]", InvoiceListParams.Status.DRAFT.toString())
expected.put("subscription_id", "subscription_id")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceTest.kt
index d346b159..9ceb3896 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/InvoiceTest.kt
@@ -19,7 +19,7 @@ class InvoiceTest {
Invoice.AutoCollection.builder()
.enabled(true)
.nextAttemptAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .numAttempts(123L)
+ .numAttempts(0L)
.previouslyAttemptedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -92,7 +92,7 @@ class InvoiceTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -117,7 +117,7 @@ class InvoiceTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -150,7 +150,7 @@ class InvoiceTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -159,7 +159,7 @@ class InvoiceTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -175,16 +175,16 @@ class InvoiceTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -215,7 +215,7 @@ class InvoiceTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -225,7 +225,7 @@ class InvoiceTest {
.build()
)
)
- .quantity(42.23)
+ .quantity(1.0)
.startDate(OffsetDateTime.parse("2022-02-01T08:00:00+00:00"))
.subLineItems(
listOf(
@@ -248,7 +248,7 @@ class InvoiceTest {
.build()
)
.name("Tier One")
- .quantity(42.23)
+ .quantity(5.0)
.type(
Invoice.LineItem.SubLineItem.MatrixSubLineItem.Type
.MATRIX
@@ -328,7 +328,7 @@ class InvoiceTest {
Invoice.AutoCollection.builder()
.enabled(true)
.nextAttemptAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .numAttempts(123L)
+ .numAttempts(0L)
.previouslyAttemptedAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -400,7 +400,7 @@ class InvoiceTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -428,7 +428,7 @@ class InvoiceTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -459,7 +459,7 @@ class InvoiceTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -467,7 +467,7 @@ class InvoiceTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -483,16 +483,16 @@ class InvoiceTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -517,7 +517,7 @@ class InvoiceTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -527,7 +527,7 @@ class InvoiceTest {
.build()
)
)
- .quantity(42.23)
+ .quantity(1.0)
.startDate(OffsetDateTime.parse("2022-02-01T08:00:00+00:00"))
.subLineItems(
listOf(
@@ -548,7 +548,7 @@ class InvoiceTest {
.build()
)
.name("Tier One")
- .quantity(42.23)
+ .quantity(5.0)
.type(
Invoice.LineItem.SubLineItem.MatrixSubLineItem.Type.MATRIX
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/ItemListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/ItemListParamsTest.kt
index d5cd9b81..0fd057ec 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/ItemListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/ItemListParamsTest.kt
@@ -11,15 +11,15 @@ class ItemListParamsTest {
@Test
fun createItemListParams() {
- ItemListParams.builder().cursor("cursor").limit(123L).build()
+ ItemListParams.builder().cursor("cursor").limit(1L).build()
}
@Test
fun getQueryParams() {
- val params = ItemListParams.builder().cursor("cursor").limit(123L).build()
+ val params = ItemListParams.builder().cursor("cursor").limit(1L).build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/MetricListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/MetricListParamsTest.kt
index 4fc11ae6..f546decf 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/MetricListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/MetricListParamsTest.kt
@@ -18,7 +18,7 @@ class MetricListParamsTest {
.createdAtLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAtLte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
}
@@ -31,7 +31,7 @@ class MetricListParamsTest {
.createdAtLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAtLte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.build()
val expected = QueryParams.builder()
expected.put("created_at[gt]", "2019-12-27T18:11:19.117Z")
@@ -39,7 +39,7 @@ class MetricListParamsTest {
expected.put("created_at[lt]", "2019-12-27T18:11:19.117Z")
expected.put("created_at[lte]", "2019-12-27T18:11:19.117Z")
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/PercentageDiscountTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/PercentageDiscountTest.kt
index a5b73edd..fe691fd0 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/PercentageDiscountTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/PercentageDiscountTest.kt
@@ -13,14 +13,14 @@ class PercentageDiscountTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
assertThat(percentageDiscount).isNotNull
assertThat(percentageDiscount.appliesToPriceIds()).containsExactly("string")
assertThat(percentageDiscount.discountType())
.isEqualTo(PercentageDiscount.DiscountType.PERCENTAGE)
- assertThat(percentageDiscount.percentageDiscount()).isEqualTo(1.0)
+ assertThat(percentageDiscount.percentageDiscount()).isEqualTo(0.15)
assertThat(percentageDiscount.reason()).contains("reason")
}
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanCreateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanCreateParamsTest.kt
index 85ec8267..5fd6fb97 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanCreateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanCreateParamsTest.kt
@@ -31,7 +31,7 @@ class PlanCreateParamsTest {
.billingCycleConfiguration(
PlanCreateParams.Price.NewPlanUnitPrice.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PlanCreateParams.Price.NewPlanUnitPrice
.BillingCycleConfiguration
@@ -40,15 +40,15 @@ class PlanCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
PlanCreateParams.Price.NewPlanUnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PlanCreateParams.Price.NewPlanUnitPrice
.InvoicingCycleConfiguration
@@ -67,7 +67,7 @@ class PlanCreateParamsTest {
.defaultInvoiceMemo("default_invoice_memo")
.externalPlanId("external_plan_id")
.metadata(PlanCreateParams.Metadata.builder().build())
- .netTerms(123L)
+ .netTerms(0L)
.status(PlanCreateParams.Status.ACTIVE)
.build()
}
@@ -97,7 +97,7 @@ class PlanCreateParamsTest {
PlanCreateParams.Price.NewPlanUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PlanCreateParams.Price.NewPlanUnitPrice
.BillingCycleConfiguration
@@ -106,16 +106,16 @@ class PlanCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
PlanCreateParams.Price.NewPlanUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PlanCreateParams.Price.NewPlanUnitPrice
.InvoicingCycleConfiguration
@@ -135,7 +135,7 @@ class PlanCreateParamsTest {
.defaultInvoiceMemo("default_invoice_memo")
.externalPlanId("external_plan_id")
.metadata(PlanCreateParams.Metadata.builder().build())
- .netTerms(123L)
+ .netTerms(0L)
.status(PlanCreateParams.Status.ACTIVE)
.build()
val body = params.getBody()
@@ -161,7 +161,7 @@ class PlanCreateParamsTest {
.billingCycleConfiguration(
PlanCreateParams.Price.NewPlanUnitPrice.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PlanCreateParams.Price.NewPlanUnitPrice
.BillingCycleConfiguration
@@ -170,15 +170,15 @@ class PlanCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
PlanCreateParams.Price.NewPlanUnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PlanCreateParams.Price.NewPlanUnitPrice
.InvoicingCycleConfiguration
@@ -197,7 +197,7 @@ class PlanCreateParamsTest {
assertThat(body.defaultInvoiceMemo()).isEqualTo("default_invoice_memo")
assertThat(body.externalPlanId()).isEqualTo("external_plan_id")
assertThat(body.metadata()).isEqualTo(PlanCreateParams.Metadata.builder().build())
- assertThat(body.netTerms()).isEqualTo(123L)
+ assertThat(body.netTerms()).isEqualTo(0L)
assertThat(body.status()).isEqualTo(PlanCreateParams.Status.ACTIVE)
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanListParamsTest.kt
index af8d6983..1f451e4e 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanListParamsTest.kt
@@ -18,7 +18,7 @@ class PlanListParamsTest {
.createdAtLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAtLte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.status(PlanListParams.Status.ACTIVE)
.build()
}
@@ -32,7 +32,7 @@ class PlanListParamsTest {
.createdAtLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.createdAtLte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.status(PlanListParams.Status.ACTIVE)
.build()
val expected = QueryParams.builder()
@@ -41,7 +41,7 @@ class PlanListParamsTest {
expected.put("created_at[lt]", "2019-12-27T18:11:19.117Z")
expected.put("created_at[lte]", "2019-12-27T18:11:19.117Z")
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("status", PlanListParams.Status.ACTIVE.toString())
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanTest.kt
index e5726286..a60385ea 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/PlanTest.kt
@@ -30,7 +30,7 @@ class PlanTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -53,7 +53,7 @@ class PlanTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -64,12 +64,12 @@ class PlanTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -86,7 +86,7 @@ class PlanTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -100,7 +100,7 @@ class PlanTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -108,7 +108,7 @@ class PlanTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -124,16 +124,16 @@ class PlanTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -158,7 +158,7 @@ class PlanTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -179,11 +179,11 @@ class PlanTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
assertThat(plan).isNotNull
assertThat(plan.id()).isEqualTo("id")
@@ -206,7 +206,7 @@ class PlanTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -231,7 +231,7 @@ class PlanTest {
)
assertThat(plan.minimumAmount()).contains("minimum_amount")
assertThat(plan.name()).isEqualTo("name")
- assertThat(plan.netTerms()).contains(123L)
+ assertThat(plan.netTerms()).contains(0L)
assertThat(plan.planPhases().get())
.containsExactly(
Plan.PlanPhase.builder()
@@ -242,12 +242,12 @@ class PlanTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -264,7 +264,7 @@ class PlanTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
assertThat(plan.prices())
@@ -275,14 +275,14 @@ class PlanTest {
.billableMetric(Price.UnitPrice.BillableMetric.builder().id("id").build())
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit.DAY
)
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -296,16 +296,16 @@ class PlanTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit.DAY
)
@@ -329,7 +329,7 @@ class PlanTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder().unitAmount("unit_amount").build()
@@ -349,10 +349,10 @@ class PlanTest {
assertThat(plan.trialConfig())
.isEqualTo(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- assertThat(plan.version()).isEqualTo(123L)
+ assertThat(plan.version()).isEqualTo(0L)
}
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceCreateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceCreateParamsTest.kt
index 8e58fbea..022caaed 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceCreateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceCreateParamsTest.kt
@@ -26,7 +26,7 @@ class PriceCreateParamsTest {
.billedInAdvance(true)
.billingCycleConfiguration(
PriceCreateParams.NewFloatingUnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PriceCreateParams.NewFloatingUnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -34,13 +34,13 @@ class PriceCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
PriceCreateParams.NewFloatingUnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PriceCreateParams.NewFloatingUnitPrice.InvoicingCycleConfiguration
.DurationUnit
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceEvaluateResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceEvaluateResponseTest.kt
index 61ebc205..ed00ca9f 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceEvaluateResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceEvaluateResponseTest.kt
@@ -18,7 +18,7 @@ class PriceEvaluateResponseTest {
.groupingValues(
listOf(EvaluatePriceGroup.GroupingValue.ofString("string"))
)
- .quantity(42.23)
+ .quantity(0.0)
.build()
)
)
@@ -29,7 +29,7 @@ class PriceEvaluateResponseTest {
EvaluatePriceGroup.builder()
.amount("amount")
.groupingValues(listOf(EvaluatePriceGroup.GroupingValue.ofString("string")))
- .quantity(42.23)
+ .quantity(0.0)
.build()
)
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceListParamsTest.kt
index 81abe351..4156f950 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/PriceListParamsTest.kt
@@ -11,15 +11,15 @@ class PriceListParamsTest {
@Test
fun createPriceListParams() {
- PriceListParams.builder().cursor("cursor").limit(123L).build()
+ PriceListParams.builder().cursor("cursor").limit(1L).build()
}
@Test
fun getQueryParams() {
- val params = PriceListParams.builder().cursor("cursor").limit(123L).build()
+ val params = PriceListParams.builder().cursor("cursor").limit(1L).build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCancelResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCancelResponseTest.kt
index 342717de..484c225a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCancelResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCancelResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionCancelResponseTest {
val subscriptionCancelResponse =
SubscriptionCancelResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionCancelResponse.AdjustmentInterval.builder()
@@ -46,12 +46,12 @@ class SubscriptionCancelResponseTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
SubscriptionCancelResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -151,7 +151,7 @@ class SubscriptionCancelResponseTest {
SubscriptionCancelResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -180,7 +180,7 @@ class SubscriptionCancelResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -201,7 +201,7 @@ class SubscriptionCancelResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -224,7 +224,7 @@ class SubscriptionCancelResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -237,12 +237,12 @@ class SubscriptionCancelResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -259,7 +259,7 @@ class SubscriptionCancelResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -275,7 +275,7 @@ class SubscriptionCancelResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -284,7 +284,7 @@ class SubscriptionCancelResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -300,16 +300,16 @@ class SubscriptionCancelResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -340,7 +340,7 @@ class SubscriptionCancelResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -361,18 +361,18 @@ class SubscriptionCancelResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionCancelResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -389,7 +389,7 @@ class SubscriptionCancelResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -404,7 +404,7 @@ class SubscriptionCancelResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -413,7 +413,7 @@ class SubscriptionCancelResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -429,16 +429,16 @@ class SubscriptionCancelResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -469,7 +469,7 @@ class SubscriptionCancelResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -500,7 +500,7 @@ class SubscriptionCancelResponseTest {
.build()
assertThat(subscriptionCancelResponse).isNotNull
assertThat(subscriptionCancelResponse.id()).isEqualTo("id")
- assertThat(subscriptionCancelResponse.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscriptionCancelResponse.activePlanPhaseOrder()).contains(0L)
assertThat(subscriptionCancelResponse.adjustmentIntervals())
.containsExactly(
SubscriptionCancelResponse.AdjustmentInterval.builder()
@@ -532,12 +532,12 @@ class SubscriptionCancelResponseTest {
assertThat(subscriptionCancelResponse.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionCancelResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionCancelResponse.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscriptionCancelResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionCancelResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionCancelResponse.currentBillingPeriodEndDate())
@@ -638,7 +638,7 @@ class SubscriptionCancelResponseTest {
SubscriptionCancelResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -665,7 +665,7 @@ class SubscriptionCancelResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionCancelResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionCancelResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionCancelResponse.plan())
.isEqualTo(
Plan.builder()
@@ -687,7 +687,7 @@ class SubscriptionCancelResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -710,7 +710,7 @@ class SubscriptionCancelResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -723,12 +723,12 @@ class SubscriptionCancelResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -745,7 +745,7 @@ class SubscriptionCancelResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -759,7 +759,7 @@ class SubscriptionCancelResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -768,7 +768,7 @@ class SubscriptionCancelResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -784,16 +784,16 @@ class SubscriptionCancelResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -821,7 +821,7 @@ class SubscriptionCancelResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -842,18 +842,18 @@ class SubscriptionCancelResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionCancelResponse.priceIntervals())
.containsExactly(
SubscriptionCancelResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -863,7 +863,7 @@ class SubscriptionCancelResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -876,7 +876,7 @@ class SubscriptionCancelResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -884,7 +884,7 @@ class SubscriptionCancelResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -900,16 +900,16 @@ class SubscriptionCancelResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -934,7 +934,7 @@ class SubscriptionCancelResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCreateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCreateParamsTest.kt
index 7ca31afe..5ff8ed1e 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCreateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCreateParamsTest.kt
@@ -29,12 +29,12 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -50,8 +50,8 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
@@ -59,7 +59,7 @@ class SubscriptionCreateParamsTest {
.externalPriceId("external_price_id")
.maximumAmount("1.23")
.minimumAmount("1.23")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.price(
SubscriptionCreateParams.AddPrice.Price.ofNewSubscriptionUnitPrice(
SubscriptionCreateParams.AddPrice.Price.NewSubscriptionUnitPrice
@@ -93,7 +93,7 @@ class SubscriptionCreateParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
@@ -103,17 +103,17 @@ class SubscriptionCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
@@ -144,13 +144,13 @@ class SubscriptionCreateParamsTest {
.awsRegion("aws_region")
.billingCycleAnchorConfiguration(
SubscriptionCreateParams.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
.couponRedemptionCode("coupon_redemption_code")
- .creditsOverageRate(42.23)
+ .creditsOverageRate(0.0)
.customerId("customer_id")
.defaultInvoiceMemo("default_invoice_memo")
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -158,13 +158,14 @@ class SubscriptionCreateParamsTest {
.externalMarketplace(SubscriptionCreateParams.ExternalMarketplace.GOOGLE)
.externalMarketplaceReportingId("external_marketplace_reporting_id")
.externalPlanId("ZMwNQefe7J3ecf7W")
- .initialPhaseOrder(123L)
+ .filter("my_property > 100 AND my_other_property = 'bar'")
+ .initialPhaseOrder(2L)
.invoicingThreshold("10.00")
.metadata(SubscriptionCreateParams.Metadata.builder().build())
- .netTerms(123L)
- .perCreditOverageAmount(42.23)
+ .netTerms(0L)
+ .perCreditOverageAmount(0.0)
.planId("ZMwNQefe7J3ecf7W")
- .planVersionNumber(123L)
+ .planVersionNumber(0L)
.priceOverrides(listOf(JsonValue.from(mapOf())))
.removeAdjustments(
listOf(
@@ -197,7 +198,7 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -217,13 +218,13 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(2.0)
.maximumAmount("1.23")
.minimumAmount("1.23")
.price(
@@ -259,7 +260,7 @@ class SubscriptionCreateParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
@@ -269,17 +270,17 @@ class SubscriptionCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
@@ -305,7 +306,7 @@ class SubscriptionCreateParamsTest {
)
)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .trialDurationDays(123L)
+ .trialDurationDays(0L)
.build()
}
@@ -329,12 +330,12 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -350,8 +351,8 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
@@ -359,7 +360,7 @@ class SubscriptionCreateParamsTest {
.externalPriceId("external_price_id")
.maximumAmount("1.23")
.minimumAmount("1.23")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.price(
SubscriptionCreateParams.AddPrice.Price.ofNewSubscriptionUnitPrice(
SubscriptionCreateParams.AddPrice.Price.NewSubscriptionUnitPrice
@@ -393,7 +394,7 @@ class SubscriptionCreateParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
@@ -403,17 +404,17 @@ class SubscriptionCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
@@ -444,13 +445,13 @@ class SubscriptionCreateParamsTest {
.awsRegion("aws_region")
.billingCycleAnchorConfiguration(
SubscriptionCreateParams.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
.couponRedemptionCode("coupon_redemption_code")
- .creditsOverageRate(42.23)
+ .creditsOverageRate(0.0)
.customerId("customer_id")
.defaultInvoiceMemo("default_invoice_memo")
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -458,13 +459,14 @@ class SubscriptionCreateParamsTest {
.externalMarketplace(SubscriptionCreateParams.ExternalMarketplace.GOOGLE)
.externalMarketplaceReportingId("external_marketplace_reporting_id")
.externalPlanId("ZMwNQefe7J3ecf7W")
- .initialPhaseOrder(123L)
+ .filter("my_property > 100 AND my_other_property = 'bar'")
+ .initialPhaseOrder(2L)
.invoicingThreshold("10.00")
.metadata(SubscriptionCreateParams.Metadata.builder().build())
- .netTerms(123L)
- .perCreditOverageAmount(42.23)
+ .netTerms(0L)
+ .perCreditOverageAmount(0.0)
.planId("ZMwNQefe7J3ecf7W")
- .planVersionNumber(123L)
+ .planVersionNumber(0L)
.priceOverrides(listOf(JsonValue.from(mapOf())))
.removeAdjustments(
listOf(
@@ -498,7 +500,7 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -519,13 +521,13 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(2.0)
.maximumAmount("1.23")
.minimumAmount("1.23")
.price(
@@ -563,7 +565,7 @@ class SubscriptionCreateParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
@@ -573,17 +575,17 @@ class SubscriptionCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
@@ -609,7 +611,7 @@ class SubscriptionCreateParamsTest {
)
)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .trialDurationDays(123L)
+ .trialDurationDays(0L)
.build()
val body = params.getBody()
assertThat(body).isNotNull
@@ -630,12 +632,12 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -652,8 +654,8 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
@@ -661,7 +663,7 @@ class SubscriptionCreateParamsTest {
.externalPriceId("external_price_id")
.maximumAmount("1.23")
.minimumAmount("1.23")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.price(
SubscriptionCreateParams.AddPrice.Price.ofNewSubscriptionUnitPrice(
SubscriptionCreateParams.AddPrice.Price.NewSubscriptionUnitPrice
@@ -695,7 +697,7 @@ class SubscriptionCreateParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
@@ -705,17 +707,17 @@ class SubscriptionCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
@@ -747,13 +749,13 @@ class SubscriptionCreateParamsTest {
assertThat(body.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionCreateParams.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
assertThat(body.couponRedemptionCode()).isEqualTo("coupon_redemption_code")
- assertThat(body.creditsOverageRate()).isEqualTo(42.23)
+ assertThat(body.creditsOverageRate()).isEqualTo(0.0)
assertThat(body.customerId()).isEqualTo("customer_id")
assertThat(body.defaultInvoiceMemo()).isEqualTo("default_invoice_memo")
assertThat(body.endDate()).isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -763,13 +765,14 @@ class SubscriptionCreateParamsTest {
assertThat(body.externalMarketplaceReportingId())
.isEqualTo("external_marketplace_reporting_id")
assertThat(body.externalPlanId()).isEqualTo("ZMwNQefe7J3ecf7W")
- assertThat(body.initialPhaseOrder()).isEqualTo(123L)
+ assertThat(body.filter()).isEqualTo("my_property > 100 AND my_other_property = 'bar'")
+ assertThat(body.initialPhaseOrder()).isEqualTo(2L)
assertThat(body.invoicingThreshold()).isEqualTo("10.00")
assertThat(body.metadata()).isEqualTo(SubscriptionCreateParams.Metadata.builder().build())
- assertThat(body.netTerms()).isEqualTo(123L)
- assertThat(body.perCreditOverageAmount()).isEqualTo(42.23)
+ assertThat(body.netTerms()).isEqualTo(0L)
+ assertThat(body.perCreditOverageAmount()).isEqualTo(0.0)
assertThat(body.planId()).isEqualTo("ZMwNQefe7J3ecf7W")
- assertThat(body.planVersionNumber()).isEqualTo(123L)
+ assertThat(body.planVersionNumber()).isEqualTo(0L)
assertThat(body.priceOverrides()).isEqualTo(listOf(JsonValue.from(mapOf())))
assertThat(body.removeAdjustments())
.isEqualTo(
@@ -805,7 +808,7 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -826,13 +829,13 @@ class SubscriptionCreateParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(2.0)
.maximumAmount("1.23")
.minimumAmount("1.23")
.price(
@@ -868,7 +871,7 @@ class SubscriptionCreateParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
@@ -878,17 +881,17 @@ class SubscriptionCreateParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
@@ -914,7 +917,7 @@ class SubscriptionCreateParamsTest {
)
)
assertThat(body.startDate()).isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- assertThat(body.trialDurationDays()).isEqualTo(123L)
+ assertThat(body.trialDurationDays()).isEqualTo(0L)
}
@Test
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCreateResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCreateResponseTest.kt
index 25cceb4c..c681c7b1 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCreateResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionCreateResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionCreateResponseTest {
val subscriptionCreateResponse =
SubscriptionCreateResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionCreateResponse.AdjustmentInterval.builder()
@@ -46,12 +46,12 @@ class SubscriptionCreateResponseTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
SubscriptionCreateResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -151,7 +151,7 @@ class SubscriptionCreateResponseTest {
SubscriptionCreateResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -180,7 +180,7 @@ class SubscriptionCreateResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -201,7 +201,7 @@ class SubscriptionCreateResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -224,7 +224,7 @@ class SubscriptionCreateResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -237,12 +237,12 @@ class SubscriptionCreateResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -259,7 +259,7 @@ class SubscriptionCreateResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -275,7 +275,7 @@ class SubscriptionCreateResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -284,7 +284,7 @@ class SubscriptionCreateResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -300,16 +300,16 @@ class SubscriptionCreateResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -340,7 +340,7 @@ class SubscriptionCreateResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -361,18 +361,18 @@ class SubscriptionCreateResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionCreateResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -389,7 +389,7 @@ class SubscriptionCreateResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -404,7 +404,7 @@ class SubscriptionCreateResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -413,7 +413,7 @@ class SubscriptionCreateResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -429,16 +429,16 @@ class SubscriptionCreateResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -469,7 +469,7 @@ class SubscriptionCreateResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -500,7 +500,7 @@ class SubscriptionCreateResponseTest {
.build()
assertThat(subscriptionCreateResponse).isNotNull
assertThat(subscriptionCreateResponse.id()).isEqualTo("id")
- assertThat(subscriptionCreateResponse.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscriptionCreateResponse.activePlanPhaseOrder()).contains(0L)
assertThat(subscriptionCreateResponse.adjustmentIntervals())
.containsExactly(
SubscriptionCreateResponse.AdjustmentInterval.builder()
@@ -532,12 +532,12 @@ class SubscriptionCreateResponseTest {
assertThat(subscriptionCreateResponse.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionCreateResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionCreateResponse.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscriptionCreateResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionCreateResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionCreateResponse.currentBillingPeriodEndDate())
@@ -638,7 +638,7 @@ class SubscriptionCreateResponseTest {
SubscriptionCreateResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -665,7 +665,7 @@ class SubscriptionCreateResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionCreateResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionCreateResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionCreateResponse.plan())
.isEqualTo(
Plan.builder()
@@ -687,7 +687,7 @@ class SubscriptionCreateResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -710,7 +710,7 @@ class SubscriptionCreateResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -723,12 +723,12 @@ class SubscriptionCreateResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -745,7 +745,7 @@ class SubscriptionCreateResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -759,7 +759,7 @@ class SubscriptionCreateResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -768,7 +768,7 @@ class SubscriptionCreateResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -784,16 +784,16 @@ class SubscriptionCreateResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -821,7 +821,7 @@ class SubscriptionCreateResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -842,18 +842,18 @@ class SubscriptionCreateResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionCreateResponse.priceIntervals())
.containsExactly(
SubscriptionCreateResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -863,7 +863,7 @@ class SubscriptionCreateResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -876,7 +876,7 @@ class SubscriptionCreateResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -884,7 +884,7 @@ class SubscriptionCreateResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -900,16 +900,16 @@ class SubscriptionCreateResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -934,7 +934,7 @@ class SubscriptionCreateResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionFetchCostsResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionFetchCostsResponseTest.kt
index 2f620c8c..985b2f92 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionFetchCostsResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionFetchCostsResponseTest.kt
@@ -30,7 +30,7 @@ class SubscriptionFetchCostsResponseTest {
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.BillingCycleConfiguration
@@ -40,7 +40,7 @@ class SubscriptionFetchCostsResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse(
"2019-12-27T18:11:19.117Z"
@@ -61,17 +61,17 @@ class SubscriptionFetchCostsResponseTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.InvoicingCycleConfiguration
@@ -105,7 +105,7 @@ class SubscriptionFetchCostsResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(
Price.UnitPrice.PriceType.USAGE_PRICE
)
@@ -119,7 +119,7 @@ class SubscriptionFetchCostsResponseTest {
)
.subtotal("subtotal")
.total("total")
- .quantity(42.23)
+ .quantity(0.0)
.build()
)
)
@@ -149,7 +149,7 @@ class SubscriptionFetchCostsResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -158,7 +158,7 @@ class SubscriptionFetchCostsResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -177,17 +177,17 @@ class SubscriptionFetchCostsResponseTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -218,7 +218,7 @@ class SubscriptionFetchCostsResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -230,7 +230,7 @@ class SubscriptionFetchCostsResponseTest {
)
.subtotal("subtotal")
.total("total")
- .quantity(42.23)
+ .quantity(0.0)
.build()
)
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionFetchScheduleParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionFetchScheduleParamsTest.kt
index 98eb7bec..79697c98 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionFetchScheduleParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionFetchScheduleParamsTest.kt
@@ -15,7 +15,7 @@ class SubscriptionFetchScheduleParamsTest {
SubscriptionFetchScheduleParams.builder()
.subscriptionId("subscription_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.startDateGt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.startDateGte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.startDateLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -29,7 +29,7 @@ class SubscriptionFetchScheduleParamsTest {
SubscriptionFetchScheduleParams.builder()
.subscriptionId("subscription_id")
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.startDateGt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.startDateGte(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.startDateLt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -37,7 +37,7 @@ class SubscriptionFetchScheduleParamsTest {
.build()
val expected = QueryParams.builder()
expected.put("cursor", "cursor")
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("start_date[gt]", "2019-12-27T18:11:19.117Z")
expected.put("start_date[gte]", "2019-12-27T18:11:19.117Z")
expected.put("start_date[lt]", "2019-12-27T18:11:19.117Z")
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionListParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionListParamsTest.kt
index f82e2197..db57d65e 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionListParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionListParamsTest.kt
@@ -20,7 +20,7 @@ class SubscriptionListParamsTest {
.cursor("cursor")
.customerId(listOf("string"))
.externalCustomerId("external_customer_id")
- .limit(123L)
+ .limit(1L)
.status(SubscriptionListParams.Status.ACTIVE)
.build()
}
@@ -36,7 +36,7 @@ class SubscriptionListParamsTest {
.cursor("cursor")
.customerId(listOf("string"))
.externalCustomerId("external_customer_id")
- .limit(123L)
+ .limit(1L)
.status(SubscriptionListParams.Status.ACTIVE)
.build()
val expected = QueryParams.builder()
@@ -47,7 +47,7 @@ class SubscriptionListParamsTest {
expected.put("cursor", "cursor")
expected.put("customer_id[]", "string")
expected.put("external_customer_id", "external_customer_id")
- expected.put("limit", "123")
+ expected.put("limit", "1")
expected.put("status", SubscriptionListParams.Status.ACTIVE.toString())
assertThat(params.getQueryParams()).isEqualTo(expected.build())
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionPriceIntervalsParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionPriceIntervalsParamsTest.kt
index 69f95ab2..f842d3f9 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionPriceIntervalsParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionPriceIntervalsParamsTest.kt
@@ -39,7 +39,7 @@ class SubscriptionPriceIntervalsParamsTest {
SubscriptionPriceIntervalsParams.Add.Discount
.AmountDiscountCreationParams
.builder()
- .amountDiscount(42.23)
+ .amountDiscount(0.0)
.discountType(
SubscriptionPriceIntervalsParams.Add.Discount
.AmountDiscountCreationParams
@@ -61,12 +61,12 @@ class SubscriptionPriceIntervalsParamsTest {
SubscriptionPriceIntervalsParams.Add.FixedFeeQuantityTransition
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .quantity(123L)
+ .quantity(5L)
.build()
)
)
- .maximumAmount(42.23)
- .minimumAmount(42.23)
+ .maximumAmount(0.0)
+ .minimumAmount(0.0)
.price(
SubscriptionPriceIntervalsParams.Add.Price.ofNewFloatingUnitPrice(
SubscriptionPriceIntervalsParams.Add.Price.NewFloatingUnitPrice
@@ -101,7 +101,7 @@ class SubscriptionPriceIntervalsParamsTest {
.NewFloatingUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
@@ -111,16 +111,16 @@ class SubscriptionPriceIntervalsParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
@@ -161,7 +161,7 @@ class SubscriptionPriceIntervalsParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -182,7 +182,7 @@ class SubscriptionPriceIntervalsParamsTest {
listOf(
SubscriptionPriceIntervalsParams.Edit.builder()
.priceIntervalId("sdfs6wdjvn7ujokd")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.endDate(
SubscriptionPriceIntervalsParams.Edit.EndDate.ofDateTime(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
@@ -193,7 +193,7 @@ class SubscriptionPriceIntervalsParamsTest {
SubscriptionPriceIntervalsParams.Edit.FixedFeeQuantityTransition
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .quantity(123L)
+ .quantity(5L)
.build()
)
)
@@ -256,7 +256,7 @@ class SubscriptionPriceIntervalsParamsTest {
SubscriptionPriceIntervalsParams.Add.Discount
.AmountDiscountCreationParams
.builder()
- .amountDiscount(42.23)
+ .amountDiscount(0.0)
.discountType(
SubscriptionPriceIntervalsParams.Add.Discount
.AmountDiscountCreationParams
@@ -280,12 +280,12 @@ class SubscriptionPriceIntervalsParamsTest {
.effectiveDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
- .quantity(123L)
+ .quantity(5L)
.build()
)
)
- .maximumAmount(42.23)
- .minimumAmount(42.23)
+ .maximumAmount(0.0)
+ .minimumAmount(0.0)
.price(
SubscriptionPriceIntervalsParams.Add.Price.ofNewFloatingUnitPrice(
SubscriptionPriceIntervalsParams.Add.Price.NewFloatingUnitPrice
@@ -320,7 +320,7 @@ class SubscriptionPriceIntervalsParamsTest {
.NewFloatingUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
@@ -330,16 +330,16 @@ class SubscriptionPriceIntervalsParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
@@ -380,7 +380,7 @@ class SubscriptionPriceIntervalsParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -401,7 +401,7 @@ class SubscriptionPriceIntervalsParamsTest {
listOf(
SubscriptionPriceIntervalsParams.Edit.builder()
.priceIntervalId("sdfs6wdjvn7ujokd")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.endDate(
SubscriptionPriceIntervalsParams.Edit.EndDate.ofDateTime(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
@@ -414,7 +414,7 @@ class SubscriptionPriceIntervalsParamsTest {
.effectiveDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
- .quantity(123L)
+ .quantity(5L)
.build()
)
)
@@ -472,7 +472,7 @@ class SubscriptionPriceIntervalsParamsTest {
SubscriptionPriceIntervalsParams.Add.Discount
.AmountDiscountCreationParams
.builder()
- .amountDiscount(42.23)
+ .amountDiscount(0.0)
.discountType(
SubscriptionPriceIntervalsParams.Add.Discount
.AmountDiscountCreationParams
@@ -494,12 +494,12 @@ class SubscriptionPriceIntervalsParamsTest {
SubscriptionPriceIntervalsParams.Add.FixedFeeQuantityTransition
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .quantity(123L)
+ .quantity(5L)
.build()
)
)
- .maximumAmount(42.23)
- .minimumAmount(42.23)
+ .maximumAmount(0.0)
+ .minimumAmount(0.0)
.price(
SubscriptionPriceIntervalsParams.Add.Price.ofNewFloatingUnitPrice(
SubscriptionPriceIntervalsParams.Add.Price.NewFloatingUnitPrice
@@ -534,7 +534,7 @@ class SubscriptionPriceIntervalsParamsTest {
.NewFloatingUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
@@ -544,16 +544,16 @@ class SubscriptionPriceIntervalsParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
@@ -595,7 +595,7 @@ class SubscriptionPriceIntervalsParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -617,7 +617,7 @@ class SubscriptionPriceIntervalsParamsTest {
listOf(
SubscriptionPriceIntervalsParams.Edit.builder()
.priceIntervalId("sdfs6wdjvn7ujokd")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.endDate(
SubscriptionPriceIntervalsParams.Edit.EndDate.ofDateTime(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
@@ -628,7 +628,7 @@ class SubscriptionPriceIntervalsParamsTest {
SubscriptionPriceIntervalsParams.Edit.FixedFeeQuantityTransition
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .quantity(123L)
+ .quantity(5L)
.build()
)
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionPriceIntervalsResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionPriceIntervalsResponseTest.kt
index 07a97c28..aff34cfe 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionPriceIntervalsResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionPriceIntervalsResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionPriceIntervalsResponseTest {
val subscriptionPriceIntervalsResponse =
SubscriptionPriceIntervalsResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionPriceIntervalsResponse.AdjustmentInterval.builder()
@@ -48,12 +48,12 @@ class SubscriptionPriceIntervalsResponseTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
SubscriptionPriceIntervalsResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -155,7 +155,7 @@ class SubscriptionPriceIntervalsResponseTest {
SubscriptionPriceIntervalsResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -184,7 +184,7 @@ class SubscriptionPriceIntervalsResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -205,7 +205,7 @@ class SubscriptionPriceIntervalsResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -228,7 +228,7 @@ class SubscriptionPriceIntervalsResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -241,12 +241,12 @@ class SubscriptionPriceIntervalsResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -263,7 +263,7 @@ class SubscriptionPriceIntervalsResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -279,7 +279,7 @@ class SubscriptionPriceIntervalsResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -288,7 +288,7 @@ class SubscriptionPriceIntervalsResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -304,16 +304,16 @@ class SubscriptionPriceIntervalsResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -344,7 +344,7 @@ class SubscriptionPriceIntervalsResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -365,18 +365,18 @@ class SubscriptionPriceIntervalsResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionPriceIntervalsResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -393,7 +393,7 @@ class SubscriptionPriceIntervalsResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -408,7 +408,7 @@ class SubscriptionPriceIntervalsResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -417,7 +417,7 @@ class SubscriptionPriceIntervalsResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -433,16 +433,16 @@ class SubscriptionPriceIntervalsResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -473,7 +473,7 @@ class SubscriptionPriceIntervalsResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -504,7 +504,7 @@ class SubscriptionPriceIntervalsResponseTest {
.build()
assertThat(subscriptionPriceIntervalsResponse).isNotNull
assertThat(subscriptionPriceIntervalsResponse.id()).isEqualTo("id")
- assertThat(subscriptionPriceIntervalsResponse.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscriptionPriceIntervalsResponse.activePlanPhaseOrder()).contains(0L)
assertThat(subscriptionPriceIntervalsResponse.adjustmentIntervals())
.containsExactly(
SubscriptionPriceIntervalsResponse.AdjustmentInterval.builder()
@@ -537,12 +537,12 @@ class SubscriptionPriceIntervalsResponseTest {
assertThat(subscriptionPriceIntervalsResponse.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionPriceIntervalsResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionPriceIntervalsResponse.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscriptionPriceIntervalsResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionPriceIntervalsResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionPriceIntervalsResponse.currentBillingPeriodEndDate())
@@ -646,7 +646,7 @@ class SubscriptionPriceIntervalsResponseTest {
SubscriptionPriceIntervalsResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -674,7 +674,7 @@ class SubscriptionPriceIntervalsResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionPriceIntervalsResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionPriceIntervalsResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionPriceIntervalsResponse.plan())
.isEqualTo(
Plan.builder()
@@ -696,7 +696,7 @@ class SubscriptionPriceIntervalsResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -719,7 +719,7 @@ class SubscriptionPriceIntervalsResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -732,12 +732,12 @@ class SubscriptionPriceIntervalsResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -754,7 +754,7 @@ class SubscriptionPriceIntervalsResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -768,7 +768,7 @@ class SubscriptionPriceIntervalsResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -777,7 +777,7 @@ class SubscriptionPriceIntervalsResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -793,16 +793,16 @@ class SubscriptionPriceIntervalsResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -830,7 +830,7 @@ class SubscriptionPriceIntervalsResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -851,18 +851,18 @@ class SubscriptionPriceIntervalsResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionPriceIntervalsResponse.priceIntervals())
.containsExactly(
SubscriptionPriceIntervalsResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -873,7 +873,7 @@ class SubscriptionPriceIntervalsResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -886,7 +886,7 @@ class SubscriptionPriceIntervalsResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -894,7 +894,7 @@ class SubscriptionPriceIntervalsResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -910,16 +910,16 @@ class SubscriptionPriceIntervalsResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -944,7 +944,7 @@ class SubscriptionPriceIntervalsResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeParamsTest.kt
index 0b91aa6d..afb1e0e8 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeParamsTest.kt
@@ -32,12 +32,12 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -54,8 +54,8 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
@@ -63,7 +63,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.externalPriceId("external_price_id")
.maximumAmount("1.23")
.minimumAmount("1.23")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.price(
SubscriptionSchedulePlanChangeParams.AddPrice.Price
.ofNewSubscriptionUnitPrice(
@@ -99,7 +99,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams.AddPrice
.Price
@@ -110,17 +110,17 @@ class SubscriptionSchedulePlanChangeParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionSchedulePlanChangeParams.AddPrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams.AddPrice
.Price
@@ -154,22 +154,23 @@ class SubscriptionSchedulePlanChangeParamsTest {
)
.billingCycleAnchorConfiguration(
SubscriptionSchedulePlanChangeParams.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
.changeDate(OffsetDateTime.parse("2017-07-21T17:32:28Z"))
.couponRedemptionCode("coupon_redemption_code")
- .creditsOverageRate(42.23)
+ .creditsOverageRate(0.0)
.defaultInvoiceMemo("default_invoice_memo")
.externalPlanId("ZMwNQefe7J3ecf7W")
- .initialPhaseOrder(123L)
+ .filter("my_property > 100 AND my_other_property = 'bar'")
+ .initialPhaseOrder(2L)
.invoicingThreshold("10.00")
- .netTerms(123L)
- .perCreditOverageAmount(42.23)
+ .netTerms(0L)
+ .perCreditOverageAmount(0.0)
.planId("ZMwNQefe7J3ecf7W")
- .planVersionNumber(123L)
+ .planVersionNumber(0L)
.priceOverrides(listOf(JsonValue.from(mapOf())))
.removeAdjustments(
listOf(
@@ -204,7 +205,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -225,13 +226,13 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(2.0)
.maximumAmount("1.23")
.minimumAmount("1.23")
.price(
@@ -269,7 +270,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.ReplacePrice
@@ -281,17 +282,17 @@ class SubscriptionSchedulePlanChangeParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionSchedulePlanChangeParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.ReplacePrice
@@ -318,7 +319,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.build()
)
)
- .trialDurationDays(123L)
+ .trialDurationDays(0L)
.build()
}
@@ -346,12 +347,12 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -368,8 +369,8 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
@@ -377,7 +378,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.externalPriceId("external_price_id")
.maximumAmount("1.23")
.minimumAmount("1.23")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.price(
SubscriptionSchedulePlanChangeParams.AddPrice.Price
.ofNewSubscriptionUnitPrice(
@@ -413,7 +414,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.AddPrice
@@ -425,17 +426,17 @@ class SubscriptionSchedulePlanChangeParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionSchedulePlanChangeParams.AddPrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.AddPrice
@@ -470,22 +471,23 @@ class SubscriptionSchedulePlanChangeParamsTest {
)
.billingCycleAnchorConfiguration(
SubscriptionSchedulePlanChangeParams.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
.changeDate(OffsetDateTime.parse("2017-07-21T17:32:28Z"))
.couponRedemptionCode("coupon_redemption_code")
- .creditsOverageRate(42.23)
+ .creditsOverageRate(0.0)
.defaultInvoiceMemo("default_invoice_memo")
.externalPlanId("ZMwNQefe7J3ecf7W")
- .initialPhaseOrder(123L)
+ .filter("my_property > 100 AND my_other_property = 'bar'")
+ .initialPhaseOrder(2L)
.invoicingThreshold("10.00")
- .netTerms(123L)
- .perCreditOverageAmount(42.23)
+ .netTerms(0L)
+ .perCreditOverageAmount(0.0)
.planId("ZMwNQefe7J3ecf7W")
- .planVersionNumber(123L)
+ .planVersionNumber(0L)
.priceOverrides(listOf(JsonValue.from(mapOf())))
.removeAdjustments(
listOf(
@@ -521,7 +523,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -544,13 +546,13 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(2.0)
.maximumAmount("1.23")
.minimumAmount("1.23")
.price(
@@ -592,7 +594,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.ReplacePrice
@@ -604,10 +606,10 @@ class SubscriptionSchedulePlanChangeParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionSchedulePlanChangeParams.ReplacePrice
@@ -615,7 +617,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.ReplacePrice
@@ -643,7 +645,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.build()
)
)
- .trialDurationDays(123L)
+ .trialDurationDays(0L)
.build()
val body = params.getBody()
assertThat(body).isNotNull
@@ -667,12 +669,12 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -690,8 +692,8 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
@@ -699,7 +701,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.externalPriceId("external_price_id")
.maximumAmount("1.23")
.minimumAmount("1.23")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.price(
SubscriptionSchedulePlanChangeParams.AddPrice.Price
.ofNewSubscriptionUnitPrice(
@@ -735,7 +737,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams.AddPrice
.Price
@@ -746,17 +748,17 @@ class SubscriptionSchedulePlanChangeParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionSchedulePlanChangeParams.AddPrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams.AddPrice
.Price
@@ -790,22 +792,23 @@ class SubscriptionSchedulePlanChangeParamsTest {
assertThat(body.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionSchedulePlanChangeParams.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
assertThat(body.changeDate()).isEqualTo(OffsetDateTime.parse("2017-07-21T17:32:28Z"))
assertThat(body.couponRedemptionCode()).isEqualTo("coupon_redemption_code")
- assertThat(body.creditsOverageRate()).isEqualTo(42.23)
+ assertThat(body.creditsOverageRate()).isEqualTo(0.0)
assertThat(body.defaultInvoiceMemo()).isEqualTo("default_invoice_memo")
assertThat(body.externalPlanId()).isEqualTo("ZMwNQefe7J3ecf7W")
- assertThat(body.initialPhaseOrder()).isEqualTo(123L)
+ assertThat(body.filter()).isEqualTo("my_property > 100 AND my_other_property = 'bar'")
+ assertThat(body.initialPhaseOrder()).isEqualTo(2L)
assertThat(body.invoicingThreshold()).isEqualTo("10.00")
- assertThat(body.netTerms()).isEqualTo(123L)
- assertThat(body.perCreditOverageAmount()).isEqualTo(42.23)
+ assertThat(body.netTerms()).isEqualTo(0L)
+ assertThat(body.perCreditOverageAmount()).isEqualTo(0.0)
assertThat(body.planId()).isEqualTo("ZMwNQefe7J3ecf7W")
- assertThat(body.planVersionNumber()).isEqualTo(123L)
+ assertThat(body.planVersionNumber()).isEqualTo(0L)
assertThat(body.priceOverrides()).isEqualTo(listOf(JsonValue.from(mapOf())))
assertThat(body.removeAdjustments())
.isEqualTo(
@@ -843,7 +846,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -865,13 +868,13 @@ class SubscriptionSchedulePlanChangeParamsTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(2.0)
.maximumAmount("1.23")
.minimumAmount("1.23")
.price(
@@ -909,7 +912,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.ReplacePrice
@@ -921,17 +924,17 @@ class SubscriptionSchedulePlanChangeParamsTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionSchedulePlanChangeParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.ReplacePrice
@@ -958,7 +961,7 @@ class SubscriptionSchedulePlanChangeParamsTest {
.build()
)
)
- assertThat(body.trialDurationDays()).isEqualTo(123L)
+ assertThat(body.trialDurationDays()).isEqualTo(0L)
}
@Test
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeResponseTest.kt
index 540b5e1a..74b51ad9 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionSchedulePlanChangeResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
val subscriptionSchedulePlanChangeResponse =
SubscriptionSchedulePlanChangeResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionSchedulePlanChangeResponse.AdjustmentInterval.builder()
@@ -48,12 +48,12 @@ class SubscriptionSchedulePlanChangeResponseTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
SubscriptionSchedulePlanChangeResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -155,7 +155,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
SubscriptionSchedulePlanChangeResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -184,7 +184,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -205,7 +205,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -228,7 +228,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -241,12 +241,12 @@ class SubscriptionSchedulePlanChangeResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -263,7 +263,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -279,7 +279,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -288,7 +288,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -304,16 +304,16 @@ class SubscriptionSchedulePlanChangeResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -344,7 +344,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -365,18 +365,18 @@ class SubscriptionSchedulePlanChangeResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionSchedulePlanChangeResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -393,7 +393,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -408,7 +408,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -417,7 +417,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -433,16 +433,16 @@ class SubscriptionSchedulePlanChangeResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -473,7 +473,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -504,7 +504,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.build()
assertThat(subscriptionSchedulePlanChangeResponse).isNotNull
assertThat(subscriptionSchedulePlanChangeResponse.id()).isEqualTo("id")
- assertThat(subscriptionSchedulePlanChangeResponse.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscriptionSchedulePlanChangeResponse.activePlanPhaseOrder()).contains(0L)
assertThat(subscriptionSchedulePlanChangeResponse.adjustmentIntervals())
.containsExactly(
SubscriptionSchedulePlanChangeResponse.AdjustmentInterval.builder()
@@ -537,12 +537,12 @@ class SubscriptionSchedulePlanChangeResponseTest {
assertThat(subscriptionSchedulePlanChangeResponse.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionSchedulePlanChangeResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionSchedulePlanChangeResponse.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscriptionSchedulePlanChangeResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionSchedulePlanChangeResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionSchedulePlanChangeResponse.currentBillingPeriodEndDate())
@@ -646,7 +646,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
SubscriptionSchedulePlanChangeResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -674,7 +674,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionSchedulePlanChangeResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionSchedulePlanChangeResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionSchedulePlanChangeResponse.plan())
.isEqualTo(
Plan.builder()
@@ -696,7 +696,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -719,7 +719,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -732,12 +732,12 @@ class SubscriptionSchedulePlanChangeResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -754,7 +754,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -768,7 +768,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -777,7 +777,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -793,16 +793,16 @@ class SubscriptionSchedulePlanChangeResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -830,7 +830,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -851,18 +851,18 @@ class SubscriptionSchedulePlanChangeResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionSchedulePlanChangeResponse.priceIntervals())
.containsExactly(
SubscriptionSchedulePlanChangeResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -873,7 +873,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -886,7 +886,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -894,7 +894,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -910,16 +910,16 @@ class SubscriptionSchedulePlanChangeResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -944,7 +944,7 @@ class SubscriptionSchedulePlanChangeResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionTest.kt
index 2884ea08..f9585e9a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionTest.kt
@@ -13,7 +13,7 @@ class SubscriptionTest {
val subscription =
Subscription.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
Subscription.AdjustmentInterval.builder()
@@ -45,12 +45,12 @@ class SubscriptionTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
Subscription.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -148,7 +148,7 @@ class SubscriptionTest {
Subscription.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -177,7 +177,7 @@ class SubscriptionTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -198,7 +198,7 @@ class SubscriptionTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -221,7 +221,7 @@ class SubscriptionTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -234,12 +234,12 @@ class SubscriptionTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -256,7 +256,7 @@ class SubscriptionTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -272,7 +272,7 @@ class SubscriptionTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -281,7 +281,7 @@ class SubscriptionTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -297,16 +297,16 @@ class SubscriptionTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -337,7 +337,7 @@ class SubscriptionTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -358,18 +358,18 @@ class SubscriptionTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
Subscription.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -384,7 +384,7 @@ class SubscriptionTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -399,7 +399,7 @@ class SubscriptionTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -408,7 +408,7 @@ class SubscriptionTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -424,16 +424,16 @@ class SubscriptionTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -464,7 +464,7 @@ class SubscriptionTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -495,7 +495,7 @@ class SubscriptionTest {
.build()
assertThat(subscription).isNotNull
assertThat(subscription.id()).isEqualTo("id")
- assertThat(subscription.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscription.activePlanPhaseOrder()).contains(0L)
assertThat(subscription.adjustmentIntervals())
.containsExactly(
Subscription.AdjustmentInterval.builder()
@@ -525,12 +525,12 @@ class SubscriptionTest {
assertThat(subscription.billingCycleAnchorConfiguration())
.isEqualTo(
Subscription.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscription.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscription.billingCycleDay()).isEqualTo(1L)
assertThat(subscription.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscription.currentBillingPeriodEndDate())
@@ -629,7 +629,7 @@ class SubscriptionTest {
Subscription.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -655,7 +655,7 @@ class SubscriptionTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscription.netTerms()).isEqualTo(123L)
+ assertThat(subscription.netTerms()).isEqualTo(0L)
assertThat(subscription.plan())
.isEqualTo(
Plan.builder()
@@ -677,7 +677,7 @@ class SubscriptionTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -700,7 +700,7 @@ class SubscriptionTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -713,12 +713,12 @@ class SubscriptionTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -735,7 +735,7 @@ class SubscriptionTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -749,7 +749,7 @@ class SubscriptionTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -758,7 +758,7 @@ class SubscriptionTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -774,16 +774,16 @@ class SubscriptionTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -811,7 +811,7 @@ class SubscriptionTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -832,18 +832,18 @@ class SubscriptionTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscription.priceIntervals())
.containsExactly(
Subscription.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -852,7 +852,7 @@ class SubscriptionTest {
Subscription.PriceInterval.FixedFeeQuantityTransition.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -865,7 +865,7 @@ class SubscriptionTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -873,7 +873,7 @@ class SubscriptionTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -889,16 +889,16 @@ class SubscriptionTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -923,7 +923,7 @@ class SubscriptionTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionTriggerPhaseResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionTriggerPhaseResponseTest.kt
index c018ace9..cae7cfc5 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionTriggerPhaseResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionTriggerPhaseResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionTriggerPhaseResponseTest {
val subscriptionTriggerPhaseResponse =
SubscriptionTriggerPhaseResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionTriggerPhaseResponse.AdjustmentInterval.builder()
@@ -47,12 +47,12 @@ class SubscriptionTriggerPhaseResponseTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
SubscriptionTriggerPhaseResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -152,7 +152,7 @@ class SubscriptionTriggerPhaseResponseTest {
SubscriptionTriggerPhaseResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -181,7 +181,7 @@ class SubscriptionTriggerPhaseResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -202,7 +202,7 @@ class SubscriptionTriggerPhaseResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -225,7 +225,7 @@ class SubscriptionTriggerPhaseResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -238,12 +238,12 @@ class SubscriptionTriggerPhaseResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -260,7 +260,7 @@ class SubscriptionTriggerPhaseResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -276,7 +276,7 @@ class SubscriptionTriggerPhaseResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -285,7 +285,7 @@ class SubscriptionTriggerPhaseResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -301,16 +301,16 @@ class SubscriptionTriggerPhaseResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -341,7 +341,7 @@ class SubscriptionTriggerPhaseResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -362,18 +362,18 @@ class SubscriptionTriggerPhaseResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionTriggerPhaseResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -390,7 +390,7 @@ class SubscriptionTriggerPhaseResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -405,7 +405,7 @@ class SubscriptionTriggerPhaseResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -414,7 +414,7 @@ class SubscriptionTriggerPhaseResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -430,16 +430,16 @@ class SubscriptionTriggerPhaseResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -470,7 +470,7 @@ class SubscriptionTriggerPhaseResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -501,7 +501,7 @@ class SubscriptionTriggerPhaseResponseTest {
.build()
assertThat(subscriptionTriggerPhaseResponse).isNotNull
assertThat(subscriptionTriggerPhaseResponse.id()).isEqualTo("id")
- assertThat(subscriptionTriggerPhaseResponse.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscriptionTriggerPhaseResponse.activePlanPhaseOrder()).contains(0L)
assertThat(subscriptionTriggerPhaseResponse.adjustmentIntervals())
.containsExactly(
SubscriptionTriggerPhaseResponse.AdjustmentInterval.builder()
@@ -534,12 +534,12 @@ class SubscriptionTriggerPhaseResponseTest {
assertThat(subscriptionTriggerPhaseResponse.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionTriggerPhaseResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionTriggerPhaseResponse.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscriptionTriggerPhaseResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionTriggerPhaseResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionTriggerPhaseResponse.currentBillingPeriodEndDate())
@@ -642,7 +642,7 @@ class SubscriptionTriggerPhaseResponseTest {
SubscriptionTriggerPhaseResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -670,7 +670,7 @@ class SubscriptionTriggerPhaseResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionTriggerPhaseResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionTriggerPhaseResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionTriggerPhaseResponse.plan())
.isEqualTo(
Plan.builder()
@@ -692,7 +692,7 @@ class SubscriptionTriggerPhaseResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -715,7 +715,7 @@ class SubscriptionTriggerPhaseResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -728,12 +728,12 @@ class SubscriptionTriggerPhaseResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -750,7 +750,7 @@ class SubscriptionTriggerPhaseResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -764,7 +764,7 @@ class SubscriptionTriggerPhaseResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -773,7 +773,7 @@ class SubscriptionTriggerPhaseResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -789,16 +789,16 @@ class SubscriptionTriggerPhaseResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -826,7 +826,7 @@ class SubscriptionTriggerPhaseResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -847,18 +847,18 @@ class SubscriptionTriggerPhaseResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionTriggerPhaseResponse.priceIntervals())
.containsExactly(
SubscriptionTriggerPhaseResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -869,7 +869,7 @@ class SubscriptionTriggerPhaseResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -882,7 +882,7 @@ class SubscriptionTriggerPhaseResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -890,7 +890,7 @@ class SubscriptionTriggerPhaseResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -906,16 +906,16 @@ class SubscriptionTriggerPhaseResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -940,7 +940,7 @@ class SubscriptionTriggerPhaseResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnscheduleCancellationResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnscheduleCancellationResponseTest.kt
index ab81049c..63eaa454 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnscheduleCancellationResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnscheduleCancellationResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
val subscriptionUnscheduleCancellationResponse =
SubscriptionUnscheduleCancellationResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionUnscheduleCancellationResponse.AdjustmentInterval.builder()
@@ -51,12 +51,12 @@ class SubscriptionUnscheduleCancellationResponseTest {
.billingCycleAnchorConfiguration(
SubscriptionUnscheduleCancellationResponse.BillingCycleAnchorConfiguration
.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -159,7 +159,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -188,7 +188,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -209,7 +209,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -232,7 +232,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -245,12 +245,12 @@ class SubscriptionUnscheduleCancellationResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -267,7 +267,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -283,7 +283,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -292,7 +292,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -308,16 +308,16 @@ class SubscriptionUnscheduleCancellationResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -348,7 +348,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -369,18 +369,18 @@ class SubscriptionUnscheduleCancellationResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionUnscheduleCancellationResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -397,7 +397,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -412,7 +412,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -421,7 +421,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -437,16 +437,16 @@ class SubscriptionUnscheduleCancellationResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -477,7 +477,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -508,7 +508,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.build()
assertThat(subscriptionUnscheduleCancellationResponse).isNotNull
assertThat(subscriptionUnscheduleCancellationResponse.id()).isEqualTo("id")
- assertThat(subscriptionUnscheduleCancellationResponse.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscriptionUnscheduleCancellationResponse.activePlanPhaseOrder()).contains(0L)
assertThat(subscriptionUnscheduleCancellationResponse.adjustmentIntervals())
.containsExactly(
SubscriptionUnscheduleCancellationResponse.AdjustmentInterval.builder()
@@ -543,12 +543,12 @@ class SubscriptionUnscheduleCancellationResponseTest {
assertThat(subscriptionUnscheduleCancellationResponse.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionUnscheduleCancellationResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionUnscheduleCancellationResponse.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscriptionUnscheduleCancellationResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionUnscheduleCancellationResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionUnscheduleCancellationResponse.currentBillingPeriodEndDate())
@@ -654,7 +654,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
SubscriptionUnscheduleCancellationResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -682,7 +682,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionUnscheduleCancellationResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionUnscheduleCancellationResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionUnscheduleCancellationResponse.plan())
.isEqualTo(
Plan.builder()
@@ -704,7 +704,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -727,7 +727,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -740,12 +740,12 @@ class SubscriptionUnscheduleCancellationResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -762,7 +762,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -776,7 +776,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -785,7 +785,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -801,16 +801,16 @@ class SubscriptionUnscheduleCancellationResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -838,7 +838,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -859,18 +859,18 @@ class SubscriptionUnscheduleCancellationResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionUnscheduleCancellationResponse.priceIntervals())
.containsExactly(
SubscriptionUnscheduleCancellationResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -881,7 +881,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -894,7 +894,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -902,7 +902,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -918,16 +918,16 @@ class SubscriptionUnscheduleCancellationResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -952,7 +952,7 @@ class SubscriptionUnscheduleCancellationResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest.kt
index fd6195ed..adc43838 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
val subscriptionUnscheduleFixedFeeQuantityUpdatesResponse =
SubscriptionUnscheduleFixedFeeQuantityUpdatesResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionUnscheduleFixedFeeQuantityUpdatesResponse.AdjustmentInterval
@@ -54,12 +54,12 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
SubscriptionUnscheduleFixedFeeQuantityUpdatesResponse
.BillingCycleAnchorConfiguration
.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -165,7 +165,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -198,7 +198,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -219,7 +219,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -242,7 +242,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -255,12 +255,12 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -277,7 +277,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -293,7 +293,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -302,7 +302,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -318,16 +318,16 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -358,7 +358,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -379,11 +379,11 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
@@ -391,7 +391,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
SubscriptionUnscheduleFixedFeeQuantityUpdatesResponse.PriceInterval
.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -409,7 +409,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -424,7 +424,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -433,7 +433,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -449,16 +449,16 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -489,7 +489,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -521,7 +521,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse).isNotNull
assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.id()).isEqualTo("id")
assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.activePlanPhaseOrder())
- .contains(123L)
+ .contains(0L)
assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.adjustmentIntervals())
.containsExactly(
SubscriptionUnscheduleFixedFeeQuantityUpdatesResponse.AdjustmentInterval.builder()
@@ -564,13 +564,13 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
SubscriptionUnscheduleFixedFeeQuantityUpdatesResponse
.BillingCycleAnchorConfiguration
.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.billingCycleDay())
- .isEqualTo(31L)
+ .isEqualTo(1L)
assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(
@@ -683,7 +683,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -713,7 +713,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.plan())
.isEqualTo(
Plan.builder()
@@ -735,7 +735,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -758,7 +758,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -771,12 +771,12 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -793,7 +793,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -807,7 +807,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -816,7 +816,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -832,16 +832,16 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -869,7 +869,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -890,18 +890,18 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionUnscheduleFixedFeeQuantityUpdatesResponse.priceIntervals())
.containsExactly(
SubscriptionUnscheduleFixedFeeQuantityUpdatesResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -912,7 +912,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -925,7 +925,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -933,7 +933,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -949,16 +949,16 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -983,7 +983,7 @@ class SubscriptionUnscheduleFixedFeeQuantityUpdatesResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnschedulePendingPlanChangesResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnschedulePendingPlanChangesResponseTest.kt
index dbcb000f..a50a537a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnschedulePendingPlanChangesResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUnschedulePendingPlanChangesResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
val subscriptionUnschedulePendingPlanChangesResponse =
SubscriptionUnschedulePendingPlanChangesResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionUnschedulePendingPlanChangesResponse.AdjustmentInterval
@@ -52,12 +52,12 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.billingCycleAnchorConfiguration(
SubscriptionUnschedulePendingPlanChangesResponse.BillingCycleAnchorConfiguration
.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -161,7 +161,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -192,7 +192,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -213,7 +213,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -236,7 +236,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -249,12 +249,12 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -271,7 +271,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -287,7 +287,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -296,7 +296,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -312,16 +312,16 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -352,7 +352,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -373,18 +373,18 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionUnschedulePendingPlanChangesResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -401,7 +401,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -416,7 +416,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -425,7 +425,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -441,16 +441,16 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -481,7 +481,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -513,7 +513,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
assertThat(subscriptionUnschedulePendingPlanChangesResponse).isNotNull
assertThat(subscriptionUnschedulePendingPlanChangesResponse.id()).isEqualTo("id")
assertThat(subscriptionUnschedulePendingPlanChangesResponse.activePlanPhaseOrder())
- .contains(123L)
+ .contains(0L)
assertThat(subscriptionUnschedulePendingPlanChangesResponse.adjustmentIntervals())
.containsExactly(
SubscriptionUnschedulePendingPlanChangesResponse.AdjustmentInterval.builder()
@@ -552,13 +552,12 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.isEqualTo(
SubscriptionUnschedulePendingPlanChangesResponse.BillingCycleAnchorConfiguration
.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionUnschedulePendingPlanChangesResponse.billingCycleDay())
- .isEqualTo(31L)
+ assertThat(subscriptionUnschedulePendingPlanChangesResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionUnschedulePendingPlanChangesResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionUnschedulePendingPlanChangesResponse.currentBillingPeriodEndDate())
@@ -664,7 +663,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
SubscriptionUnschedulePendingPlanChangesResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -692,7 +691,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionUnschedulePendingPlanChangesResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionUnschedulePendingPlanChangesResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionUnschedulePendingPlanChangesResponse.plan())
.isEqualTo(
Plan.builder()
@@ -714,7 +713,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -737,7 +736,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -750,12 +749,12 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -772,7 +771,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -786,7 +785,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -795,7 +794,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -811,16 +810,16 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -848,7 +847,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -869,18 +868,18 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionUnschedulePendingPlanChangesResponse.priceIntervals())
.containsExactly(
SubscriptionUnschedulePendingPlanChangesResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -891,7 +890,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -904,7 +903,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -912,7 +911,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -928,16 +927,16 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -962,7 +961,7 @@ class SubscriptionUnschedulePendingPlanChangesResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateFixedFeeQuantityParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateFixedFeeQuantityParamsTest.kt
index 55b13d23..55b2ad20 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateFixedFeeQuantityParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateFixedFeeQuantityParamsTest.kt
@@ -14,7 +14,7 @@ class SubscriptionUpdateFixedFeeQuantityParamsTest {
SubscriptionUpdateFixedFeeQuantityParams.builder()
.subscriptionId("subscription_id")
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.changeOption(SubscriptionUpdateFixedFeeQuantityParams.ChangeOption.IMMEDIATE)
.effectiveDate(LocalDate.parse("2022-12-21"))
.build()
@@ -26,14 +26,14 @@ class SubscriptionUpdateFixedFeeQuantityParamsTest {
SubscriptionUpdateFixedFeeQuantityParams.builder()
.subscriptionId("subscription_id")
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.changeOption(SubscriptionUpdateFixedFeeQuantityParams.ChangeOption.IMMEDIATE)
.effectiveDate(LocalDate.parse("2022-12-21"))
.build()
val body = params.getBody()
assertThat(body).isNotNull
assertThat(body.priceId()).isEqualTo("price_id")
- assertThat(body.quantity()).isEqualTo(42.23)
+ assertThat(body.quantity()).isEqualTo(0.0)
assertThat(body.changeOption())
.isEqualTo(SubscriptionUpdateFixedFeeQuantityParams.ChangeOption.IMMEDIATE)
assertThat(body.effectiveDate()).isEqualTo(LocalDate.parse("2022-12-21"))
@@ -45,12 +45,12 @@ class SubscriptionUpdateFixedFeeQuantityParamsTest {
SubscriptionUpdateFixedFeeQuantityParams.builder()
.subscriptionId("subscription_id")
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.build()
val body = params.getBody()
assertThat(body).isNotNull
assertThat(body.priceId()).isEqualTo("price_id")
- assertThat(body.quantity()).isEqualTo(42.23)
+ assertThat(body.quantity()).isEqualTo(0.0)
}
@Test
@@ -59,7 +59,7 @@ class SubscriptionUpdateFixedFeeQuantityParamsTest {
SubscriptionUpdateFixedFeeQuantityParams.builder()
.subscriptionId("subscription_id")
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.build()
assertThat(params).isNotNull
// path param "subscriptionId"
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateFixedFeeQuantityResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateFixedFeeQuantityResponseTest.kt
index 03f4e363..bcdaf067 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateFixedFeeQuantityResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateFixedFeeQuantityResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
val subscriptionUpdateFixedFeeQuantityResponse =
SubscriptionUpdateFixedFeeQuantityResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionUpdateFixedFeeQuantityResponse.AdjustmentInterval.builder()
@@ -51,12 +51,12 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.billingCycleAnchorConfiguration(
SubscriptionUpdateFixedFeeQuantityResponse.BillingCycleAnchorConfiguration
.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -159,7 +159,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -188,7 +188,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -209,7 +209,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -232,7 +232,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -245,12 +245,12 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -267,7 +267,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -283,7 +283,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -292,7 +292,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -308,16 +308,16 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -348,7 +348,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -369,18 +369,18 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionUpdateFixedFeeQuantityResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -397,7 +397,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -412,7 +412,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -421,7 +421,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -437,16 +437,16 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -477,7 +477,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -508,7 +508,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.build()
assertThat(subscriptionUpdateFixedFeeQuantityResponse).isNotNull
assertThat(subscriptionUpdateFixedFeeQuantityResponse.id()).isEqualTo("id")
- assertThat(subscriptionUpdateFixedFeeQuantityResponse.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscriptionUpdateFixedFeeQuantityResponse.activePlanPhaseOrder()).contains(0L)
assertThat(subscriptionUpdateFixedFeeQuantityResponse.adjustmentIntervals())
.containsExactly(
SubscriptionUpdateFixedFeeQuantityResponse.AdjustmentInterval.builder()
@@ -543,12 +543,12 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
assertThat(subscriptionUpdateFixedFeeQuantityResponse.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionUpdateFixedFeeQuantityResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionUpdateFixedFeeQuantityResponse.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscriptionUpdateFixedFeeQuantityResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionUpdateFixedFeeQuantityResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionUpdateFixedFeeQuantityResponse.currentBillingPeriodEndDate())
@@ -654,7 +654,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
SubscriptionUpdateFixedFeeQuantityResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -682,7 +682,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionUpdateFixedFeeQuantityResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionUpdateFixedFeeQuantityResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionUpdateFixedFeeQuantityResponse.plan())
.isEqualTo(
Plan.builder()
@@ -704,7 +704,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -727,7 +727,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -740,12 +740,12 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -762,7 +762,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -776,7 +776,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -785,7 +785,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -801,16 +801,16 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -838,7 +838,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -859,18 +859,18 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionUpdateFixedFeeQuantityResponse.priceIntervals())
.containsExactly(
SubscriptionUpdateFixedFeeQuantityResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -881,7 +881,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -894,7 +894,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -902,7 +902,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -918,16 +918,16 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -952,7 +952,7 @@ class SubscriptionUpdateFixedFeeQuantityResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateParamsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateParamsTest.kt
index d08e8235..2fd3c0f5 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateParamsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateParamsTest.kt
@@ -16,7 +16,7 @@ class SubscriptionUpdateParamsTest {
.defaultInvoiceMemo("default_invoice_memo")
.invoicingThreshold("10.00")
.metadata(SubscriptionUpdateParams.Metadata.builder().build())
- .netTerms(123L)
+ .netTerms(0L)
.build()
}
@@ -29,7 +29,7 @@ class SubscriptionUpdateParamsTest {
.defaultInvoiceMemo("default_invoice_memo")
.invoicingThreshold("10.00")
.metadata(SubscriptionUpdateParams.Metadata.builder().build())
- .netTerms(123L)
+ .netTerms(0L)
.build()
val body = params.getBody()
assertThat(body).isNotNull
@@ -37,7 +37,7 @@ class SubscriptionUpdateParamsTest {
assertThat(body.defaultInvoiceMemo()).isEqualTo("default_invoice_memo")
assertThat(body.invoicingThreshold()).isEqualTo("10.00")
assertThat(body.metadata()).isEqualTo(SubscriptionUpdateParams.Metadata.builder().build())
- assertThat(body.netTerms()).isEqualTo(123L)
+ assertThat(body.netTerms()).isEqualTo(0L)
}
@Test
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateTrialResponseTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateTrialResponseTest.kt
index 974780fc..f014d16d 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateTrialResponseTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionUpdateTrialResponseTest.kt
@@ -13,7 +13,7 @@ class SubscriptionUpdateTrialResponseTest {
val subscriptionUpdateTrialResponse =
SubscriptionUpdateTrialResponse.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
SubscriptionUpdateTrialResponse.AdjustmentInterval.builder()
@@ -47,12 +47,12 @@ class SubscriptionUpdateTrialResponseTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
SubscriptionUpdateTrialResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -152,7 +152,7 @@ class SubscriptionUpdateTrialResponseTest {
SubscriptionUpdateTrialResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -181,7 +181,7 @@ class SubscriptionUpdateTrialResponseTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -202,7 +202,7 @@ class SubscriptionUpdateTrialResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -225,7 +225,7 @@ class SubscriptionUpdateTrialResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -238,12 +238,12 @@ class SubscriptionUpdateTrialResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -260,7 +260,7 @@ class SubscriptionUpdateTrialResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -276,7 +276,7 @@ class SubscriptionUpdateTrialResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -285,7 +285,7 @@ class SubscriptionUpdateTrialResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -301,16 +301,16 @@ class SubscriptionUpdateTrialResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -341,7 +341,7 @@ class SubscriptionUpdateTrialResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -362,18 +362,18 @@ class SubscriptionUpdateTrialResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
SubscriptionUpdateTrialResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -390,7 +390,7 @@ class SubscriptionUpdateTrialResponseTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -405,7 +405,7 @@ class SubscriptionUpdateTrialResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -414,7 +414,7 @@ class SubscriptionUpdateTrialResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -430,16 +430,16 @@ class SubscriptionUpdateTrialResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -470,7 +470,7 @@ class SubscriptionUpdateTrialResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -501,7 +501,7 @@ class SubscriptionUpdateTrialResponseTest {
.build()
assertThat(subscriptionUpdateTrialResponse).isNotNull
assertThat(subscriptionUpdateTrialResponse.id()).isEqualTo("id")
- assertThat(subscriptionUpdateTrialResponse.activePlanPhaseOrder()).contains(123L)
+ assertThat(subscriptionUpdateTrialResponse.activePlanPhaseOrder()).contains(0L)
assertThat(subscriptionUpdateTrialResponse.adjustmentIntervals())
.containsExactly(
SubscriptionUpdateTrialResponse.AdjustmentInterval.builder()
@@ -534,12 +534,12 @@ class SubscriptionUpdateTrialResponseTest {
assertThat(subscriptionUpdateTrialResponse.billingCycleAnchorConfiguration())
.isEqualTo(
SubscriptionUpdateTrialResponse.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- assertThat(subscriptionUpdateTrialResponse.billingCycleDay()).isEqualTo(31L)
+ assertThat(subscriptionUpdateTrialResponse.billingCycleDay()).isEqualTo(1L)
assertThat(subscriptionUpdateTrialResponse.createdAt())
.isEqualTo(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
assertThat(subscriptionUpdateTrialResponse.currentBillingPeriodEndDate())
@@ -642,7 +642,7 @@ class SubscriptionUpdateTrialResponseTest {
SubscriptionUpdateTrialResponse.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -670,7 +670,7 @@ class SubscriptionUpdateTrialResponseTest {
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
- assertThat(subscriptionUpdateTrialResponse.netTerms()).isEqualTo(123L)
+ assertThat(subscriptionUpdateTrialResponse.netTerms()).isEqualTo(0L)
assertThat(subscriptionUpdateTrialResponse.plan())
.isEqualTo(
Plan.builder()
@@ -692,7 +692,7 @@ class SubscriptionUpdateTrialResponseTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -715,7 +715,7 @@ class SubscriptionUpdateTrialResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -728,12 +728,12 @@ class SubscriptionUpdateTrialResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -750,7 +750,7 @@ class SubscriptionUpdateTrialResponseTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -764,7 +764,7 @@ class SubscriptionUpdateTrialResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -773,7 +773,7 @@ class SubscriptionUpdateTrialResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -789,16 +789,16 @@ class SubscriptionUpdateTrialResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -826,7 +826,7 @@ class SubscriptionUpdateTrialResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -847,18 +847,18 @@ class SubscriptionUpdateTrialResponseTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
assertThat(subscriptionUpdateTrialResponse.priceIntervals())
.containsExactly(
SubscriptionUpdateTrialResponse.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -868,7 +868,7 @@ class SubscriptionUpdateTrialResponseTest {
.builder()
.effectiveDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -881,7 +881,7 @@ class SubscriptionUpdateTrialResponseTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration.DurationUnit
.DAY
@@ -889,7 +889,7 @@ class SubscriptionUpdateTrialResponseTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.creditAllocation(
Price.UnitPrice.CreditAllocation.builder()
@@ -905,16 +905,16 @@ class SubscriptionUpdateTrialResponseTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration.DurationUnit
.DAY
@@ -939,7 +939,7 @@ class SubscriptionUpdateTrialResponseTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionsTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionsTest.kt
index f182eb8d..19e94b83 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionsTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/SubscriptionsTest.kt
@@ -16,7 +16,7 @@ class SubscriptionsTest {
listOf(
Subscription.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
Subscription.AdjustmentInterval.builder()
@@ -49,12 +49,12 @@ class SubscriptionsTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
Subscription.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
@@ -164,7 +164,7 @@ class SubscriptionsTest {
Subscription.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -193,7 +193,7 @@ class SubscriptionsTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -216,7 +216,7 @@ class SubscriptionsTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -239,7 +239,7 @@ class SubscriptionsTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -253,12 +253,12 @@ class SubscriptionsTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -275,7 +275,7 @@ class SubscriptionsTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -292,7 +292,7 @@ class SubscriptionsTest {
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.BillingCycleConfiguration
@@ -302,7 +302,7 @@ class SubscriptionsTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse(
"2019-12-27T18:11:19.117Z"
@@ -323,17 +323,17 @@ class SubscriptionsTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.InvoicingCycleConfiguration
@@ -367,7 +367,7 @@ class SubscriptionsTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(
Price.UnitPrice.PriceType.USAGE_PRICE
)
@@ -392,18 +392,18 @@ class SubscriptionsTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
Subscription.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -422,7 +422,7 @@ class SubscriptionsTest {
)
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -438,7 +438,7 @@ class SubscriptionsTest {
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.BillingCycleConfiguration
@@ -448,7 +448,7 @@ class SubscriptionsTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse(
"2019-12-27T18:11:19.117Z"
@@ -469,17 +469,17 @@ class SubscriptionsTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice
.InvoicingCycleConfiguration
@@ -513,7 +513,7 @@ class SubscriptionsTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(
Price.UnitPrice.PriceType.USAGE_PRICE
)
@@ -555,7 +555,7 @@ class SubscriptionsTest {
.containsExactly(
Subscription.builder()
.id("id")
- .activePlanPhaseOrder(123L)
+ .activePlanPhaseOrder(0L)
.adjustmentIntervals(
listOf(
Subscription.AdjustmentInterval.builder()
@@ -587,12 +587,12 @@ class SubscriptionsTest {
.autoCollection(true)
.billingCycleAnchorConfiguration(
Subscription.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
- .billingCycleDay(31L)
+ .billingCycleDay(1L)
.createdAt(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodEndDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.currentBillingPeriodStartDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -690,7 +690,7 @@ class SubscriptionsTest {
Subscription.FixedFeeQuantitySchedule.builder()
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -719,7 +719,7 @@ class SubscriptionsTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.plan(
Plan.builder()
.id("id")
@@ -740,7 +740,7 @@ class SubscriptionsTest {
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -763,7 +763,7 @@ class SubscriptionsTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .netTerms(123L)
+ .netTerms(0L)
.planPhases(
listOf(
Plan.PlanPhase.builder()
@@ -776,12 +776,12 @@ class SubscriptionsTest {
.discountType(
PercentageDiscount.DiscountType.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
- .duration(123L)
+ .duration(0L)
.durationUnit(Plan.PlanPhase.DurationUnit.DAILY)
.maximum(
Plan.PlanPhase.Maximum.builder()
@@ -798,7 +798,7 @@ class SubscriptionsTest {
)
.minimumAmount("minimum_amount")
.name("name")
- .order(123L)
+ .order(0L)
.build()
)
)
@@ -814,7 +814,7 @@ class SubscriptionsTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -823,7 +823,7 @@ class SubscriptionsTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -842,17 +842,17 @@ class SubscriptionsTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -883,7 +883,7 @@ class SubscriptionsTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
@@ -904,18 +904,18 @@ class SubscriptionsTest {
.status(Plan.Status.ACTIVE)
.trialConfig(
Plan.TrialConfig.builder()
- .trialPeriod(123L)
+ .trialPeriod(0L)
.trialPeriodUnit(Plan.TrialConfig.TrialPeriodUnit.DAYS)
.build()
)
- .version(123L)
+ .version(0L)
.build()
)
.priceIntervals(
listOf(
Subscription.PriceInterval.builder()
.id("id")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.currentBillingPeriodEndDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -931,7 +931,7 @@ class SubscriptionsTest {
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
.priceId("price_id")
- .quantity(123L)
+ .quantity(0L)
.build()
)
)
@@ -946,7 +946,7 @@ class SubscriptionsTest {
)
.billingCycleConfiguration(
Price.UnitPrice.BillingCycleConfiguration.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.BillingCycleConfiguration
.DurationUnit
@@ -955,7 +955,7 @@ class SubscriptionsTest {
.build()
)
.cadence(Price.UnitPrice.Cadence.ONE_TIME)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.createdAt(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
@@ -974,17 +974,17 @@ class SubscriptionsTest {
PercentageDiscount.DiscountType
.PERCENTAGE
)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoicingCycleConfiguration(
Price.UnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
Price.UnitPrice.InvoicingCycleConfiguration
.DurationUnit
@@ -1015,7 +1015,7 @@ class SubscriptionsTest {
.minimumAmount("minimum_amount")
.modelType(Price.UnitPrice.ModelType.UNIT)
.name("name")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.priceType(Price.UnitPrice.PriceType.USAGE_PRICE)
.unitConfig(
Price.UnitPrice.UnitConfig.builder()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/models/TrialDiscountTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/models/TrialDiscountTest.kt
index 45a4aa7d..f0fd127c 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/models/TrialDiscountTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/models/TrialDiscountTest.kt
@@ -15,13 +15,13 @@ class TrialDiscountTest {
.discountType(TrialDiscount.DiscountType.TRIAL)
.reason("reason")
.trialAmountDiscount("trial_amount_discount")
- .trialPercentageDiscount(42.23)
+ .trialPercentageDiscount(0.0)
.build()
assertThat(trialDiscount).isNotNull
assertThat(trialDiscount.appliesToPriceIds()).containsExactly("string")
assertThat(trialDiscount.discountType()).isEqualTo(TrialDiscount.DiscountType.TRIAL)
assertThat(trialDiscount.reason()).contains("reason")
assertThat(trialDiscount.trialAmountDiscount()).contains("trial_amount_discount")
- assertThat(trialDiscount.trialPercentageDiscount()).contains(42.23)
+ assertThat(trialDiscount.trialPercentageDiscount()).contains(0.0)
}
}
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/AlertServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/AlertServiceTest.kt
index 543b3d73..18870aa5 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/AlertServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/AlertServiceTest.kt
@@ -38,7 +38,7 @@ class AlertServiceTest {
alertService.update(
AlertUpdateParams.builder()
.alertConfigurationId("alert_configuration_id")
- .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(42.23).build()))
+ .thresholds(listOf(AlertUpdateParams.Threshold.builder().value(0.0).build()))
.build()
)
println(alert)
@@ -74,9 +74,7 @@ class AlertServiceTest {
.currency("currency")
.type(AlertCreateForCustomerParams.Type.USAGE_EXCEEDED)
.thresholds(
- listOf(
- AlertCreateForCustomerParams.Threshold.builder().value(42.23).build()
- )
+ listOf(AlertCreateForCustomerParams.Threshold.builder().value(0.0).build())
)
.build()
)
@@ -101,7 +99,7 @@ class AlertServiceTest {
.thresholds(
listOf(
AlertCreateForExternalCustomerParams.Threshold.builder()
- .value(42.23)
+ .value(0.0)
.build()
)
)
@@ -125,9 +123,7 @@ class AlertServiceTest {
.subscriptionId("subscription_id")
.thresholds(
listOf(
- AlertCreateForSubscriptionParams.Threshold.builder()
- .value(42.23)
- .build()
+ AlertCreateForSubscriptionParams.Threshold.builder().value(0.0).build()
)
)
.type(AlertCreateForSubscriptionParams.Type.USAGE_EXCEEDED)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/CouponServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/CouponServiceTest.kt
index 3762f99a..b899ab46 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/CouponServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/CouponServiceTest.kt
@@ -31,13 +31,13 @@ class CouponServiceTest {
.DiscountType
.PERCENTAGE
)
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.redemptionCode("HALFOFF")
- .durationInMonths(120L)
- .maxRedemptions(123L)
+ .durationInMonths(12L)
+ .maxRedemptions(1L)
.build()
)
println(coupon)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/InvoiceLineItemServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/InvoiceLineItemServiceTest.kt
index 24d0c38f..f767794a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/InvoiceLineItemServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/InvoiceLineItemServiceTest.kt
@@ -27,7 +27,7 @@ class InvoiceLineItemServiceTest {
.endDate(LocalDate.parse("2023-09-22"))
.invoiceId("4khy3nwzktxv7")
.name("Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.build()
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/InvoiceServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/InvoiceServiceTest.kt
index 3b7f899f..8067d25a 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/InvoiceServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/InvoiceServiceTest.kt
@@ -34,7 +34,7 @@ class InvoiceServiceTest {
.itemId("4khy3nwzktxv7")
.modelType(InvoiceCreateParams.LineItem.ModelType.UNIT)
.name("Line Item Name")
- .quantity(42.23)
+ .quantity(1.0)
.startDate(LocalDate.parse("2023-09-22"))
.unitConfig(
InvoiceCreateParams.LineItem.UnitConfig.builder()
@@ -44,14 +44,14 @@ class InvoiceServiceTest {
.build()
)
)
- .netTerms(123L)
+ .netTerms(0L)
.customerId("4khy3nwzktxv7")
.discount(
Discount.ofPercentageDiscount(
PercentageDiscount.builder()
.appliesToPriceIds(listOf("string"))
.discountType(PercentageDiscount.DiscountType.PERCENTAGE)
- .percentageDiscount(1.0)
+ .percentageDiscount(0.15)
.reason("reason")
.build()
)
@@ -59,7 +59,7 @@ class InvoiceServiceTest {
.externalCustomerId("external-customer-id")
.memo("An optional memo for my invoice.")
.metadata(InvoiceCreateParams.Metadata.builder().build())
- .willAutoIssue(true)
+ .willAutoIssue(false)
.build()
)
println(invoice)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/PlanServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/PlanServiceTest.kt
index b86bf2c8..163a1386 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/PlanServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/PlanServiceTest.kt
@@ -46,7 +46,7 @@ class PlanServiceTest {
PlanCreateParams.Price.NewPlanUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PlanCreateParams.Price.NewPlanUnitPrice
.BillingCycleConfiguration
@@ -55,16 +55,16 @@ class PlanServiceTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
PlanCreateParams.Price.NewPlanUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PlanCreateParams.Price.NewPlanUnitPrice
.InvoicingCycleConfiguration
@@ -84,7 +84,7 @@ class PlanServiceTest {
.defaultInvoiceMemo("default_invoice_memo")
.externalPlanId("external_plan_id")
.metadata(PlanCreateParams.Metadata.builder().build())
- .netTerms(123L)
+ .netTerms(0L)
.status(PlanCreateParams.Status.ACTIVE)
.build()
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/PriceServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/PriceServiceTest.kt
index 63b71521..8762a3d7 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/PriceServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/PriceServiceTest.kt
@@ -41,7 +41,7 @@ class PriceServiceTest {
.billingCycleConfiguration(
PriceCreateParams.NewFloatingUnitPrice.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PriceCreateParams.NewFloatingUnitPrice
.BillingCycleConfiguration
@@ -50,14 +50,14 @@ class PriceServiceTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
PriceCreateParams.NewFloatingUnitPrice.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
PriceCreateParams.NewFloatingUnitPrice
.InvoicingCycleConfiguration
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/SubscriptionServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/SubscriptionServiceTest.kt
index 4edb7da6..f7613c9f 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/SubscriptionServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/SubscriptionServiceTest.kt
@@ -45,12 +45,12 @@ class SubscriptionServiceTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -67,8 +67,8 @@ class SubscriptionServiceTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
@@ -76,7 +76,7 @@ class SubscriptionServiceTest {
.externalPriceId("external_price_id")
.maximumAmount("1.23")
.minimumAmount("1.23")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.price(
SubscriptionCreateParams.AddPrice.Price
.ofNewSubscriptionUnitPrice(
@@ -112,7 +112,7 @@ class SubscriptionServiceTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
@@ -122,17 +122,17 @@ class SubscriptionServiceTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.AddPrice.Price
.NewSubscriptionUnitPrice
@@ -163,13 +163,13 @@ class SubscriptionServiceTest {
.awsRegion("aws_region")
.billingCycleAnchorConfiguration(
SubscriptionCreateParams.BillingCycleAnchorConfiguration.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
.couponRedemptionCode("coupon_redemption_code")
- .creditsOverageRate(42.23)
+ .creditsOverageRate(0.0)
.customerId("customer_id")
.defaultInvoiceMemo("default_invoice_memo")
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
@@ -177,13 +177,14 @@ class SubscriptionServiceTest {
.externalMarketplace(SubscriptionCreateParams.ExternalMarketplace.GOOGLE)
.externalMarketplaceReportingId("external_marketplace_reporting_id")
.externalPlanId("ZMwNQefe7J3ecf7W")
- .initialPhaseOrder(123L)
+ .filter("my_property > 100 AND my_other_property = 'bar'")
+ .initialPhaseOrder(2L)
.invoicingThreshold("10.00")
.metadata(SubscriptionCreateParams.Metadata.builder().build())
- .netTerms(123L)
- .perCreditOverageAmount(42.23)
+ .netTerms(0L)
+ .perCreditOverageAmount(0.0)
.planId("ZMwNQefe7J3ecf7W")
- .planVersionNumber(123L)
+ .planVersionNumber(0L)
.priceOverrides(listOf(JsonValue.from(mapOf())))
.removeAdjustments(
listOf(
@@ -217,7 +218,7 @@ class SubscriptionServiceTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -238,13 +239,13 @@ class SubscriptionServiceTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(2.0)
.maximumAmount("1.23")
.minimumAmount("1.23")
.price(
@@ -282,7 +283,7 @@ class SubscriptionServiceTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.ReplacePrice
.Price
@@ -293,17 +294,17 @@ class SubscriptionServiceTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionCreateParams.ReplacePrice.Price
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionCreateParams.ReplacePrice
.Price
@@ -330,7 +331,7 @@ class SubscriptionServiceTest {
)
)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .trialDurationDays(123L)
+ .trialDurationDays(0L)
.build()
)
println(subscriptionCreateResponse)
@@ -353,7 +354,7 @@ class SubscriptionServiceTest {
.defaultInvoiceMemo("default_invoice_memo")
.invoicingThreshold("10.00")
.metadata(SubscriptionUpdateParams.Metadata.builder().build())
- .netTerms(123L)
+ .netTerms(0L)
.build()
)
println(subscription)
@@ -515,7 +516,7 @@ class SubscriptionServiceTest {
SubscriptionPriceIntervalsParams.Add.Discount
.AmountDiscountCreationParams
.builder()
- .amountDiscount(42.23)
+ .amountDiscount(0.0)
.discountType(
SubscriptionPriceIntervalsParams.Add
.Discount
@@ -541,12 +542,12 @@ class SubscriptionServiceTest {
.effectiveDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
- .quantity(123L)
+ .quantity(5L)
.build()
)
)
- .maximumAmount(42.23)
- .minimumAmount(42.23)
+ .maximumAmount(0.0)
+ .minimumAmount(0.0)
.price(
SubscriptionPriceIntervalsParams.Add.Price
.ofNewFloatingUnitPrice(
@@ -583,7 +584,7 @@ class SubscriptionServiceTest {
.NewFloatingUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionPriceIntervalsParams.Add
.Price
@@ -594,16 +595,16 @@ class SubscriptionServiceTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionPriceIntervalsParams.Add.Price
.NewFloatingUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionPriceIntervalsParams.Add
.Price
@@ -646,7 +647,7 @@ class SubscriptionServiceTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -669,7 +670,7 @@ class SubscriptionServiceTest {
listOf(
SubscriptionPriceIntervalsParams.Edit.builder()
.priceIntervalId("sdfs6wdjvn7ujokd")
- .billingCycleDay(123L)
+ .billingCycleDay(0L)
.endDate(
SubscriptionPriceIntervalsParams.Edit.EndDate.ofDateTime(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
@@ -683,7 +684,7 @@ class SubscriptionServiceTest {
.effectiveDate(
OffsetDateTime.parse("2019-12-27T18:11:19.117Z")
)
- .quantity(123L)
+ .quantity(5L)
.build()
)
)
@@ -752,12 +753,12 @@ class SubscriptionServiceTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
.endDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.startDate(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.build()
)
@@ -776,8 +777,8 @@ class SubscriptionServiceTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
@@ -785,7 +786,7 @@ class SubscriptionServiceTest {
.externalPriceId("external_price_id")
.maximumAmount("1.23")
.minimumAmount("1.23")
- .planPhaseOrder(123L)
+ .planPhaseOrder(0L)
.price(
SubscriptionSchedulePlanChangeParams.AddPrice.Price
.ofNewSubscriptionUnitPrice(
@@ -825,7 +826,7 @@ class SubscriptionServiceTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.AddPrice
@@ -837,10 +838,10 @@ class SubscriptionServiceTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionSchedulePlanChangeParams.AddPrice
@@ -848,7 +849,7 @@ class SubscriptionServiceTest {
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.AddPrice
@@ -885,22 +886,23 @@ class SubscriptionServiceTest {
.billingCycleAnchorConfiguration(
SubscriptionSchedulePlanChangeParams.BillingCycleAnchorConfiguration
.builder()
- .day(31L)
- .month(12L)
- .year(123L)
+ .day(1L)
+ .month(1L)
+ .year(0L)
.build()
)
.changeDate(OffsetDateTime.parse("2017-07-21T17:32:28Z"))
.couponRedemptionCode("coupon_redemption_code")
- .creditsOverageRate(42.23)
+ .creditsOverageRate(0.0)
.defaultInvoiceMemo("default_invoice_memo")
.externalPlanId("ZMwNQefe7J3ecf7W")
- .initialPhaseOrder(123L)
+ .filter("my_property > 100 AND my_other_property = 'bar'")
+ .initialPhaseOrder(2L)
.invoicingThreshold("10.00")
- .netTerms(123L)
- .perCreditOverageAmount(42.23)
+ .netTerms(0L)
+ .perCreditOverageAmount(0.0)
.planId("ZMwNQefe7J3ecf7W")
- .planVersionNumber(123L)
+ .planVersionNumber(0L)
.priceOverrides(listOf(JsonValue.from(mapOf())))
.removeAdjustments(
listOf(
@@ -937,7 +939,7 @@ class SubscriptionServiceTest {
.PERCENTAGE_DISCOUNT
)
.appliesToPriceIds(listOf("string"))
- .percentageDiscount(42.23)
+ .percentageDiscount(0.0)
.build()
)
)
@@ -960,13 +962,13 @@ class SubscriptionServiceTest {
.PERCENTAGE
)
.amountDiscount("amount_discount")
- .percentageDiscount(42.23)
- .usageDiscount(42.23)
+ .percentageDiscount(0.15)
+ .usageDiscount(0.0)
.build()
)
)
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(2.0)
.maximumAmount("1.23")
.minimumAmount("1.23")
.price(
@@ -1012,7 +1014,7 @@ class SubscriptionServiceTest {
.NewSubscriptionUnitPrice
.BillingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.ReplacePrice
@@ -1024,10 +1026,10 @@ class SubscriptionServiceTest {
)
.build()
)
- .conversionRate(42.23)
+ .conversionRate(0.0)
.currency("currency")
.externalPriceId("external_price_id")
- .fixedPriceQuantity(42.23)
+ .fixedPriceQuantity(0.0)
.invoiceGroupingKey("invoice_grouping_key")
.invoicingCycleConfiguration(
SubscriptionSchedulePlanChangeParams
@@ -1036,7 +1038,7 @@ class SubscriptionServiceTest {
.NewSubscriptionUnitPrice
.InvoicingCycleConfiguration
.builder()
- .duration(123L)
+ .duration(0L)
.durationUnit(
SubscriptionSchedulePlanChangeParams
.ReplacePrice
@@ -1065,7 +1067,7 @@ class SubscriptionServiceTest {
.build()
)
)
- .trialDurationDays(123L)
+ .trialDurationDays(0L)
.build()
)
println(subscriptionSchedulePlanChangeResponse)
@@ -1159,7 +1161,7 @@ class SubscriptionServiceTest {
SubscriptionUpdateFixedFeeQuantityParams.builder()
.subscriptionId("subscription_id")
.priceId("price_id")
- .quantity(42.23)
+ .quantity(0.0)
.changeOption(SubscriptionUpdateFixedFeeQuantityParams.ChangeOption.IMMEDIATE)
.effectiveDate(LocalDate.parse("2022-12-21"))
.build()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/customers/credits/LedgerServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/customers/credits/LedgerServiceTest.kt
index 920b9694..f64b7383 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/customers/credits/LedgerServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/customers/credits/LedgerServiceTest.kt
@@ -46,7 +46,7 @@ class LedgerServiceTest {
CustomerCreditLedgerCreateEntryParams
.AddIncrementCreditLedgerEntryRequestParams
.builder()
- .amount(42.23)
+ .amount(0.0)
.entryType(
CustomerCreditLedgerCreateEntryParams
.AddIncrementCreditLedgerEntryRequestParams
@@ -63,7 +63,7 @@ class LedgerServiceTest {
.InvoiceSettings
.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
@@ -99,7 +99,7 @@ class LedgerServiceTest {
CustomerCreditLedgerCreateEntryByExternalIdParams
.AddIncrementCreditLedgerEntryRequestParams
.builder()
- .amount(42.23)
+ .amount(0.0)
.entryType(
CustomerCreditLedgerCreateEntryByExternalIdParams
.AddIncrementCreditLedgerEntryRequestParams
@@ -116,7 +116,7 @@ class LedgerServiceTest {
.InvoiceSettings
.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/customers/credits/TopUpServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/customers/credits/TopUpServiceTest.kt
index 68fbe993..1abdf7a8 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/customers/credits/TopUpServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/customers/credits/TopUpServiceTest.kt
@@ -30,14 +30,14 @@ class TopUpServiceTest {
.invoiceSettings(
CustomerCreditTopUpCreateParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(CustomerCreditTopUpCreateParams.ExpiresAfterUnit.DAY)
.build()
)
@@ -94,14 +94,14 @@ class TopUpServiceTest {
.invoiceSettings(
CustomerCreditTopUpCreateByExternalIdParams.InvoiceSettings.builder()
.autoCollection(true)
- .netTerms(123L)
+ .netTerms(0L)
.memo("memo")
.requireSuccessfulPayment(true)
.build()
)
.perUnitCostBasis("per_unit_cost_basis")
.threshold("threshold")
- .expiresAfter(123L)
+ .expiresAfter(0L)
.expiresAfterUnit(
CustomerCreditTopUpCreateByExternalIdParams.ExpiresAfterUnit.DAY
)
diff --git a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/events/VolumeServiceTest.kt b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/events/VolumeServiceTest.kt
index 4efc8f0b..b47be161 100644
--- a/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/events/VolumeServiceTest.kt
+++ b/orb-java-core/src/test/kotlin/com/withorb/api/services/blocking/events/VolumeServiceTest.kt
@@ -25,7 +25,7 @@ class VolumeServiceTest {
EventVolumeListParams.builder()
.timeframeStart(OffsetDateTime.parse("2019-12-27T18:11:19.117Z"))
.cursor("cursor")
- .limit(123L)
+ .limit(1L)
.timeframeEnd(OffsetDateTime.parse("2024-10-11T06:00:00Z"))
.build()
)