summaryrefslogtreecommitdiff
path: root/cpp
diff options
context:
space:
mode:
authorMatthew Newhook <matthew@zeroc.com>2008-05-09 22:46:45 +0800
committerMatthew Newhook <matthew@zeroc.com>2008-05-09 22:46:45 +0800
commit2328fb16c11a1cc0951afea846efe82a276302ce (patch)
tree9b6748e077274fc7a0684f80bcb5012582ac1b71 /cpp
parentMerge branch 'master' of cvs:/home/git/ice (diff)
downloadice-2328fb16c11a1cc0951afea846efe82a276302ce.tar.bz2
ice-2328fb16c11a1cc0951afea846efe82a276302ce.tar.xz
ice-2328fb16c11a1cc0951afea846efe82a276302ce.zip
http://bugzilla/bugzilla/show_bug.cgi?id=3127 - allDemos.py has many issues under Windows.
Squashed commit of the following: commit 5c10903ba9e2ce49af02d5e543088a7edd149e6b Author: Matthew Newhook <matthew@zeroc.com> Date: Fri May 9 22:45:21 2008 +0800 Fix bug. commit dd664b401df779cd7146d43bbe970e121cc4ceb5 Author: Matthew Newhook <matthew@zeroc.com> Date: Fri May 9 22:27:39 2008 +0800 fix bug with IceGrid/icebox expect script. commit 21ba063ad8e1f07f26de3ab384aef47b59a4d34a Author: U-MARCH4\matthew <matthew@march4.(none)> Date: Fri May 9 22:25:13 2008 +0800 update -R/-r to take multiple filters. commit 3ea23a392723c0edd0462e9ca4b5fbc36171ee05 Author: U-MARCH4\matthew <matthew@march4.(none)> Date: Fri May 9 22:05:36 2008 +0800 First set of changes. At this point all demo scripts work under Windows.
Diffstat (limited to 'cpp')
-rwxr-xr-x[-rw-r--r--]cpp/demo/Freeze/backup/db/DB_CONFIG0
-rwxr-xr-x[-rw-r--r--]cpp/demo/Freeze/backup/db/data/.gitignore0
-rwxr-xr-xcpp/demo/IceGrid/icebox/expect.py14
-rwxr-xr-xcpp/demo/IceStorm/replicated/expect.py10
-rwxr-xr-xcpp/demo/IceStorm/replicated2/expect.py8
5 files changed, 24 insertions, 8 deletions
diff --git a/cpp/demo/Freeze/backup/db/DB_CONFIG b/cpp/demo/Freeze/backup/db/DB_CONFIG
index 7e738e09d58..7e738e09d58 100644..100755
--- a/cpp/demo/Freeze/backup/db/DB_CONFIG
+++ b/cpp/demo/Freeze/backup/db/DB_CONFIG
diff --git a/cpp/demo/Freeze/backup/db/data/.gitignore b/cpp/demo/Freeze/backup/db/data/.gitignore
index 39af5887579..39af5887579 100644..100755
--- a/cpp/demo/Freeze/backup/db/data/.gitignore
+++ b/cpp/demo/Freeze/backup/db/data/.gitignore
diff --git a/cpp/demo/IceGrid/icebox/expect.py b/cpp/demo/IceGrid/icebox/expect.py
index 525d1ceb0e3..c10608ee3a1 100755
--- a/cpp/demo/IceGrid/icebox/expect.py
+++ b/cpp/demo/IceGrid/icebox/expect.py
@@ -26,7 +26,19 @@ import demoscript.Util
demoscript.Util.defaultLanguage = "C++"
import demoscript.IceGrid.icebox
+desc = 'application.xml'
+if demoscript.Util.mode == 'debug':
+ fi = open(desc, "r")
+ desc = 'tmp_application.xml'
+ fo = open(desc, "w")
+ for l in fi:
+ if l.find('exe="icebox"') != -1:
+ l = l.replace('exe="icebox"', 'exe="iceboxd.exe"')
+ fo.write(l)
+ fi.close()
+ fo.close()
+
directory = os.path.dirname(os.path.abspath(__file__))
demoscript.Util.addLdPath(directory)
-demoscript.IceGrid.icebox.run('./client')
+demoscript.IceGrid.icebox.run('./client', desc[0:len(desc)-4])
diff --git a/cpp/demo/IceStorm/replicated/expect.py b/cpp/demo/IceStorm/replicated/expect.py
index aa8c85bba0e..0a92a007ae0 100755
--- a/cpp/demo/IceStorm/replicated/expect.py
+++ b/cpp/demo/IceStorm/replicated/expect.py
@@ -32,7 +32,7 @@ if demoscript.Util.mode == 'debug':
desc = 'tmp_application.xml'
fo = open(desc, "w")
for l in fi:
- if l.find('exe="icebox"'):
+ if l.find('exe="icebox"') != -1:
l = l.replace('exe="icebox"', 'exe="iceboxd.exe"')
fo.write(l)
fi.close()
@@ -97,9 +97,11 @@ sub.waitTestSuccess()
pub.kill(signal.SIGINT)
pub.waitTestSuccess()
-matchpat(node, [ 'DemoIceStorm-1: Topic: time: remove replica observer: [-0-9A-Fa-f]+',
- 'DemoIceStorm-2: Topic: time: remove replica observer: [-0-9A-Fa-f]+' ,
- 'DemoIceStorm-3: Topic: time: unsubscribe: [-0-9A-Fa-f]+' ])
+# With Cygwin SIGINT isn't intercepted.
+if not demoscript.Util.isCygwin():
+ matchpat(node, [ 'DemoIceStorm-1: Topic: time: remove replica observer: [-0-9A-Fa-f]+',
+ 'DemoIceStorm-2: Topic: time: remove replica observer: [-0-9A-Fa-f]+' ,
+ 'DemoIceStorm-3: Topic: time: unsubscribe: [-0-9A-Fa-f]+' ])
admin.sendline('registry shutdown Master')
admin.sendline('exit')
diff --git a/cpp/demo/IceStorm/replicated2/expect.py b/cpp/demo/IceStorm/replicated2/expect.py
index d020ebc52a4..c933f5303d6 100755
--- a/cpp/demo/IceStorm/replicated2/expect.py
+++ b/cpp/demo/IceStorm/replicated2/expect.py
@@ -73,9 +73,11 @@ sub.waitTestSuccess()
pub.kill(signal.SIGINT)
pub.waitTestSuccess()
-ib1.expect('Topic: time: remove replica observer: [-0-9A-Fa-f]+')
-ib2.expect('Topic: time: remove replica observer: [-0-9A-Fa-f]+')
-ib3.expect('Topic: time: unsubscribe: [-0-9A-Fa-f]+')
+# With Cygwin SIGINT isn't intercepted.
+if not demoscript.Util.isCygwin():
+ ib1.expect('Topic: time: remove replica observer: [-0-9A-Fa-f]+')
+ ib2.expect('Topic: time: remove replica observer: [-0-9A-Fa-f]+')
+ ib3.expect('Topic: time: unsubscribe: [-0-9A-Fa-f]+')
admin = demoscript.Util.spawn('iceboxadmin --Ice.Config=config.ib1 shutdown')
admin.waitTestSuccess()