Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add an invalid platform test for which the parser should trigger an assertion error
authorthiery <thiery@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Fri, 12 Nov 2010 18:44:20 +0000 (18:44 +0000)
committerthiery <thiery@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Fri, 12 Nov 2010 18:44:20 +0000 (18:44 +0000)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@8542 48e7efb5-ca39-0410-a469-dd3cf9ba447f

teshsuite/simdag/platforms/two_hosts_asymetric.tesh
teshsuite/simdag/platforms/two_hosts_asymetric_BOGUS2.xml [new file with mode: 0644]

index ff075d2..2283477 100644 (file)
@@ -3,3 +3,8 @@ $ ./flatifier two_hosts_asymetric_BOGUS.xml --log=root.fmt:[%10.6r]%e(%i:%P@%h)%
 > [  0.000000] (0:@) surf_workstation_model_init_ptask_L07
 > [  0.000000] (0:@) Error while loading two_hosts_asymetric_BOGUS.xml: The route between "alice" and "bob" already exist
 
+! expect signal SIGABRT
+$ ./flatifier two_hosts_asymetric_BOGUS2.xml --log=root.fmt:[%10.6r]%e(%i:%P@%h)%e%m%n
+> [  0.000000] (0:@) surf_workstation_model_init_ptask_L07
+> [  0.000000] (0:@) Error while loading two_hosts_asymetric_BOGUS2.xml: The route between "alice" and "bob" already exist
+
diff --git a/teshsuite/simdag/platforms/two_hosts_asymetric_BOGUS2.xml b/teshsuite/simdag/platforms/two_hosts_asymetric_BOGUS2.xml
new file mode 100644 (file)
index 0000000..8038273
--- /dev/null
@@ -0,0 +1,29 @@
+
+<!-- THIS FILE IS INVALID.
+
+It declares a route alice->bob and another bob->alice, both being different.
+It is used to check that this (bogus) file is detected as is (see
+two_hosts_asymetric.tesh) -->
+
+<?xml version='1.0'?>
+ <!DOCTYPE platform SYSTEM "simgrid.dtd">
+ <platform version="2">
+ <AS  id="AS0"  routing="Full">
+   <host id="bob" power="1000000000"/>
+   <host id="alice" power="500000000"/>
+   <link id="link1" bandwidth="125000000" latency="5E-5"/>
+   <link id="link2" bandwidth="125000000" latency="5E-5"/>
+   <link id="link3" bandwidth="125000000" latency="5E-5"/>
+   <link id="link4" bandwidth="125000000" latency="5E-5"/>
+   
+   <route src="bob" dst="alice">
+     <link_ctn id="link1"/><link_ctn id="link2"/><link_ctn id="link4"/>
+   </route>
+
+   <route src="alice" dst="bob">
+     <link_ctn id="link4"/><link_ctn id="link3"/><link_ctn id="link1"/>
+   </route>
+
+ </AS>
+ </platform>