2using System.Collections.Generic;
4using System.Linq.Expressions;
5using System.Reflection;
18using Microsoft.VisualStudio.TestTools.UnitTesting;
23using TestCategory =
NUnit.Framework.CategoryAttribute;
59 [
TestMethod, TestCategory(
"FixedRateCurrencyConverter")]
75 #region Layer Derived Types
79 #region Set Up and Configuration
80 private const string TypeName =
"AggXL";
83 #endregion Set Up and Configuration
89 #region Set Up and Configuration
90 private const string TypeName =
"Generic";
93 #endregion Set Up and Configuration
97 #region reinstatements
110 #region reinstatement.premium and .brokerage
155 #endregion reinstatement.premium and .brokerage
156 #endregion reinstatements
160 #region reinstatements
176 #endregion reinstatements
183 #region Set Up and Configuration
184 private const string TypeName =
"CatXL";
187 #endregion Set Up and Configuration
209 #region reinstatements
224 #endregion reinstatements
252 #region reinstatements
268 #endregion reinstatements
275 #region Set Up and Configuration
276 private const string TypeName =
"QuotaShare";
279 #endregion Set Up and Configuration
286 #region Set Up and Configuration
287 private const string TypeName =
"AggregateQuotaShare";
290 #endregion Set Up and Configuration
293 #region aggregate_attachment
306 #endregion aggregate_attachment
308 #region aggregate_limit
321 #endregion aggregate_limit
325 #region aggregate_attachment
338 #endregion aggregate_attachment
340 #region aggregate_limit
353 #endregion aggregate_limit
360 #region Set Up and Configuration
361 private const string TypeName =
"SurplusShare";
364 #endregion Set Up and Configuration
387 #endregion sums_insured
389 #region retained_line
402 #endregion retained_line
404 #region participation
416 Skip.
Indefinitely(
"ARE-5460: Server doesn't return SurplusShare participation.");
431 double computed_participation = TestResource.participation;
446 Console.WriteLine(
"Property identifying as \"participation\" is named \"" +
460 "This test assumes the test resource has a positive computed participation.");
469 "Server did not compute the same negative participation as us."));
476 () => TestResource.participation = 1);
478 #endregion participation
480 #region number_of_lines
511 #endregion number_of_lines
528 #endregion sums_insured
530 #region retained_line
542 #endregion retained_line
544 #region participation
547 #endregion participation
549 #region number_of_lines
555 #endregion number_of_lines
562 #region Set Up and Configuration
563 private const string TypeName =
"IndustryLossWarranty";
566 #endregion Set Up and Configuration
695 #region Set Up and Configuration
696 private const string TypeName =
"Nested";
699 #endregion Set Up and Configuration
712 #endregion Test Helpers
958 #region Set Up and Configuration
959 private const string TypeName =
"Filter";
962 #endregion Set Up and Configuration
971 #endregion Test Invert
978 Samples.LossFilter_GTFilter.AsReference },
true);
992 new Reference<LossFilter>(Samples.Valid_NonExistant_UUID) },
false);
1019 #endregion Test Filters
1060 #region Set Up and Configuration
1061 private const string TypeName =
"FixedRateCurrencyConverter";
1064 #endregion Set Up and Configuration
1107 Assert.Inconclusive(
"RUN_OFFLINE = true");
1114 .Change(layer => layer.in_currency,
"AAA")
1115 .Change(layer => layer.loss_sets,
new List<
IReference<LossSet>> { lossSet.ToReference() });
1120 #endregion in_currency
1122 #region out_currency
1155 #endregion out_currency
1274 #region Set Up and Configuration
1275 private const string TypeName =
"LossRank";
1278 #endregion Set Up and Configuration
1287 #endregion Test Invert
1310 #endregion Test Count
1312 #region Test Criterion
1326 #endregion Test Criterion
1336 #endregion Test Invert
1354 #endregion Test Count
1356 #region Test Criterion
1370 #endregion Test Criterion
1377 #region Set Up and Configuration
1378 private const string TypeName =
"NoClaimsBonus";
1381 #endregion Set Up and Configuration
1384 #region payout_amount
1396 #endregion payout_amount
1424 #endregion payout_date
1428 #region payout_amount
1440 #endregion payout_amount
1453 TestResource.payout_date.Value.Subtract(
new TimeSpan(0, 0, 0, 1)),
true);
1469 #endregion payout_date
1476 #region Set Up and Configuration
1477 private const string TypeName =
"ValueAllocator";
1480 #endregion Set Up and Configuration
1640 #region allocation_perspectives
1660 POST_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.LossNetOfAggregateTerms },
true);
1661 POST_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.ReinstatementPremium },
true);
1662 POST_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.ReinstatementBrokerage },
true);
1663 POST_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.LossNetOfAggregateTerms, ValueAllocator.Perspective.ReinstatementPremium },
true);
1664 POST_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.LossNetOfAggregateTerms, ValueAllocator.Perspective.ReinstatementBrokerage },
true);
1665 POST_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.ReinstatementPremium, ValueAllocator.Perspective.ReinstatementBrokerage },
true);
1666 POST_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.LossNetOfAggregateTerms,
1667 ValueAllocator.Perspective.ReinstatementPremium, ValueAllocator.Perspective.ReinstatementBrokerage },
true);
1669 #endregion allocation_perspectives
1671 #region proportioned_perspective
1684 #endregion proportioned_perspective
1686 #region allocation_ratio_basis
1698 #endregion allocation_ratio_basis
1855 #region allocation_perspectives
1875 PUT_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.LossNetOfAggregateTerms },
true);
1876 PUT_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.ReinstatementPremium },
true);
1877 PUT_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.ReinstatementBrokerage },
true);
1878 PUT_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.LossNetOfAggregateTerms, ValueAllocator.Perspective.ReinstatementPremium },
true);
1879 PUT_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.LossNetOfAggregateTerms, ValueAllocator.Perspective.ReinstatementBrokerage },
true);
1880 PUT_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.ReinstatementPremium, ValueAllocator.Perspective.ReinstatementBrokerage },
true);
1881 PUT_WithValue(
l =>
l.allocation_perspectives,
new[] { ValueAllocator.Perspective.LossNetOfAggregateTerms,
1882 ValueAllocator.Perspective.ReinstatementPremium, ValueAllocator.Perspective.ReinstatementBrokerage },
true);
1884 #endregion allocation_perspectives
1886 #region proportioned_perspective
1899 #endregion proportioned_perspective
1901 #region allocation_ratio_basis
1913 #endregion allocation_ratio_basis
1920 #region Set Up and Configuration
1921 private const string TypeName =
"BackAllocatedLayer";
1924 #endregion Set Up and Configuration
1926 #region Test Helpers
1938 #endregion Test Helpers
1988 Console.WriteLine(
"Skipping sink layer reference test of un-saveable layer type " +
1989 layer.UnderlyingType.NiceTypeName());
2003 Skip.
Indefinitely(
"ARE-7212: BackAllocating Payment Patterns cause Internal Server Errors");
2023 Console.WriteLine(
"Skipping sink layer reference test of un-saveable layer type " +
2024 layer.UnderlyingType.NiceTypeName());
2064 POST_StringAttribute_Empty(
a =>
a.source_id);
2081 #endregion source_id
2131 Skip.
Indefinitely(
"ARE-7212: BackAllocating Payment Patterns cause Internal Server Errors");
2170 PUT_StringAttribute_Empty(
a =>
a.source_id);
2178 #endregion source_id
2185 #region Set Up and Configuration
2186 private const string TypeName =
"DelayedPayment";
2189 #endregion Set Up and Configuration
2192 #region Test payments
2198 new DelayedPayment.Payment(0d, 0.5),
2199 new DelayedPayment.Payment(1d, 0.5)
2221 new DelayedPayment.Payment(-2d, -5.0),
2222 new DelayedPayment.Payment(-1d, 0.5),
2223 new DelayedPayment.Payment(1d, -0.5)
2233 new DelayedPayment.Payment(1d, 0.1),
2234 new DelayedPayment.Payment(3d, 0.1),
2235 new DelayedPayment.Payment(2d, 0.1),
2244 { new DelayedPayment.Payment(Double.NaN, 0.1), },
false);
2246 { new DelayedPayment.Payment(Double.PositiveInfinity, 0.1), },
false);
2248 { new DelayedPayment.Payment(Double.NegativeInfinity, 0.1), },
false);
2251 { new DelayedPayment.Payment(0d, Double.NaN), },
false);
2253 { new DelayedPayment.Payment(0d, Double.PositiveInfinity), },
false);
2255 { new DelayedPayment.Payment(0d, Double.NegativeInfinity), },
false);
2263 { new DelayedPayment.Payment(Double.MaxValue, 0.1), },
true);
2265 { new DelayedPayment.Payment(Double.Epsilon, 0.1), },
true);
2267 { new DelayedPayment.Payment(Double.MinValue, 0.1), },
true);
2269 { new DelayedPayment.Payment(Math.PI, 0.1), },
true);
2272 { new DelayedPayment.Payment(0d, Double.MaxValue), },
true);
2274 { new DelayedPayment.Payment(0d, Double.Epsilon), },
true);
2276 { new DelayedPayment.Payment(0d, Double.MinValue), },
true);
2278 { new DelayedPayment.Payment(0d, Math.PI), },
true);
2280 #endregion Test payments
2284 #region Test payments
2290 new DelayedPayment.Payment(0d, 0.5),
2291 new DelayedPayment.Payment(1d, 0.5)
2313 new DelayedPayment.Payment(-2d, -5.0),
2314 new DelayedPayment.Payment(-1d, 0.5),
2315 new DelayedPayment.Payment(1d, -0.5)
2325 new DelayedPayment.Payment(1d, 0.1),
2326 new DelayedPayment.Payment(3d, 0.1),
2327 new DelayedPayment.Payment(2d, 0.1),
2336 { new DelayedPayment.Payment(Double.NaN, 0.1), },
false);
2338 { new DelayedPayment.Payment(Double.PositiveInfinity, 0.1), },
false);
2340 { new DelayedPayment.Payment(Double.NegativeInfinity, 0.1), },
false);
2343 { new DelayedPayment.Payment(0d, Double.NaN), },
false);
2345 { new DelayedPayment.Payment(0d, Double.PositiveInfinity), },
false);
2347 { new DelayedPayment.Payment(0d, Double.NegativeInfinity), },
false);
2355 { new DelayedPayment.Payment(Double.MaxValue, 0.1), },
true);
2357 { new DelayedPayment.Payment(Double.Epsilon, 0.1), },
true);
2359 { new DelayedPayment.Payment(Double.MinValue, 0.1), },
true);
2361 { new DelayedPayment.Payment(Math.PI, 0.1), },
true);
2364 { new DelayedPayment.Payment(0d, Double.MaxValue), },
true);
2366 { new DelayedPayment.Payment(0d, Double.Epsilon), },
true);
2368 { new DelayedPayment.Payment(0d, Double.MinValue), },
true);
2370 { new DelayedPayment.Payment(0d, Math.PI), },
true);
2372 #endregion Test payments
2379 #region Set Up and Configuration
2380 private const string TypeName =
"FixedDatePayment";
2383 #endregion Set Up and Configuration
2386 #region Test payments
2430 #endregion Test payments
2432 #region Test payment_dates
2437 Enumerable.Range(0, TestResource.payments.Count)
2458 TestResource.payment_dates.Reverse<
DateTime>().ToList(),
false);
2465 Enumerable.Range(0, TestResource.payments.Count - 1)
2473 POST_WithValue(
l =>
l.payment_dates,
new[] { new DateTime(0L, DateTimeKind.Utc) }
2474 .Concat(TestResource.payment_dates).ToList(),
true);
2476 new[] { new DateTime(DateTime.MaxValue.Ticks, DateTimeKind.Utc) }).ToList(),
true);
2478 #endregion Test payment_dates
2482 #region Test payments
2526 #endregion Test payments
2528 #region Test payment_dates
2533 Enumerable.Range(0, TestResource.payments.Count)
2554 TestResource.payment_dates.Reverse<
DateTime>().ToList(),
false);
2561 Enumerable.Range(0, TestResource.payments.Count - 1)
2569 PUT_WithValue(
l =>
l.payment_dates,
new[] { new DateTime(0L, DateTimeKind.Utc) }
2570 .Concat(TestResource.payment_dates).ToList(),
true);
2571 PUT_WithValue(
l =>
l.payment_dates, TestResource.payment_dates.Concat(
2572 new[] { new DateTime(DateTime.MaxValue.Ticks, DateTimeKind.Utc) }).ToList(),
true);
2574 #endregion Test payment_dates
2577 #endregion Layer Derived Types
2579 #region Abstract Base Layer Tests
2584 private const string TypeName =
"QuotaShare";
2599 #endregion event_limit
2615 #endregion event_limit
2623 private const string TypeName =
"Layer_AggXL_Base";
2626 #region aggregate_limit
2638 #endregion aggregate_limit
2640 #region aggregate_attachment
2652 #endregion aggregate_attachment
2656 #region aggregate_limit
2668 #endregion aggregate_limit
2670 #region aggregate_attachment
2682 #endregion aggregate_attachment
2689 private const string TypeName =
"Layer_XL";
2718 #endregion attachment
2732 #endregion franchise
2762 #endregion attachment
2776 #endregion franchise
2783 private const string TypeName =
"Layer_WithTerms";
2786 #region participation
2817 #endregion participation
2819 #region inception_date and expiry_date
2858 "Test cannot proceed unless the inception date is set on the test resource.");
2862 #endregion inception_date and expiry_date
2892 private void Test_Layer_POST_Fee(
Fee fee)
2901 Test_Layer_POST_Fee(
fee);
2909 new ProfitCommission
2912 payout_date = TestResource.inception_date,
2914 losses = new List<FeeReference> { FeeReference.CreateFromPremiumOrLossName(
"X") },
2924 new ProfitCommission()
2927 payout_date = TestResource.inception_date,
2929 losses = new List<FeeReference>
2931 FeeReference.CreateFromPremiumOrLossName(
"ReinstatementBrokerage")
2933 premiums = new List<FeeReference>
2935 FeeReference.CreateFromPremiumOrLossName(
"ReinstatementPremium")
2946 new ProfitCommission()
2949 payout_date = TestResource.inception_date,
2951 premiums = new List<FeeReference>
2953 FeeReference.CreateFromPremiumOrLossName(
"ReinstatementBrokerage")
2964 new ProportionalExpense
2967 payout_date = TestResource.inception_date,
2969 premiums = new List<FeeReference> { FeeReference.CreateFromPremiumOrLossName(
"X") },
2979 new ProfitCommission
2982 payout_date = TestResource.inception_date,
2984 fees = new List<FeeReference> { FeeReference.CreateFromFeeName(
"X") }
2994 new ProfitCommission
2997 payout_date = TestResource.inception_date,
2999 fees = new List<FeeReference> { FeeReference.CreateFromFeeName(
"MyFee") }
3012 payout_date = TestResource.inception_date,
3018 payout_date = TestResource.inception_date,
3025 payout_date = TestResource.inception_date,
3032 payout_date = TestResource.inception_date,
3039 payout_date = TestResource.inception_date,
3046 payout_date = TestResource.inception_date,
3057 payout_date = TestResource.inception_date,
3075 #region participation
3081 #endregion participation
3083 #region inception_date and expiry_date
3100 TestResource.inception_date.Value.Subtract(
new TimeSpan(0, 0, 0, 1)),
true);
3107 TestResource.expiry_date.Value.Add(
new TimeSpan(0, 0, 0, 1)),
true);
3133 Assert.IsNotNull(TestResource.inception_date,
3134 "Test cannot proceed unless the inception date is set on the test resource.");
3136 TestResource.inception_date.Value.Subtract(
new TimeSpan(0, 0, 0, 1)),
false);
3138 #endregion inception_date and expiry_date
3170 private const string TypeName =
"Layer_Unsaveable";
3179 $"The {typeof(T).NiceTypeName()} layer type is being tested as an un-saveable " +
3180 $"layer, but it does not carry the {nameof(NotSaveableAttribute)}.");
3191 GenericTest.POST_InvalidResource_Fails(TestResource);
3213 #region Hidden Tests
3244 #endregion Hidden Tests
3250 private const string TypeName =
"Layer_WithLossSets";
3279 Assert.Inconclusive(
"RUN_OFFLINE = true");
3286 GenericTest.POST_InvalidResource_Fails(TestResource.Change(
l =>
l.loss_sets,
3289 #endregion loss_sets
3330 Samples.LossSet_YELTLossSetWithReinstatements.AsReference,
3353 Assert.Inconclusive(
"RUN_OFFLINE = true");
3358 PUT_WithValue(l => l.loss_sets,
3359 new List<IReference<LossSet>> { notFinalized.ToReference() },
false);
3362 #endregion loss_sets
3400 private const string TypeName =
"Layer";
3418 $"The {typeof(T).NiceTypeName()} layer type is being tested as a saveable " +
3419 $"layer, but it carries the {nameof(NotSaveableAttribute)}.");
3423 #region BaseMutableResourceTestSuite Overrides
3437 base.Test_Resource_GET_AllPropertiesRecognized();
3445 #region Helper Methods
3483 #endregion Helper Methods
3489 GenericTest.POST_InvalidResource_Fails(TestResource);
3491 base.Test_Resource_POST_FieldsIdOnly();
3499 base.Test_Resource_ShallowCopy();
3502 r => r.ShallowCopy());
3509 base.Test_Resource_DeepCopy();
3514 #endregion BaseMutableResourceTestSuite Overrides
3516 #endregion Abstract Base Layer Tests
Tests for a stored resource collection which do not require an instance of that resource to be define...
virtual T TestResource
The resource used for all unit tests that require a valid prepared but unPOSTed resource.
virtual void POST_ThenDoAction(T validToPost, Action< T > toExecute)
Post a valid resource under the assumption that it will succeed, then perform an action on the result...
static List< Fee > ListOfAllFeeTypes
static List< Fee > ListWithNestedFeeReference
Exposes sample resource objects, with built-in methods for injecting dependencies.
static readonly PollingOptions DataPollingOptions
Polling options to use when uploading a data file.
List< IInjectableResource< ILayerView > > AllLayerViewTypesTestList
A list of one of each type of layer.
IInjectableResource< Nested > Layer_Nested
A simple nested layer retaining a CatXL source's losses to an AggXL sink.
static Policy TransformAllPolicy
IInjectableResource< SurplusShare > Layer_SurplusShare
IInjectableResource< ELTLossSet > LossSet_ELTLossSet
IInjectableResource< AggXL > Layer_AggXL
IInjectableResource< Generic > Layer_Generic
List< IInjectableResource< ILayer > > AllSaveableLayerTypesTestList
A list of one of each type of layer that can be POSTed. Layer types that cannot be posted on their ow...
IInjectableResource< AnalysisProfile > AnalysisProfile
An analysis profile with one of each possible type of filter.
IInjectableResource< BackAllocatedLayer > Layer_BackAllocatedLayer
IInjectableResource< IndustryLossWarranty > Layer_IndustryLossWarranty
IInjectableResource< LossRank > Layer_LossRank
IInjectableResource< AggregateQuotaShare > Layer_AggregateQuotaShare
static string Valid_NonExistant_UUID
IInjectableResource< ValueAllocator > Layer_ValueAllocator
DateTime SimulationStartDate
The relative start_date to use for all new resources that require an absolute DateTime point of refer...
IInjectableResource< CatXL > Layer_CatXL
List< IInjectableResource< ILayer > > AllLayerTypesTestList
A list of one of each type of layer.
IInjectableResource< Filter > Layer_Filter
IInjectableResource< FixedDatePayment > Layer_FixedDatePayment
static Policy ForwardAllPolicy
IInjectableResource< QuotaShare > Layer_QuotaShare
IInjectableResource< DelayedPayment > Layer_DelayedPayment
IInjectableResource< FixedRateCurrencyConverter > Layer_FixedRateCurrencyConverter
IInjectableResource< NoClaimsBonus > Layer_NoClaimsBonus
Contains static helper methods for testing IAPIResourceView instances.
Special case - for simplicity, Generic layer inherits from AggXL.
virtual void Test_Layer_AggXL_PUT_AggregateLimit_HighPrecision()
virtual void Test_Layer_AggXL_PUT_AggregateLimit_Null()
virtual void Test_Layer_AggXL_PUT_AggregateAttachment_Null()
virtual void Test_Layer_AggXL_POST_AggregateAttachment_Null()
virtual void Test_Layer_AggXL_POST_AggregateLimit_HighPrecision()
virtual void Test_Layer_AggXL_PUT_AggregateAttachment_HighPrecision()
virtual void Test_Layer_AggXL_POST_AggregateLimit_Null()
virtual void Test_Layer_AggXL_POST_AggregateAttachment_HighPrecision()
override IInjectableResource< AggXL > TestInjectableResource
void Test_Layer_AggregateQuotaShare_POST_AggregateLimit_Null()
void Test_Layer_AggregateQuotaShare_POST_AggregateAttachment_HighPrecision()
void Test_Layer_AggregateQuotaShare_PUT_AggregateLimit_Null()
void Test_Layer_AggregateQuotaShare_PUT_AggregateLimit_HighPrecision()
void Test_Layer_AggregateQuotaShare_PUT_AggregateAttachment_HighPrecision()
void Test_Layer_AggregateQuotaShare_PUT_AggregateAttachment_Null()
override IInjectableResource< AggregateQuotaShare > TestInjectableResource
void Test_Layer_AggregateQuotaShare_POST_AggregateLimit_HighPrecision()
void Test_Layer_AggregateQuotaShare_POST_AggregateAttachment_Null()
override IInjectableResource< BackAllocatedLayer > TestInjectableResource
void Test_Layer_BackAllocatedLayer_PUT_Sink_Reference_NullId()
void Test_Layer_BackAllocatedLayer_POST_SourceId_Null()
void Test_Layer_BackAllocatedLayer_POST_SourceId_Blank()
void Test_Layer_BackAllocatedLayer_PUT_SourceId()
void Test_Layer_BackAllocatedLayer_PUT_Sink_Reference_NonExistantId()
void Test_Layer_BackAllocatedLayer_POST_Sink_Reference_EmptyStringId()
void Test_Layer_BackAllocatedLayer_PUT_Sink_ValidTypes()
void Test_Layer_BackAllocatedLayer_POST_Sink_LayerViewReference()
void Test_Layer_BackAllocatedLayer_POST_SourceId_Malformed()
void Test_Layer_BackAllocatedLayer_POST_SourceId_NonExistant()
void Test_Layer_BackAllocatedLayer_POST_Sink_Reference_NullId()
void Test_Layer_BackAllocatedLayer_PUT_Sink_InvalidTypes()
void Test_Layer_BackAllocatedLayer_PUT_Sink_Inlined()
void Test_Layer_BackAllocatedLayer_PUT_Sink_LayerViewReference()
void Test_Layer_BackAllocatedLayer_POST_Sink_InvalidTypes()
void Test_Layer_BackAllocatedLayer_POST_SourceId_LossSet()
void Test_Layer_BackAllocatedLayer_POST_Sink_ValidTypes()
static IEnumerable< IInjectableResource< ILayer > > ForbiddenSinkLayerTypesTestList
A set of injectable test layers that are not valid to use as a sink.
static IEnumerable< IInjectableResource< ILayer > > ValidSinkLayerTypesTestList
A set of injectable test layers that are valid to use as a sink.
void Test_Layer_BackAllocatedLayer_PUT_SourceId_Malformed()
void Test_Layer_BackAllocatedLayer_PUT_Sink_Reference_EmptyStringId()
void Test_Layer_BackAllocatedLayer_PUT_SourceId_Blank()
void Test_Layer_BackAllocatedLayer_PUT_SourceId_Null()
static HashSet< Type > UnsupportedBackAllocatedLayerSinkTypes
Types that cannot be the sink of a Back-Allocated layer.
void Test_Layer_BackAllocatedLayer_PUT_Source()
void Test_Layer_BackAllocatedLayer_POST_Sink_Null()
void Test_Layer_BackAllocatedLayer_POST_Sink_Reference_NonExistantId()
void Test_Layer_BackAllocatedLayer_PUT_Sink_Null()
void Test_Layer_FixedRateCurrencyConverter_POST_NotAllowed()
Demonstrate that layers of type "FixedRateCurrencyConverter" cannot be posted to the /layers/ endpoin...
override IResourceCollection< ILayer > collection_source
static void TestLayerInLayerView< T >(T layerToInline, bool shouldSucceed)
Inline the specified layer in a new LayerView, and test whether the LayerView POST succeeds.
static IEnumerable< Type > PaymentPatternTypes
A list of "PaymentPattern" layer types for convenience (because they comes up in a lot of validation ...
void Test_Layer_Filter_POST_Allowed()
Demonstrate that layers of type "FilterLayer" can be posted to the /layers/ endpoint....
void Test_Layer_CatXL_POST_Reinstatements_Empty()
void Test_Layer_CatXL_POST_Nth_MinValue()
void Test_Layer_CatXL_PUT_Nth_LessThanOne()
void Test_Layer_CatXL_PUT_Nth()
void Test_Layer_CatXL_PUT_Nth_MinValue()
void Test_Layer_CatXL_POST_Nth_MaxValue()
void Test_Layer_CatXL_PUT_Reinstatements_Empty()
void Test_Layer_CatXL_POST_Reinstatements_Null()
void Test_Layer_CatXL_PUT_Reinstatements()
void Test_Layer_CatXL_POST_Nth_LessThanOne()
override IInjectableResource< CatXL > TestInjectableResource
void Test_Layer_CatXL_PUT_Nth_MaxValue()
void Test_Layer_DelayedPayment_PUT_Payments_Null()
void Test_Layer_DelayedPayment_PUT_Payments_ValidSpecialValues()
void Test_Layer_DelayedPayment_POST_Payments_OutOfOrder()
void Test_Layer_DelayedPayment_PUT_Payments_InvalidValues()
void Test_Layer_DelayedPayment_PUT_Payments_OutOfOrder()
void Test_Layer_DelayedPayment_POST_Payments_Empty()
void Test_Layer_DelayedPayment_POST_Payments_Null()
void Test_Layer_DelayedPayment_POST_Payments_InvalidValues()
override IInjectableResource< DelayedPayment > TestInjectableResource
void Test_Layer_DelayedPayment_PUT_Payments()
void Test_Layer_DelayedPayment_PUT_Payments_Empty()
void Test_Layer_DelayedPayment_PUT_Payments_Negative()
void Test_Layer_DelayedPayment_POST_Payments_Negative()
void Test_Layer_DelayedPayment_POST_Payments()
void Test_Layer_DelayedPayment_POST_Payments_ValidSpecialValues()
void Test_Layer_Filter_POST_Invert()
void Test_Layer_Filter_POST_Filters()
void Test_Layer_Filter_POST_Filters_Empty()
void Test_Layer_Filter_POST_Filters_Null()
override IInjectableResource< Filter > TestInjectableResource
override void Test_Resource_POST_FieldsIdOnly()
void Test_Layer_Filter_POST_Filters_NonExistantId()
override void Test_Resource_POST_Valid()
void Test_Layer_FixedDatePayment_POST_Payments_Null()
void Test_Layer_DelayedPayment_POST_PaymentDates()
void Test_Layer_DelayedPayment_PUT_PaymentDates_Empty()
void Test_Layer_DelayedPayment_POST_PaymentDates_InsufficientNumber()
void Test_Layer_FixedDatePayment_PUT_Payments_Negative()
void Test_Layer_DelayedPayment_PUT_PaymentDates_InsufficientNumber()
void Test_Layer_DelayedPayment_PUT_PaymentDates_OutOfOrder()
void Test_Layer_FixedDatePayment_POST_Payments_InvalidValues()
void Test_Layer_FixedDatePayment_PUT_Payments()
void Test_Layer_FixedDatePayment_PUT_Payments_ValidSpecialValues()
void Test_Layer_DelayedPayment_POST_PaymentDates_ValidSpecialValues()
override IInjectableResource< FixedDatePayment > TestInjectableResource
void Test_Layer_FixedDatePayment_POST_Payments_Negative()
void Test_Layer_FixedDatePayment_PUT_Payments_InvalidValues()
void Test_Layer_DelayedPayment_PUT_PaymentDates_Null()
void Test_Layer_DelayedPayment_PUT_PaymentDates_ValidSpecialValues()
void Test_Layer_FixedDatePayment_POST_Payments_Empty()
void Test_Layer_DelayedPayment_POST_PaymentDates_Null()
void Test_Layer_FixedDatePayment_POST_Payments()
void Test_Layer_FixedDatePayment_PUT_Payments_Null()
void Test_Layer_FixedDatePayment_PUT_Payments_Empty()
void Test_Layer_DelayedPayment_PUT_PaymentDates()
void Test_Layer_DelayedPayment_POST_PaymentDates_Empty()
void Test_Layer_DelayedPayment_POST_PaymentDates_OutOfOrder()
void Test_Layer_FixedDatePayment_POST_Payments_ValidSpecialValues()
void Test_Layer_FixedRateCurrencyConverter_POST_Rate_Negative()
void Test_Layer_FixedRateCurrencyConverter_POST_InCurrency_TooShort()
void Test_Layer_FixedRateCurrencyConverter_POST_OutCurrency_TooLong()
void Test_Layer_FixedRateCurrencyConverter_POST_OutCurrency_InvalidISO()
void Test_Layer_FixedRateCurrencyConverter_POST_OutCurrency_Empty()
void Test_Layer_FixedRateCurrencyConverter_POST_Rate()
void Test_Layer_FixedRateCurrencyConverter_POST_OutCurrency_TooShort()
void Test_Layer_FixedRateCurrencyConverter_POST_Rate_Zero()
void Test_Layer_FixedRateCurrencyConverter_POST_OutCurrency_Null()
void Test_Layer_FixedRateCurrencyConverter_POST_OutCurrency_ValidISO()
void Test_Layer_FixedRateCurrencyConverter_POST_InCurrency_InvalidCurrencyConversion()
void Test_Layer_FixedRateCurrencyConverter_POST_InCurrency_Null()
void Test_Layer_FixedRateCurrencyConverter_POST_InCurrency_ValidISO()
void Test_Layer_FixedRateCurrencyConverter_POST_InCurrency_InvalidISO()
void Test_Layer_FixedRateCurrencyConverter_POST_InCurrency_Empty()
override IInjectableResource< FixedRateCurrencyConverter > TestInjectableResource
void Test_Layer_FixedRateCurrencyConverter_POST_InCurrency_TooLong()
void Test_Layer_Generic_POST_Reinstatements_HighPrecision()
void Test_Layer_Generic_POST_Reinstatements_Infinity()
void Test_Layer_Generic_PUT_Reinstatements()
void Test_Layer_Generic_POST_Reinstatements_NegativeInfinity()
void Test_Layer_Generic_PUT_Reinstatements_Empty()
override IInjectableResource< Generic > TestInjectableResource
void Test_Layer_Generic_POST_Reinstatements_Empty()
void Test_Layer_Generic_POST_Reinstatements_MinValue()
void Test_Layer_Generic_POST_Reinstatements_Zero()
void Test_Layer_Generic_POST_Reinstatements_MaxValue()
void Test_Layer_Generic_POST_Reinstatements_NaN()
void Test_Layer_Generic_POST_Reinstatements_Null()
void Test_Layer_IndustryLossWarranty_POST_Payout_HighPrecision()
void Test_Layer_IndustryLossWarranty_POST_Trigger_Null()
void Test_Layer_IndustryLossWarranty_PUT_Nth_LessThanOne()
void Test_Layer_IndustryLossWarranty_POST_Nth_MaxValue()
void Test_Layer_IndustryLossWarranty_PUT_Nth_MinValue()
void Test_Layer_IndustryLossWarranty_POST_Payout_Null()
void Test_Layer_IndustryLossWarranty_POST_Trigger_HighPrecision()
void Test_Layer_IndustryLossWarranty_PUT_Payout_HighPrecision()
void Test_Layer_IndustryLossWarranty_PUT_Nth()
void Test_Layer_IndustryLossWarranty_POST_Nth_Null()
void Test_Layer_IndustryLossWarranty_PUT_Trigger_HighPrecision()
void Test_Layer_IndustryLossWarranty_PUT_Payout_Null()
void Test_Layer_IndustryLossWarranty_POST_Nth_MinValue()
void Test_Layer_IndustryLossWarranty_PUT_Nth_Null()
override IInjectableResource< IndustryLossWarranty > TestInjectableResource
void Test_Layer_IndustryLossWarranty_POST_Nth_LessThanOne()
void Test_Layer_IndustryLossWarranty_PUT_Trigger_Null()
void Test_Layer_IndustryLossWarranty_PUT_Nth_MaxValue()
void Test_Layer_LossRank_PUT_Count()
void Test_Layer_LossRank_PUT_Invert()
void Test_Layer_LossRank_POST_Count_LessThanMin()
void Test_Layer_LossRank_POST_Count_Max()
void Test_Layer_LossRank_POST_Count()
override IInjectableResource< LossRank > TestInjectableResource
void Test_Layer_LossRank_PUT_Count_Max()
void Test_Layer_LossRank_POST_Invert()
void Test_Layer_LossRank_POST_Count_Min()
void Test_Layer_LossRank_PUT_Count_Min()
void Test_Layer_Nested_PUT_Sources_Inlined()
void Test_Layer_Nested_POST_Sources_LayerViewReference()
void Test_Layer_Nested_POST_Sources_EveryType()
void Test_Layer_Nested_PUT_Sources_Empty()
void Test_Layer_Nested_PUT_Sink()
void Test_Layer_Nested_PUT_Sink_EveryType()
void Test_Layer_Nested_PUT_Sink_Null()
void Test_Layer_Nested_PUT_Sink_LayerViewReference()
void Test_Layer_Nested_PUT_Sink_Reference_NullId()
void Test_Layer_Nested_POST_Sources_Empty()
void Test_Layer_Nested_PUT_Sources()
static HashSet< Type > UnsupportedNestedSinkTypes
Types that cannot be the sink of a Nested layer.
void Test_Layer_Nested_POST_Sink_EveryType()
void Test_Layer_Nested_POST_Sink_InvalidType()
void Test_Layer_Nested_POST_Sink_Reference_NullId()
static IEnumerable< IInjectableResource< ILayer > > ForbiddenSinkLayerTypesTestList
A set of injectable test layers that are not valid to use as a sink.
void Test_Layer_Nested_POST_Sink_Reference_EmptyStringId()
void Test_Layer_Nested_PUT_Sink_Reference_EmptyStringId()
void Test_Layer_Nested_POST_Sink_Reference_NonExistantId()
void Test_Layer_Nested_POST_Sink_LayerViewReference()
void Test_Layer_Nested_POST_Sources_ContainsSink()
void Test_Layer_Nested_PUT_Sources_Invalid()
void Test_Layer_Nested_POST_Sources_Duplicates()
void Test_Layer_Nested_POST_Sink_Inlined()
static IEnumerable< IInjectableResource< ILayer > > ValidSinkLayerTypesTestList
A set of injectable test layers that are valid to use as a sink.
void Test_Layer_Nested_POST_Sources_Null()
void Test_Layer_Nested_POST_Sources_Inlined()
void Test_Layer_Nested_PUT_Sink_Reference_NonExistantId()
void Test_Layer_Nested_POST_Sink_Null()
void Test_Layer_Nested_PUT_Sources_Duplicates()
void Test_Layer_Nested_PUT_Sink_InvalidType()
void Test_Layer_Nested_POST_Sources_Invalid()
void Test_Layer_Nested_PUT_Sources_Null()
void Test_Layer_Nested_PUT_Sources_LayerViewReference()
void Test_Layer_Nested_PUT_Sources_EveryType()
void Test_Layer_Nested_PUT_Sink_Inlined()
override IInjectableResource< Nested > TestInjectableResource
void Test_Layer_POST_PayoutDate()
void Test_Layer_POST_PayoutDate_Null()
void TestSuite_Layer_NoClaimsBonus_POST_PayoutAmount_Null()
void Test_Layer_PUT_PayoutDate_MaxValue()
void Test_Layer_PUT_PayoutDate_MinValue()
void Test_Layer_PUT_PayoutDate()
void Test_Layer_POST_PayoutDate_MaxValue()
void Test_Layer_PUT_PayoutDate_Null()
void TestSuite_Layer_NoClaimsBonus_PUT_PayoutAmount_HighPrecision()
void TestSuite_Layer_NoClaimsBonus_POST_PayoutAmount_HighPrecision()
override IInjectableResource< NoClaimsBonus > TestInjectableResource
void Test_Layer_POST_PayoutDate_MinValue()
void TestSuite_Layer_NoClaimsBonus_PUT_PayoutAmount_Null()
Special case - for simplicity, AggregateQuotaShare layer inherits from QuotaShare.
virtual void Test_Layer_QuotaShare_POST_EventLimit_Null()
virtual void Test_Layer_QuotaShare_PUT_EventLimit_Null()
virtual void Test_Layer_QuotaShare_PUT_EventLimit_HighPrecision()
virtual void Test_Layer_QuotaShare_POST_EventLimit_HighPrecision()
override IInjectableResource< QuotaShare > TestInjectableResource
void Test_Layer_SurplusShare_PUT_RetainedLine_Null()
void Test_Layer_SurplusShare_POST_NumberOfLines_MaxValue()
void Test_Layer_SurplusShare_NegativeParticipation()
override void Test_Layer_POST_Participation_Infinity()
void Test_Layer_SurplusShare_Participation_CientSide()
void Test_Layer_SurplusShare_PUT_SumsInsured_Null()
void Test_Layer_SurplusShare_POST_NumberOfLines_Infinity()
override IInjectableResource< SurplusShare > TestInjectableResource
void Test_Layer_SurplusShare_POST_NumberOfLines_MinValue()
override void Test_Layer_POST_Participation_HighPrecision()
void Test_Layer_SurplusShare_POST_RetainedLine_Null()
void Test_Layer_SurplusShare_POST_SumsInsured_Negative()
void Test_Layer_SurplusShare_PUT_NumberOfLines()
override void Test_Layer_POST_Participation_NegativeInfinity()
void Test_Layer_SurplusShare_POST_RetainedLine_HighPrecision()
void Test_Layer_SurplusShare_POST_NumberOfLines_HighPrecision()
void Test_Layer_SurplusShare_Participation_NoSet()
override void Test_Layer_PUT_Participation()
void Test_Layer_SurplusShare_PUT_RetainedLine_HighPrecision()
override void Test_Layer_POST_Participation_MinValue()
void Test_Layer_SurplusShare_POST_SumsInsured_HighPrecision()
void Test_Layer_SurplusShare_Participation_ServerSide()
void Test_Layer_SurplusShare_POST_SumsInsured_Null()
override void Test_Layer_POST_Participation_NaN()
override void Test_Layer_POST_Participation_MaxValue()
void Test_Layer_SurplusShare_POST_NumberOfLines_NaN()
void Test_Layer_SurplusShare_PUT_SumsInsured_HighPrecision()
void Test_Layer_SurplusShare_POST_NumberOfLines_NegativeInfinity()
Special case - certain layer types do not currently support being saved (See ARE-3360)....
override void Test_Resource_GET_FromBatch()
Test that resources of this type can be retrieved using the collection batch-get feature.
override void Test_Layer_WithLossSets_PUT_Policy_TransformAll()
override void Test_Resource_PUT_Metadata_Null()
override void Test_Resource_PUT_Description_Null()
override void Test_Layer_WithLossSets_PUT_LossSets_Invalid()
override void Test_Resource_PUT_Metadata_InvalidValues()
override void Test_Resource_POST_CreatedAndModified()
override void Test_Resource_POST_ExistingId()
Verifies that it is okay to post an object with an ID that already exists on the server,...
override void Test_Resource_PUT_Metadata_MixedTypes()
override void Test_Layer_WithLossSets_PUT_Policy_Empty()
override void Test_Layer_WithLossSets_PUT_LossSets()
override void Test_Layer_WithLossSets_PUT_LossSet_NotFinalized()
override void Test_Layer_Saveable()
As a sanity check, layers that are saveable should not carry the NotSaveableAttribute....
override void Test_Resource_GET_Existing()
override void Test_Layer_WithLossSets_PUT_Policy()
override void Test_Layer_WithLossSets_PUT_LossSets_Empty()
override void Test_Resource_PUT_NoChanges()
override void Test_Layer_WithLossSets_PUT_Policy_ForwardAll()
override void Test_Resource_PUT_Metadata_Empty()
override void Test_Resource_DELETE()
override void Test_Resource_GET_Existing_ResolveReferences()
IStoredAPIResource collections support reference resolution.
override void Test_Resource_PUT_Description()
override void Test_Resource_PUT_Description_Blank()
override void Test_Resource_POST_Valid()
override void Test_Resource_PUT_CreatedAndModified()
override void Test_Resource_Search()
All resources should support searching in a few fundamental ways.
override void Test_Layer_WithLossSets_PUT_Policy_Duplicates()
override void Test_Resource_POST_Id_Ignored()
No matter what string we set the Id property to, POST should succeed because the Id of the posted res...
override void Test_Layer_WithLossSets_PUT_LossSets_Duplicates()
void Test_Layer_ValueAllocator_PUT_Target_Reference_NullId()
void Test_Layer_ValueAllocator_PUT_Target_Reference_EmptyStringId()
void Test_Layer_ValueAllocator_PUT_AllocationPerspective_Empty()
void Test_Layer_ValueAllocator_PUT_Source_Reference_NullId()
override IInjectableResource< ValueAllocator > TestInjectableResource
void Test_Layer_ValueAllocator_POST_Source_Inlined()
void Test_Layer_ValueAllocator_POST_ProportionedPerspective_Null()
void Test_Layer_ValueAllocator_POST_Target_Null()
void Test_Layer_ValueAllocator_POST_Group_Inlined()
void Test_Layer_ValueAllocator_POST_Target_LayerViewReference()
void Test_Layer_ValueAllocator_POST_Source_EveryType()
void Test_Layer_ValueAllocator_PUT_Source()
void Test_Layer_ValueAllocator_POST_Group_LayerViewReference()
void Test_Layer_ValueAllocator_PUT_Target_EveryType()
void Test_Layer_ValueAllocator_PUT_Group_Reference_EmptyStringId()
void Test_Layer_ValueAllocator_POST_Source_LayerViewReference()
void Test_Layer_ValueAllocator_PUT_AllocationRatioBasis_PossibleValues()
void Test_Layer_ValueAllocator_PUT_Group_EveryType()
void Test_Layer_ValueAllocator_PUT_Source_EveryType()
void Test_Layer_ValueAllocator_PUT_ProportionedPerspective_Null()
void Test_Layer_ValueAllocator_POST_Group_Reference_EmptyStringId()
void Test_Layer_ValueAllocator_PUT_Source_LayerViewReference()
void Test_Layer_ValueAllocator_POST_Group_Reference_NullId()
void Test_Layer_ValueAllocator_POST_Source_Reference_NonExistantId()
void Test_Layer_ValueAllocator_POST_AllocationRatioBasis_PossibleValues()
void Test_Layer_ValueAllocator_POST_Target_EveryType()
void Test_Layer_ValueAllocator_PUT_Group_Reference_NullId()
void Test_Layer_ValueAllocator_PUT_Target_LayerViewReference()
void Test_Layer_ValueAllocator_PUT_Source_Reference_NonExistantId()
void Test_Layer_ValueAllocator_POST_Target_Reference_EmptyStringId()
void Test_Layer_ValueAllocator_POST_AllocationPerspective_EveryPerspective()
void Test_Layer_ValueAllocator_POST_AllocationRationBasis_Null()
void Test_Layer_ValueAllocator_POST_Group_Null()
void Test_Layer_ValueAllocator_PUT_AllocationPerspective_EveryPerspective()
void Test_Layer_ValueAllocator_PUT_AllocationPerspective_Duplicates()
void Test_Layer_ValueAllocator_PUT_AllocationRationBasis_Null()
void Test_Layer_ValueAllocator_PUT_Target_Reference_NonExistantId()
void Test_Layer_ValueAllocator_PUT_Source_Inlined()
void Test_Layer_ValueAllocator_PUT_ProportionedPerspective_EveryPerspective()
void Test_Layer_ValueAllocator_POST_Source_Null()
void Test_Layer_ValueAllocator_POST_AllocationPerspective_Null()
void Test_Layer_ValueAllocator_PUT_Target()
void Test_Layer_ValueAllocator_PUT_Group()
void Test_Layer_ValueAllocator_PUT_Source_Null()
void Test_Layer_ValueAllocator_PUT_Group_Null()
void Test_Layer_ValueAllocator_POST_Target_Reference_NonExistantId()
void Test_Layer_ValueAllocator_POST_Group_EveryType()
void Test_Layer_ValueAllocator_PUT_Group_LayerViewReference()
void Test_Layer_ValueAllocator_PUT_Source_Reference_EmptyStringId()
void Test_Layer_ValueAllocator_POST_Target_Inlined()
void Test_Layer_ValueAllocator_POST_Target_Reference_NullId()
void Test_Layer_ValueAllocator_POST_ProportionedPerspective_EveryPerspective()
void Test_Layer_ValueAllocator_PUT_Group_Reference_NonExistantId()
void Test_Layer_ValueAllocator_PUT_AllocationPerspective_Null()
void Test_Layer_ValueAllocator_PUT_Target_Inlined()
void Test_Layer_ValueAllocator_POST_Source_Reference_EmptyStringId()
void Test_Layer_ValueAllocator_POST_AllocationPerspective_Duplicates()
void Test_Layer_ValueAllocator_POST_Group_Reference_NonExistantId()
void Test_Layer_ValueAllocator_PUT_Target_Null()
void Test_Layer_ValueAllocator_POST_AllocationPerspective_Empty()
void Test_Layer_ValueAllocator_POST_Source_Reference_NullId()
void Test_Layer_ValueAllocator_PUT_Group_Inlined()
virtual void Test_Layer_WithLossSets_POST_LossSets_Invalid()
virtual void Test_Layer_WithLossSets_PUT_LossSets_Invalid()
virtual void Test_Layer_WithLossSets_POST_Policy_TransformAll()
virtual void Test_Layer_WithLossSets_POST_Policy_ForwardAll()
virtual void Test_Layer_WithLossSets_POST_LossSets_Empty()
virtual void Test_Layer_WithLossSets_PUT_Policy_Duplicates()
virtual void Test_Layer_WithLossSets_POST_Policy_Empty()
virtual void Test_Layer_WithLossSets_PUT_Policy_Empty()
virtual void Test_Layer_WithLossSets_POST_LossSets_Null()
virtual void Test_Layer_WithLossSets_PUT_LossSet_NotFinalized()
virtual void Test_Layer_WithLossSets_POST_LossSets_Duplicates()
virtual void Test_Layer_WithLossSets_PUT_Policy()
virtual void Test_Layer_WithLossSets_PUT_Policy_ForwardAll()
virtual void Test_Layer_WithLossSets_POST_LossSet_NotFinalized()
virtual void Test_Layer_WithLossSets_POST_Policy_Duplicates()
virtual void Test_Layer_WithLossSets_POST_Policy_Null()
virtual void Test_Layer_WithLossSets_PUT_LossSets_Empty()
virtual void Test_Layer_WithLossSets_PUT_LossSets_Duplicates()
virtual void Test_Layer_WithLossSets_PUT_Policy_TransformAll()
virtual void Test_Layer_WithLossSets_PUT_LossSets()
virtual void Test_Layer_POST_Fee_BadPremiumReference()
virtual void Test_Layer_POST_Participation_NegativeInfinity()
virtual void Test_Layer_POST_Fee_BadFeeReference()
virtual void Test_Layer_PUT_Premium_Null()
virtual void Test_Layer_POST_Fee_SelfFeeReference()
virtual void Test_Layer_POST_Participation_Infinity()
virtual void Test_Layer_POST_Fee_CircularFeeReference()
virtual void Test_Layer_PUT_ExpiryDate()
virtual void Test_Layer_POST_Premium_HighPrecision()
virtual void Test_Layer_POST_Participation_HighPrecision()
virtual void Test_Layer_POST_Participation_NaN()
virtual void Test_Layer_POST_ExpiryDate_LessThanInception()
virtual void Test_Layer_POST_Fee_Bad_Brokerage_Reference()
virtual void Test_Layer_POST_Inception_Null()
virtual void Test_Layer_POST_InceptionExpiryDate_MaxValue()
virtual void Test_Layer_PUT_InceptionDate()
virtual void Test_Layer_POST_Expiry_Null()
virtual void Test_Layer_POST_Participation_MaxValue()
virtual void Test_Layer_POST_InceptionExpiryDate_MinValue()
virtual void Test_Layer_PUT_Inception_Null()
virtual void Test_Layer_PUT_Participation()
virtual void Test_Layer_PUT_Expiry_Null()
virtual void Test_Layer_POST_EachFee()
virtual void Test_Layer_PUT_ExpiryDate_LessThanInception()
virtual void Test_Layer_PUT_InceptionExpiryDate_MaxValue()
virtual void Test_Layer_POST_Fee_BadLossesReference()
virtual void Test_Layer_POST_Fees_Many()
virtual void Test_Layer_POST_Fees_Null()
virtual void Test_Layer_POST_Participation_MinValue()
virtual void Test_Layer_PUT_InceptionExpiryDate_MinValue()
virtual void Test_Layer_POST_Premium_Null()
virtual void Test_Layer_POST_Fees_Empty()
virtual void Test_Layer_PUT_Premium_HighPrecision()
virtual void Test_Layer_POST_Fee_Good_Brokerage_Reference()
virtual void Test_Layer_XL_POST_Franchise_Null()
virtual void Test_Layer_XL_POST_Limit_HighPrecision()
virtual void Test_Layer_XL_PUT_Limit_HighPrecision()
virtual void Test_Layer_XL_PUT_Limit_Null()
virtual void Test_Layer_XL_POST_Franchise_HighPrecision()
virtual void Test_Layer_XL_POST_Attachment_HighPrecision()
virtual void Test_Layer_XL_PUT_Attachment_HighPrecision()
virtual void Test_Layer_XL_PUT_Franchise_Null()
virtual void Test_Layer_XL_POST_Limit_Null()
virtual void Test_Layer_XL_POST_Attachment_Null()
virtual void Test_Layer_XL_PUT_Attachment_Null()
virtual void Test_Layer_XL_PUT_Franchise_HighPrecision()
virtual void Test_Resource_GET_As_Inlined()
override void Test_Resource_GET_AllPropertiesRecognized()
override void Test_Resource_POST_FieldsIdOnly()
Test that a user can post a resource and get back only the id using the omit query parameter.
override void Test_Resource_ShallowCopy()
Test that any resource can be "Shallow Copied", which is a quick copy that does a member-wise clone o...
override void Test_Resource_DeepCopy()
Test that any resource can be "Deep Copied", a slower copy method that creates a new duplicate instan...
override void AdditionalValidResourceTests(T posted)
For all tests, we want to test success both when the layer is posted on its own, and when it's posted...
virtual void Test_Layer_Saveable()
As a sanity check, layers that are saveable should not carry the NotSaveableAttribute....
static void DoublesAreEqual(double expected, double actual, Func< string > message, double? relative_tolerance=null)
Determines if two doubles are equivalent within the accepted tolerance.
Retrieve settings from environment variables if they exist, or the project settings file otherwise.
static bool RUN_OFFLINE
Controls whether tests that normally require a connection to the server should be allowed to try to r...
Generic Unit test implementations that will test REST methods on arbitrary resources.
A collection of filthy hacks to populate some fields of APIResources objects of any type.
string PickBackAllocatedLayerSourceId(IReference< ILayerSource > sinkReference)
Finds a random source loss set or layer_view id within the specified sinkReference which can be used...
A helper class containing default skip dates.
static void Validation(string ticket=null)
Skip a test due to a validation-related issue, possibly with no insight into when this issue is likel...
Class used in unit tests to mark tests as skipped by using Assert.Inconclusive() method.
static void Indefinitely(string ticket=null)
Skip the specified test.
Describes a collection of resources which can be listed.
API methods / requests made available to the user.
static readonly ResourceCollection< ILayer > Layers
The collection of Layers on the server.
Indicates that while the current APIResource-derived class can be constructed and potentially inlined...
Specifies one or more aliases to be used as synonyms for the property's name.
string[] Aliases
The aliases associated with this property.
Represents a reference, used in Fee objects.
static FeeReference CreateFromFeeName(string name)
Create a reference to a Fee from its name.
Abstract representation of a fee. This resource type cannot be instantiated instead derived resource ...
The Profit Commission applies a fee that is the sum of the premium sources minus the sum of loss and ...
Abstract representation of a layer. This resource type cannot be instantiated instead derived resourc...
Representation of an Aggregate Catastrophe Excess of Loss layer.
Acts as a replacement for IAPIResourceView.back_allocations. Computes the proportion of some sink str...
A "delayed payment" payment pattern models claims being paid in instalments at fixed delays after the...
A "delayed payment" payment pattern models claims being paid in instalments at specific dates followi...
A structure that can be used to change the currency of a loss stream from one currency to another at ...
Abstract representation of a layer. This resource type cannot be instantiated instead derived resourc...
Abstract representation of a layer. This resource type cannot be instantiated instead derived resourc...
Abstract representation of a base Excess of Loss layer.
A wrapper for a List<T> of IReference<ILayerSource> references that simplifies the construction and u...
Allows one or more source layers or layer_views to be attached as loss sources to some other layer de...
Layer Policy is the rule on RecordType that determines how occurrences belonging to a particular Reco...
Representation of a Quota Share contract.
Represents a reinstatement premium and brokerage amount.
Representation of a Surplus Share contract.
Surfaces the value-allocator specialty structure (which is treated as a "layer definition" by the API...
Perspective
The loss perspectives that can be used when computing proportions (proportioned_perspective) and allo...
AllocationRatioBasis
Dictates how value allocator layer should allocate losses per event or per trial.
Base class for all LossSet sub-types. A LossSet is a resource that generates sample (trial) losses wh...
Representation of a single loss set with an associated event loss table.
Representation of a monetary value with a currency.
IReference< T > AsReference
A reference to the posted resource.
T Unposted
The unPOSTed resource definition.
T Posted
The posted resource, ready to be referenced.
Abstract representation of a layer.
Abstract representation of a layer with terms.
double participation
The amount of participation of the reinsurer in this deal as the percentage of loss,...
RecordType
The type of occurrence.