[C-MPI-commits] SF.net SVN: c-mpi:[61] test/cmpi
Status: Pre-Alpha
Brought to you by:
jmwozniak
|
From: <jmw...@us...> - 2010-04-29 20:57:41
|
Revision: 61
http://c-mpi.svn.sourceforge.net/c-mpi/?rev=61&view=rev
Author: jmwozniak
Date: 2010-04-29 20:57:35 +0000 (Thu, 29 Apr 2010)
Log Message:
-----------
cmpi/test05 -> test-update01
Added Paths:
-----------
test/cmpi/test-update01.c
test/cmpi/test-update01.zsh
Removed Paths:
-------------
test/cmpi/test05.c
test/cmpi/test05.zsh
Copied: test/cmpi/test-update01.c (from rev 60, test/cmpi/test05.c)
===================================================================
--- test/cmpi/test-update01.c (rev 0)
+++ test/cmpi/test-update01.c 2010-04-29 20:57:35 UTC (rev 61)
@@ -0,0 +1,45 @@
+
+/**
+ Put three keys, update one, and get the updated value.
+*/
+
+#include "test_helpers.h"
+
+void
+cmpi_client_code()
+{
+ char key1[10];
+ char key2[10];
+ char key3[10];
+ sprintf(key1, "key1_%i", mpi_rank);
+ sprintf(key2, "key2_%i", mpi_rank);
+ sprintf(key3, "key3_%i", mpi_rank);
+
+ wait_for_notification();
+ notify_next();
+
+ char value[30];
+ sprintf(value, "value1");
+ cmpi_put(key1, value, strlen(value)+1);
+ printf("FIRST PUT SUCCEEDED\n");
+ sprintf(value, "value2");
+ cmpi_put(key2, value, strlen(value)+1);
+ printf("SECOND PUT SUCCEEDED\n");
+ sprintf(value, "value3");
+ cmpi_put(key3, value, strlen(value)+1);
+ printf("THIRD PUT SUCCEEDED\n");
+
+ sleep(2);
+
+ cmpi_update(key2, "X", 1, 3);
+
+ char* result;
+ int length;
+ cmpi_get(key2, &result, &length);
+ printf("result: %s\n", result);
+ printf("GET SUCCEEDED\n");
+
+ sleep(2);
+
+ cmpi_shutdown();
+}
Property changes on: test/cmpi/test-update01.c
___________________________________________________________________
Added: svn:mergeinfo
+
Copied: test/cmpi/test-update01.zsh (from rev 60, test/cmpi/test05.zsh)
===================================================================
--- test/cmpi/test-update01.zsh (rev 0)
+++ test/cmpi/test-update01.zsh 2010-04-29 20:57:35 UTC (rev 61)
@@ -0,0 +1,37 @@
+#!/bin/zsh
+
+# Be sure to make tests with D=1
+
+# set -x
+
+source tools/test-helpers.zsh
+
+PROGRAM=$1
+OUT=${PROGRAM%.x}.out
+shift
+LAUNCH=${*}
+
+if (( USE_COMM_WORLD == 1 ))
+then
+
+ # Monolithic execution (5 nodes, 1 client):
+
+ mpiexec -n 6 ${PROGRAM} -n 5 -p reps=10 >& ${OUT}
+ CODE=$?
+ [[ ${CODE} == 0 ]] || crash "exit code was: ${CODE}"
+
+else
+
+ # KDA-2B execution:
+
+ tools/startup_nodes.zsh $(( N-1 )) 100 &
+ mpiexec -n 1 test/cmpi/test01.x > CLIENT.out
+ sleep $(( N+15 ))
+
+fi
+
+# Should be 6 "Normal exit."s
+N=$( grep -c "Normal exit." ${OUT} )
+(( N == 6 )) || crash "N != 6"
+
+exit 0
Property changes on: test/cmpi/test-update01.zsh
___________________________________________________________________
Added: svn:executable
+ *
Added: svn:mergeinfo
+
Deleted: test/cmpi/test05.c
===================================================================
--- test/cmpi/test05.c 2010-04-29 20:56:35 UTC (rev 60)
+++ test/cmpi/test05.c 2010-04-29 20:57:35 UTC (rev 61)
@@ -1,45 +0,0 @@
-
-/**
- Put three keys, update one, and get the updated value.
-*/
-
-#include "test_helpers.h"
-
-void
-cmpi_client_code()
-{
- char key1[10];
- char key2[10];
- char key3[10];
- sprintf(key1, "key1_%i", mpi_rank);
- sprintf(key2, "key2_%i", mpi_rank);
- sprintf(key3, "key3_%i", mpi_rank);
-
- wait_for_notification();
- notify_next();
-
- char value[30];
- sprintf(value, "value1");
- cmpi_put(key1, value, strlen(value)+1);
- printf("FIRST PUT SUCCEEDED\n");
- sprintf(value, "value2");
- cmpi_put(key2, value, strlen(value)+1);
- printf("SECOND PUT SUCCEEDED\n");
- sprintf(value, "value3");
- cmpi_put(key3, value, strlen(value)+1);
- printf("THIRD PUT SUCCEEDED\n");
-
- sleep(2);
-
- cmpi_update(key2, "X", 1, 3);
-
- char* result;
- int length;
- cmpi_get(key2, &result, &length);
- printf("result: %s\n", result);
- printf("GET SUCCEEDED\n");
-
- sleep(2);
-
- cmpi_shutdown();
-}
Deleted: test/cmpi/test05.zsh
===================================================================
--- test/cmpi/test05.zsh 2010-04-29 20:56:35 UTC (rev 60)
+++ test/cmpi/test05.zsh 2010-04-29 20:57:35 UTC (rev 61)
@@ -1,37 +0,0 @@
-#!/bin/zsh
-
-# Be sure to make tests with D=1
-
-# set -x
-
-source tools/test-helpers.zsh
-
-PROGRAM=$1
-OUT=${PROGRAM%.x}.out
-shift
-LAUNCH=${*}
-
-if (( USE_COMM_WORLD == 1 ))
-then
-
- # Monolithic execution (5 nodes, 1 client):
-
- mpiexec -n 6 ${PROGRAM} -n 5 -p reps=10 >& ${OUT}
- CODE=$?
- [[ ${CODE} == 0 ]] || crash "exit code was: ${CODE}"
-
-else
-
- # KDA-2B execution:
-
- tools/startup_nodes.zsh $(( N-1 )) 100 &
- mpiexec -n 1 test/cmpi/test01.x > CLIENT.out
- sleep $(( N+15 ))
-
-fi
-
-# Should be 6 "Normal exit."s
-N=$( grep -c "Normal exit." ${OUT} )
-(( N == 6 )) || crash "N != 6"
-
-exit 0
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|