Last change
on this file since 3368 was
3368,
checked in by g.georgovassilis@mpi.nl, 11 years ago
|
#269 BaseRemoteService? abstracts HTTP communication away for XML services, added facility for mocking services in unit tests, moved tests into src/test
|
-
Property svn:mime-type set to
text/plain
|
File size:
747 bytes
|
Line | |
---|
1 | package clarin.cmdi.componentregistry.editor.model { |
---|
2 | import flexunit.framework.TestCase; |
---|
3 | import flexunit.framework.TestSuite; |
---|
4 | |
---|
5 | public class CMDSpecTest extends TestCase { |
---|
6 | public function CMDSpecTest() { |
---|
7 | super(); |
---|
8 | } |
---|
9 | |
---|
10 | public static function suite():TestSuite { |
---|
11 | return new TestSuite(CMDSpecTest); |
---|
12 | } |
---|
13 | |
---|
14 | public function testToXml():void { |
---|
15 | var comp:CMDSpec = new CMDSpec(true); |
---|
16 | comp.headerName = "aap"; |
---|
17 | comp.headerDescription = "noot"; |
---|
18 | comp.headerId = ""; |
---|
19 | var expected:XML = <CMD_ComponentSpec isProfile="true"> |
---|
20 | <Header> |
---|
21 | <ID></ID> |
---|
22 | <Name>aap</Name> |
---|
23 | <Description>noot</Description> |
---|
24 | </Header> |
---|
25 | </CMD_ComponentSpec> |
---|
26 | |
---|
27 | assertEquals(expected.toXMLString(), comp.toXml().toXMLString()); |
---|
28 | |
---|
29 | } |
---|
30 | } |
---|
31 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.