Skip to content
This repository was archived by the owner on Aug 17, 2019. It is now read-only.

Commit 324e359

Browse files
committed
Remove commented and unused code
1 parent 1aa7b3c commit 324e359

File tree

1 file changed

+0
-30
lines changed

1 file changed

+0
-30
lines changed

Diff for: src/test/scala/com/ckkloverdos/maybe/MaybeTest.scala

-30
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ package com.ckkloverdos.maybe
1818

1919
import org.junit.Assert
2020
import org.junit.Test
21-
import java.io.{ByteArrayInputStream, ObjectInputStream, ByteArrayOutputStream, ObjectOutputStream}
2221

2322
/**
2423
*
@@ -117,33 +116,4 @@ class MaybeTest {
117116
Assert.assertEquals(true, _flag1)
118117
Assert.assertEquals(true, _flag2)
119118
}
120-
121-
private def serializeAndRead[A <: AnyRef](inObj: A): A = {
122-
val bytesOut = new ByteArrayOutputStream()
123-
val outStream = new ObjectOutputStream(bytesOut)
124-
outStream.writeObject(inObj)
125-
outStream.close()
126-
val bytesIn = new ByteArrayInputStream(bytesOut.toByteArray)
127-
val inStream = new ObjectInputStream(bytesIn)
128-
val outObj = inStream.readObject()
129-
inStream.close()
130-
outObj.asInstanceOf[A]
131-
}
132-
133-
// @Test
134-
// def testSerializeJust: Unit = {
135-
// Assert.assertEquals(Just(5), serializeAndRead(Just(5)))
136-
// }
137-
138-
// @Test
139-
// def testSerializeNoVal: Unit = {
140-
// Assert.assertTrue(NoVal eq serializeAndRead(NoVal))
141-
// }
142-
143-
// @Test
144-
// def testSerializeFailed: Unit = {
145-
// val failedIn = Maybe { throw new Exception("Really!!") }
146-
// val failedOut = serializeAndRead(failedIn)
147-
// Assert.assertEquals(failedIn, failedOut)
148-
// }
149119
}

0 commit comments

Comments
 (0)