Upgraded to Multiverse 0.4 and its 2PC CommitBarriers, all tests pass
This commit is contained in:
parent
28c6cc7b54
commit
21c53c2ffd
16 changed files with 259 additions and 234 deletions
|
|
@ -7,18 +7,23 @@ import org.scalatest.junit.JUnitRunner
|
|||
import org.scalatest.matchers.MustMatchers
|
||||
import org.junit.{Test}
|
||||
|
||||
/*
|
||||
@RunWith(classOf[JUnitRunner])
|
||||
class AgentTest extends junit.framework.TestCase with Suite with MustMatchers with ActorTestUtil with Logging {
|
||||
@Test def testAgent = verify(new TestActor {
|
||||
def test = {
|
||||
val t = Agent(5)
|
||||
handle(t){
|
||||
t.update( _ + 1 )
|
||||
t.update( _ * 2 )
|
||||
|
||||
val r = t()
|
||||
r must be (12)
|
||||
}
|
||||
}
|
||||
@Test def testAgent = verify(new TestActor {
|
||||
def test = {
|
||||
atomic {
|
||||
val t = Agent(5)
|
||||
handle(t) {
|
||||
t.update(_ + 1)
|
||||
t.update(_ * 2)
|
||||
|
||||
val r = t()
|
||||
r must be(12)
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
*/
|
||||
Loading…
Add table
Add a link
Reference in a new issue