.NET API
VoiceSessionStoreContract
Tracon.Testing.Contracts.Xunit.dllBehavior tests for the IVoiceSessionStore contract.
public abstract class VoiceSessionStoreContract : TenantIsolationContract<IVoiceSessionStore>, IAsyncLifetime, IAsyncDisposableInheritance
Section titled “Inheritance”object ← TenantIsolationContract<IVoiceSessionStore> ← VoiceSessionStoreContract
Implements
Section titled “Implements”IAsyncLifetime, IAsyncDisposable
Inherited Members
Section titled “Inherited Members”TenantIsolationContract<IVoiceSessionStore>.TenantA, TenantIsolationContract<IVoiceSessionStore>.TenantB, TenantIsolationContract<IVoiceSessionStore>.CreateStoreAsync(), TenantIsolationContract<IVoiceSessionStore>.UseAmbientTenant(MutableTenantContext), TenantIsolationContract<IVoiceSessionStore>.InitializeAsync(), TenantIsolationContract<IVoiceSessionStore>.DisposeAsync(), TenantIsolationContract<IVoiceSessionStore>.OnDisposeAsync(), TenantIsolationContract<IVoiceSessionStore>.SeedAsync(string, string), TenantIsolationContract<IVoiceSessionStore>.ExistsAsync(string, object), TenantIsolationContract<IVoiceSessionStore>.CountAsync(string), TenantIsolationContract<IVoiceSessionStore>.TryDeleteAsync(string, object), TenantIsolationContract<IVoiceSessionStore>.TryOverwriteAsync(string, string), TenantIsolationContract<IVoiceSessionStore>.Tenant_cannot_read_another_tenants_record(), TenantIsolationContract<IVoiceSessionStore>.Tenant_reads_its_own_record(), TenantIsolationContract<IVoiceSessionStore>.Tenant_does_not_see_another_tenants_record_in_the_list(), TenantIsolationContract<IVoiceSessionStore>.Tenant_cannot_delete_another_tenants_record(), TenantIsolationContract<IVoiceSessionStore>.Same_name_lives_independently_across_two_tenants(), TenantIsolationContract<IVoiceSessionStore>.AmbientTenant, TenantIsolationContract<IVoiceSessionStore>.Store, object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Remarks
Section titled “Remarks”The in-memory store and the three SQL providers must pass the same
scenarios. Two rules are critical: a second write with the same ID
updates the record (a call is first opened, then
closed), and input_seconds does not lose its
decimal fraction.
Constructors
Section titled “Constructors”VoiceSessionStoreContract()
Section titled “ VoiceSessionStoreContract()”protected VoiceSessionStoreContract()Methods
Section titled “Methods”Agent_and_session_filters_work()
Section titled “ Agent_and_session_filters_work()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 177)]public Task Agent_and_session_filters_work()Returns
Section titled “Returns”Another_tenants_record_is_not_visible()
Section titled “ Another_tenants_record_is_not_visible()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 167)]public Task Another_tenants_record_is_not_visible()Returns
Section titled “Returns”CountAsync(string)
Section titled “ CountAsync(string)”Reports how many records the given tenant sees through the listing endpoint.
protected override ValueTask<int> CountAsync(string tenantId)Parameters
Section titled “Parameters”tenantId string
The reading tenant.
Returns
Section titled “Returns”The number of records seen.
Duration_does_NOT_lose_its_decimal_fraction()
Section titled “ Duration_does_NOT_lose_its_decimal_fraction()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 53)]public Task Duration_does_NOT_lose_its_decimal_fraction()Returns
Section titled “Returns”ExistsAsync(string, object)
Section titled “ ExistsAsync(string, object)”Reports whether the record is visible from the given tenant’s viewpoint.
protected override ValueTask<bool> ExistsAsync(string tenantId, object key)Parameters
Section titled “Parameters”tenantId string
The reading tenant.
key object
The key returned by TenantIsolationContract.SeedAsync.
Returns
Section titled “Returns”true if the record is visible.
List_is_ordered_newest_to_oldest()
Section titled “ List_is_ordered_newest_to_oldest()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 195)]public Task List_is_ordered_newest_to_oldest()Returns
Section titled “Returns”Live_session_provider_model_and_cost_round_trip()
Section titled “ Live_session_provider_model_and_cost_round_trip()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 80)]public Task Live_session_provider_model_and_cost_round_trip()Returns
Section titled “Returns”Missing_measurement_stays_null_NOT_zero()
Section titled “ Missing_measurement_stays_null_NOT_zero()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 66)]public Task Missing_measurement_stays_null_NOT_zero()Returns
Section titled “Returns”Paging_is_applied()
Section titled “ Paging_is_applied()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 209)]public Task Paging_is_applied()Returns
Section titled “Returns”Saved_call_is_read_back()
Section titled “ Saved_call_is_read_back()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 35)]public Task Saved_call_is_read_back()Returns
Section titled “Returns”Second_write_with_the_same_id_UPDATES_the_record()
Section titled “ Second_write_with_the_same_id_UPDATES_the_record()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 146)]public Task Second_write_with_the_same_id_UPDATES_the_record()Returns
Section titled “Returns”SeedAsync(string, string)
Section titled “ SeedAsync(string, string)”Writes a sample record for the given tenant.
protected override ValueTask<object> SeedAsync(string tenantId, string name)Parameters
Section titled “Parameters”tenantId string
The tenant that owns the record.
name string
The name distinguishing the record. The same name may be used by two tenants.
Returns
Section titled “Returns”The key to use for reading the record back.
The_two_new_end_reasons_round_trip()
Section titled “ The_two_new_end_reasons_round_trip()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 127)]public Task The_two_new_end_reasons_round_trip()Returns
Section titled “Returns”Unpriced_live_session_reads_back_with_a_null_cost_NOT_a_zero()
Section titled “ Unpriced_live_session_reads_back_with_a_null_cost_NOT_a_zero()”[Fact("/Users/farukatasoy/Desktop/projects/Tracon/src/Tracon.Testing.Contracts.Xunit/Contracts/VoiceSessionStoreContract.cs", 108)]public Task Unpriced_live_session_reads_back_with_a_null_cost_NOT_a_zero()