You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by da...@apache.org on 2006/01/09 08:35:59 UTC

svn commit: r367235 - in /webservices/axis2/trunk/c: modules/core/description/ modules/util/ test/unit/ test/unit/core/context/ test/unit/core/description/ test/unit/core/engine/ test/unit/core/phaseresolver/ test/unit/util/

Author: damitha
Date: Sun Jan  8 23:35:00 2006
New Revision: 367235

URL: http://svn.apache.org/viewcvs?rev=367235&view=rev
Log:
Fixed a method name bug in transport_*_desc.c.
dir_handler unit tests was not working after
new code commits. Fixed it.
After Sahan's changes to stream the corresponding unit
tests were not working. Fixed it. Yet 3 tests still
fail. Sahan please look into them if you have time.


Modified:
    webservices/axis2/trunk/c/modules/core/description/transport_in_desc.c
    webservices/axis2/trunk/c/modules/core/description/transport_out_desc.c
    webservices/axis2/trunk/c/modules/util/dir_handler.c
    webservices/axis2/trunk/c/test/unit/Makefile.am
    webservices/axis2/trunk/c/test/unit/core/context/Makefile.am
    webservices/axis2/trunk/c/test/unit/core/description/Makefile.am
    webservices/axis2/trunk/c/test/unit/core/engine/Makefile.am
    webservices/axis2/trunk/c/test/unit/core/phaseresolver/Makefile.am
    webservices/axis2/trunk/c/test/unit/util/util_dir_handler_test.c
    webservices/axis2/trunk/c/test/unit/util/util_hash_test.c
    webservices/axis2/trunk/c/test/unit/util/util_linked_list_test.c
    webservices/axis2/trunk/c/test/unit/util/util_log_test.c
    webservices/axis2/trunk/c/test/unit/util/util_stream_test.c
    webservices/axis2/trunk/c/test/unit/util/util_stream_test.h

Modified: webservices/axis2/trunk/c/modules/core/description/transport_in_desc.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/description/transport_in_desc.c?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/description/transport_in_desc.c (original)
+++ webservices/axis2/trunk/c/modules/core/description/transport_in_desc.c Sun Jan  8 23:35:00 2006
@@ -127,7 +127,7 @@
 /************************** End of function prototypes ************************/
 
 axis2_transport_in_desc_t * AXIS2_CALL 
