@@ -679,7 +679,7 @@ public void TestPartialUpdateOperation_Increment()
679
679
680
680
[ Test ]
681
681
[ Parallelizable ]
682
- public void TestPartialUpdateOperation_IncrementFrom ( )
682
+ public void TestPartialUpdateOperation_IncrementFrom_int ( )
683
683
{
684
684
RecordWithPartialUpdateOperation < int > record = new RecordWithPartialUpdateOperation < int >
685
685
{
@@ -693,7 +693,21 @@ public void TestPartialUpdateOperation_IncrementFrom()
693
693
694
694
[ Test ]
695
695
[ Parallelizable ]
696
- public void TestPartialUpdateOperation_IncrementSet ( )
696
+ public void TestPartialUpdateOperation_IncrementFrom_long ( )
697
+ {
698
+ RecordWithPartialUpdateOperation < long > record = new RecordWithPartialUpdateOperation < long >
699
+ {
700
+ ObjectID = "myID" ,
701
+ Update = PartialUpdateOperation < long > . IncrementFrom ( ( long ) 2 ) ,
702
+ } ;
703
+
704
+ string json = JsonConvert . SerializeObject ( record , JsonConfig . AlgoliaJsonSerializerSettings ) ;
705
+ Assert . AreEqual ( json , "{\" objectID\" :\" myID\" ,\" update\" :{\" _operation\" :\" IncrementFrom\" ,\" value\" :2}}" ) ;
706
+ }
707
+
708
+ [ Test ]
709
+ [ Parallelizable ]
710
+ public void TestPartialUpdateOperation_IncrementSet_int ( )
697
711
{
698
712
RecordWithPartialUpdateOperation < int > record = new RecordWithPartialUpdateOperation < int >
699
713
{
@@ -705,6 +719,20 @@ public void TestPartialUpdateOperation_IncrementSet()
705
719
Assert . AreEqual ( json , "{\" objectID\" :\" myID\" ,\" update\" :{\" _operation\" :\" IncrementSet\" ,\" value\" :2}}" ) ;
706
720
}
707
721
722
+ [ Test ]
723
+ [ Parallelizable ]
724
+ public void TestPartialUpdateOperation_IncrementSet_long ( )
725
+ {
726
+ RecordWithPartialUpdateOperation < long > record = new RecordWithPartialUpdateOperation < long >
727
+ {
728
+ ObjectID = "myID" ,
729
+ Update = PartialUpdateOperation < long > . IncrementSet ( ( long ) 2 ) ,
730
+ } ;
731
+
732
+ string json = JsonConvert . SerializeObject ( record , JsonConfig . AlgoliaJsonSerializerSettings ) ;
733
+ Assert . AreEqual ( json , "{\" objectID\" :\" myID\" ,\" update\" :{\" _operation\" :\" IncrementSet\" ,\" value\" :2}}" ) ;
734
+ }
735
+
708
736
[ Test ]
709
737
[ Parallelizable ]
710
738
public void TestPartialUpdateOperation_Decrement ( )
0 commit comments