This is an automated email from the ASF dual-hosted git repository.

ptupitsyn pushed a commit to branch ignite-27278
in repository https://gitbox.apache.org/repos/asf/ignite-3.git


The following commit(s) were added to refs/heads/ignite-27278 by this push:
     new d9684225ce6 wip PA tests
d9684225ce6 is described below

commit d9684225ce61f0e4df8e42b6d3714d958bbddde4
Author: Pavel Tupitsyn <[email protected]>
AuthorDate: Wed Dec 24 14:06:58 2025 +0200

    wip PA tests
---
 .../Apache.Ignite.Tests/PartitionAwarenessTests.cs  | 21 +++++++++++++++++++--
 1 file changed, 19 insertions(+), 2 deletions(-)

diff --git 
a/modules/platforms/dotnet/Apache.Ignite.Tests/PartitionAwarenessTests.cs 
b/modules/platforms/dotnet/Apache.Ignite.Tests/PartitionAwarenessTests.cs
index ae7d446220d..6f6d2e39377 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Tests/PartitionAwarenessTests.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Tests/PartitionAwarenessTests.cs
@@ -24,6 +24,7 @@ using System.Threading.Channels;
 using System.Threading.Tasks;
 using Ignite.Compute;
 using Ignite.Table;
+using Ignite.Table.Mapper;
 using Ignite.Transactions;
 using Internal.Proto;
 using Internal.Transactions;
@@ -320,10 +321,14 @@ public class PartitionAwarenessTests
     }
 
     [Test]
-    public async Task TestCompositeKey()
+    public async Task TestCompositeKey([Values(true, false)] bool withMapper)
     {
         using var client = await GetClient();
-        var view = (await 
client.Tables.GetTableAsync(FakeServer.CompositeKeyTableName))!.GetRecordView<CompositeKey>();
+
+        var table = await 
client.Tables.GetTableAsync(FakeServer.CompositeKeyTableName);
+        var view = withMapper
+            ? table!.GetRecordView(new CompositeKeyMapper())
+            : table!.GetRecordView<CompositeKey>();
 
         await view.UpsertAsync(null, new CompositeKey("1", Guid.Empty)); // 
Warm up.
 
@@ -526,4 +531,16 @@ public class PartitionAwarenessTests
     private record CompositeKey(string IdStr, Guid IdGuid);
 
     private record SimpleKey(int Id);
+
+    private sealed class CompositeKeyMapper : IMapper<CompositeKey>
+    {
+        public void Write(CompositeKey obj, ref RowWriter rowWriter, 
IMapperSchema schema)
+        {
+            rowWriter.WriteString(obj.IdStr);
+            rowWriter.WriteGuid(obj.IdGuid);
+        }
+
+        public CompositeKey Read(ref RowReader rowReader, IMapperSchema 
schema) =>
+            new(rowReader.ReadString()!, rowReader.ReadGuid()!.Value);
+    }
 }

Reply via email to