-axis2_transport_in_create_with_qname (axis2_env_t **env, axis2_qname_t *qname)
+axis2_transport_in_desc_create_with_qname (axis2_env_t **env, axis2_qname_t *qname)
 {
     axis2_transport_in_desc_impl_t *transport_in_impl = NULL;
     

Modified: webservices/axis2/trunk/c/modules/core/description/transport_out_desc.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/description/transport_out_desc.c?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/description/transport_out_desc.c (original)
+++ webservices/axis2/trunk/c/modules/core/description/transport_out_desc.c Sun Jan  8 23:35:00 2006
@@ -127,7 +127,7 @@
 /************************** End of function prototypes ************************/
 
 axis2_transport_out_desc_t * AXIS2_CALL 
-axis2_transport_out_create_with_qname (axis2_env_t **env, axis2_qname_t *qname)
+axis2_transport_out_desc_create_with_qname (axis2_env_t **env, axis2_qname_t *qname)
 {
     axis2_transport_out_desc_impl_t *transport_out_impl = NULL;
      

Modified: webservices/axis2/trunk/c/modules/util/dir_handler.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/util/dir_handler.c?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/util/dir_handler.c (original)
+++ webservices/axis2/trunk/c/modules/util/dir_handler.c Sun Jan  8 23:35:00 2006
@@ -40,7 +40,6 @@
     int file_size = 0;
     
     AXIS2_ENV_CHECK(env, NULL);
-    
     file_list = axis2_array_list_create(env, 100);
 	count = scandir(pathname, &files, file_select, alphasort);
 
@@ -75,7 +74,7 @@
             return NULL;
         }
         strcpy(path, pathname);
-        strcat(path, AXIS2_PATH_SEP_CHAR);
+        strcat(path, AXIS2_PATH_SEP_STR);
         strcat(path, fname);
         buf = AXIS2_MALLOC((*env)->allocator, sizeof(struct stat));
         if(!buf)

Modified: webservices/axis2/trunk/c/test/unit/Makefile.am
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/Makefile.am?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/Makefile.am (original)
+++ webservices/axis2/trunk/c/test/unit/Makefile.am Sun Jan  8 23:35:00 2006
@@ -17,6 +17,7 @@
                     -laxis2_util \
                     -laxis2_om \
                     -laxis2_description \
+                    -laxis2_deployment \
                     -laxis2_engine \
                     -laxis2_context \
                     -laxis2_phaseresolver \

Modified: webservices/axis2/trunk/c/test/unit/core/context/Makefile.am
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/core/context/Makefile.am?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/core/context/Makefile.am (original)
+++ webservices/axis2/trunk/c/test/unit/core/context/Makefile.am Sun Jan  8 23:35:00 2006
@@ -19,6 +19,7 @@
                     -laxis2_util \
                     -laxis2_context \
                     -laxis2_description \
+                    -laxis2_deployment \
                     -laxis2_engine \
                     -laxis2_wsdl \
                     -laxis2_phaseresolver \

Modified: webservices/axis2/trunk/c/test/unit/core/description/Makefile.am
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/core/description/Makefile.am?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/core/description/Makefile.am (original)
+++ webservices/axis2/trunk/c/test/unit/core/description/Makefile.am Sun Jan  8 23:35:00 2006
@@ -25,6 +25,7 @@
                     -laxis2_util \
                     -laxis2_context \
                     -laxis2_description \
+                    -laxis2_deployment \
                     -laxis2_engine \
                     -laxis2_wsdl \
                     -laxis2_phaseresolver \

Modified: webservices/axis2/trunk/c/test/unit/core/engine/Makefile.am
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/core/engine/Makefile.am?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/core/engine/Makefile.am (original)
+++ webservices/axis2/trunk/c/test/unit/core/engine/Makefile.am Sun Jan  8 23:35:00 2006
@@ -18,6 +18,7 @@
                     -laxis2_util \
                     -laxis2_context \
                     -laxis2_description \
+                    -laxis2_deployment \
                     -laxis2_engine \
                     -laxis2_wsdl \
                     -laxis2_phaseresolver \

Modified: webservices/axis2/trunk/c/test/unit/core/phaseresolver/Makefile.am
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/core/phaseresolver/Makefile.am?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/core/phaseresolver/Makefile.am (original)
+++ webservices/axis2/trunk/c/test/unit/core/phaseresolver/Makefile.am Sun Jan  8 23:35:00 2006
@@ -24,6 +24,7 @@
                     -laxis2_util \
                     -laxis2_context \
                     -laxis2_description \
+                    -laxis2_deployment \
                     -laxis2_engine \
                     -laxis2_wsdl \
                     -laxis2_phaseresolver \

Modified: webservices/axis2/trunk/c/test/unit/util/util_dir_handler_test.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/util/util_dir_handler_test.c?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/util/util_dir_handler_test.c (original)
+++ webservices/axis2/trunk/c/test/unit/util/util_dir_handler_test.c Sun Jan  8 23:35:00 2006
@@ -3,7 +3,7 @@
 
 void Testaxis2_dir_handler_list_dir(CuTest *tc)
 {
-    puts("axis2_dir_handler_list_test\n");
+    puts("testing axis2_dir_handler_list_dir\n");
 
     axis2_allocator_t *allocator = axis2_allocator_init (NULL);
     axis2_env_t *env = axis2_env_create(allocator);
@@ -14,7 +14,6 @@
     axis2_char_t *expected = NULL;
     axis2_char_t *actual = NULL;
     int i = 0;
-    
     expected = AXIS2_STRDUP("libaxis2_util.so", &env);
 	pathname = AXIS2_STRDUP(
         "/home/damitha/projects/c/test/unit/infiles/dir_handler", &env);
@@ -23,8 +22,8 @@
     
     for (i = 0; i < size; i++) 
     {
-        axis2_arch_file_t *arch_file = NULL;
-        arch_file = (axis2_arch_file_t *) AXIS2_ARRAY_LIST_GET(file_list, &env, i);
+        axis2_file_t *arch_file = NULL;
+        arch_file = (axis2_file_t *) AXIS2_ARRAY_LIST_GET(file_list, &env, i);
         if(0 == AXIS2_STRCMP(arch_file->name, expected))
         {
             actual = arch_file->name;

Modified: webservices/axis2/trunk/c/test/unit/util/util_hash_test.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/util/util_hash_test.c?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/util/util_hash_test.c (original)
+++ webservices/axis2/trunk/c/test/unit/util/util_hash_test.c Sun Jan  8 23:35:00 2006
@@ -7,6 +7,7 @@
 
 void Testaxis2_hash_get(CuTest *tc)
 {
+    printf("testing axis2_hash_get\n"); 
     axis2_allocator_t *allocator = axis2_allocator_init (NULL);
     axis2_env_t *environment =
         axis2_env_create (allocator);

Modified: webservices/axis2/trunk/c/test/unit/util/util_linked_list_test.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/util/util_linked_list_test.c?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/util/util_linked_list_test.c (original)
+++ webservices/axis2/trunk/c/test/unit/util/util_linked_list_test.c Sun Jan  8 23:35:00 2006
@@ -7,7 +7,7 @@
 
 void Testaxis2_linked_list_get(CuTest *tc)
 {
-    puts("axis2_linked_list_test\n");
+    puts("testing axis2_linked_list_get\n");
 
     axis2_allocator_t *allocator = axis2_allocator_init (NULL);
     axis2_env_t *env = axis2_env_create(allocator);

Modified: webservices/axis2/trunk/c/test/unit/util/util_log_test.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/util/util_log_test.c?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/util/util_log_test.c (original)
+++ webservices/axis2/trunk/c/test/unit/util/util_log_test.c Sun Jan  8 23:35:00 2006
@@ -3,15 +3,16 @@
 void Testaxis2_log_write(CuTest *tc) 
 {
 
+    printf("testing axis2_log_write\n"); 
     char actual[10];
     axis2_allocator_t *allocator = axis2_allocator_init(NULL);
-    axis2_stream_t *stream = axis2_stream_create(allocator, NULL);
     axis2_error_t *error = axis2_error_create(allocator);
     axis2_log_t *log  = axis2_log_create (allocator, NULL);
-    axis2_env_t *env = axis2_env_create_with_error_stream_log(allocator, error, stream, log);
+    axis2_env_t *env = axis2_env_create_with_error_log(allocator, error, log);
+    axis2_stream_t *stream = axis2_stream_create_basic(&env);
 
     char *expected = strdup("aaaaaaaaa");
-    AXIS2_STREAM_READ(env->stream, actual, 10);
+    AXIS2_STREAM_READ(stream, &env,  actual, 10);
     AXIS2_LOG_WRITE(env->log, actual, 10);
     CuAssertStrEquals(tc, expected, actual);
 }

Modified: webservices/axis2/trunk/c/test/unit/util/util_stream_test.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/util/util_stream_test.c?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/util/util_stream_test.c (original)
+++ webservices/axis2/trunk/c/test/unit/util/util_stream_test.c Sun Jan  8 23:35:00 2006
@@ -1,27 +1,27 @@
 #include "util_stream_test.h"
 
 void Testaxis2_stream_read(CuTest *tc) {
-
+    printf("testing axis2_stream_read\n");
     char actual[10];
     axis2_allocator_t *allocator = axis2_allocator_init(NULL);
-    axis2_stream_t *stream = axis2_stream_create(allocator, NULL);
     axis2_error_t *error = axis2_error_create(allocator);
-    axis2_env_t *env = axis2_env_create_with_error_stream(allocator, error, stream);
+    axis2_env_t *env = axis2_env_create_with_error(allocator, error);
+    axis2_stream_t *stream = axis2_stream_create_basic(&env);
     char *expected = (char*) strdup("aaaaaaaaa");
-    AXIS2_STREAM_READ(env->stream, actual, 10);
+    AXIS2_STREAM_READ(stream, &env, actual, 10);
     CuAssertStrEquals(tc, expected, actual);
 }
 
 void Testaxis2_stream_write(CuTest *tc) {
+    printf("testing axis2_stream_write\n");
 
     char actual[10];
     axis2_allocator_t *allocator = axis2_allocator_init(NULL);
-    axis2_stream_t *stream = axis2_stream_create(allocator, NULL);
     axis2_error_t *error = axis2_error_create(allocator);
-    axis2_env_t *env = axis2_env_create_with_error_stream(allocator, error, stream);
+    axis2_env_t *env = axis2_env_create_with_error(allocator, error);
+    axis2_stream_t *stream = axis2_stream_create_basic(&env);
     char *expected = (char*) strdup("aaaaaaaaa");
-    AXIS2_STREAM_READ(env->stream, actual, 10);
-    AXIS2_STREAM_WRITE(env->stream, actual, 10);
-    
+    AXIS2_STREAM_READ(stream, &env, actual, 10);
+    AXIS2_STREAM_WRITE(stream, &env, actual, 10);
     CuAssertStrEquals(tc, expected, actual);
 }

Modified: webservices/axis2/trunk/c/test/unit/util/util_stream_test.h
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/test/unit/util/util_stream_test.h?rev=367235&r1=367234&r2=367235&view=diff
==============================================================================
--- webservices/axis2/trunk/c/test/unit/util/util_stream_test.h (original)
+++ webservices/axis2/trunk/c/test/unit/util/util_stream_test.h Sun Jan  8 23:35:00 2006
@@ -7,7 +7,7 @@
 #include <axis2_env.h>
 #include <axis2_allocator.h>
 #include <axis2_error_default.h>
-#include <axis2_stream_default.h>
+#include <axis2_stream.h>
 
 void Testaxis2_stream_read(CuTest *tc);