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

pandalee pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fory.git


The following commit(s) were added to refs/heads/main by this push:
     new a66424abd chore(Scala): refactor scala test so it asserts something 
(#2390)
a66424abd is described below

commit a66424abdb4d2c9d92f31694e50db71cd6538274
Author: PJ Fanning <[email protected]>
AuthorDate: Sun Jul 6 17:13:52 2025 +0100

    chore(Scala): refactor scala test so it asserts something (#2390)
    
    I presume the test used to fail with an exception but now it passes, it
    is better not to have printlns and to actually compare the result of the
    deserialization to the original.
---
 .../src/test/scala/org/apache/fory/serializer/scala/ScalaTest.scala  | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git 
a/scala/src/test/scala/org/apache/fory/serializer/scala/ScalaTest.scala 
b/scala/src/test/scala/org/apache/fory/serializer/scala/ScalaTest.scala
index 056fce086..220d366d3 100644
--- a/scala/src/test/scala/org/apache/fory/serializer/scala/ScalaTest.scala
+++ b/scala/src/test/scala/org/apache/fory/serializer/scala/ScalaTest.scala
@@ -89,5 +89,8 @@ object PkgObjectMain2 extends App {
 
   case class SomeClass(v: List[IdAnyVal])
   val p = SomeClass(List.empty)
-  println(fory.deserialize(fory.serialize(p)))
+  val result = fory.deserialize(fory.serialize(p))
+  if (result != p) {
+    throw new RuntimeException(s"$result is not equal to $p")
+  }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to