Mercurial > hg > Database > jungle-network
comparison src/test/alice/jungle/core/operations/NetworkDeleteAttributeOprationTest.java @ 72:2520a5bd3dac
Added NetworkDeleteAttributeOperation and NetworkDeleteAttributeOperationTest
author | one |
---|---|
date | Tue, 15 Oct 2013 09:13:18 +0900 |
parents | |
children | 19e278488b42 |
comparison
equal
deleted
inserted
replaced
71:f1aef52c0611 | 72:2520a5bd3dac |
---|---|
1 package test.alice.jungle.core.operations; | |
2 | |
3 import java.io.IOException; | |
4 | |
5 import org.msgpack.MessagePack; | |
6 import org.msgpack.type.Value; | |
7 | |
8 import alice.jungle.operations.NetworkDeleteAttributeOperation; | |
9 import junit.framework.TestCase; | |
10 | |
11 public class NetworkDeleteAttributeOprationTest extends TestCase { | |
12 | |
13 public void testMsgpackConvert() throws IOException { | |
14 NetworkDeleteAttributeOperation op = new NetworkDeleteAttributeOperation("hoge"); | |
15 MessagePack msgpack = new MessagePack(); | |
16 Value v = msgpack.unconvert(op); | |
17 NetworkDeleteAttributeOperation mOp = msgpack.convert(v, NetworkDeleteAttributeOperation.class); | |
18 assertEquals(op.getCommand(), mOp.getCommand()); | |
19 assertEquals(mOp.getKey(), "hoge"); | |
20 | |
21 } | |
22 | |
23 | |
24 } |