Changeset 2410


Ignore:
Timestamp:
Jan 2, 2009 6:15:07 PM (15 years ago)
Author:
bennylp
Message:

Test refinements for mingw etc.

Location:
pjproject/trunk/tests
Files:
1 added
7 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/tests/cdash/README.TXT

    r2400 r2410  
    4444     $ python main.py cfg_msvc 
    4545 
     46   To execute tests for Symbian target: 
     47 
     48     $ python main.py cfg_symbian 
     49 
    4650 
    4751   If you have a different site configuration file, you may specify it in the 
     
    4953 
    5054     $ python main.py cfg_gnu my_site_config 
     55 
     56   For more information you can also pass "-h" or "--help", e.g.: 
     57 
     58     $ python main.py cfg_gnu --help 
     59 
  • pjproject/trunk/tests/cdash/builder.py

    r2405 r2410  
    8080    Operation(Operation.TEST, "./pjsip-test$SUFFIX", name="pjsip test", 
    8181              wdir="pjsip/bin") 
    82 ] 
    83  
    84 # 
    85 # These are operations to build the software on GNU/Posix systems 
    86 # 
    87 gnu_build_ops = [ 
    88     Operation(Operation.CONFIGURE, "sh ./configure"), 
    89     Operation(Operation.BUILD, "sh -c 'make distclean && make dep && make && cd pjsip-apps/src/python && python setup.py clean build'"), 
    90     #Operation(Operation.BUILD, "python setup.py clean build", 
    91     #          wdir="pjsip-apps/src/python") 
    9282] 
    9383 
     
    237227            self.build_tests() 
    238228        self.pre_action() 
     229        mandatory_op = ["update", "configure", "build"] 
    239230        counter = 0 
    240231        for a in self.ccdash_args: 
     
    262253            a = b 
    263254            #print a 
    264             ccdash.main(a) 
     255            rc = ccdash.main(a) 
     256            if rc!=0 and a[1] in mandatory_op: 
     257                print "Stopping because of error.." 
     258                break 
    265259            counter = counter + 1 
    266260        self.post_action() 
     
    316310        cmds = [] 
    317311        cmds.extend(update_ops) 
    318         cmds.extend(gnu_build_ops) 
     312        cmds.append(Operation(Operation.CONFIGURE, "sh ./configure")) 
     313        if sys.platform == "win32": 
     314            # Don't build python module on Mingw 
     315            cmds.append(Operation(Operation.BUILD,  
     316                            "sh -c 'make distclean && make dep && make'")) 
     317        else: 
     318            cmds.append(Operation(Operation.BUILD,  
     319                            "sh -c 'make distclean && make dep && make" + \ 
     320                            " && cd pjsip-apps/src/python && " + \ 
     321                            "python setup.py clean build'")) 
     322 
    319323        cmds.extend(std_test_ops) 
    320324        cmds.extend(build_pjsua_test_ops()) 
  • pjproject/trunk/tests/cdash/cfg_gnu.py

    r2405 r2410  
    6060                                  cfg_site.OPTIONS) 
    6161 
     62    config_site = "#define PJ_TODO(x)\n" + cfg_site.CONFIG_SITE 
     63    user_mak = "export CFLAGS+=-Wall\n" + cfg_site.USER_MAK 
     64 
    6265    builders = [ 
    6366        builder.GNUTestBuilder(test_cfg, build_config_name="default", 
    64                                user_mak="export CFLAGS+=-Wall\n", 
    65                                config_site="#define PJ_TODO(x)\n", 
     67                               user_mak=user_mak, 
     68                               config_site=config_site, 
    6669                               exclude=cfg_site.EXCLUDE, 
    6770                               not_exclude=cfg_site.NOT_EXCLUDE) 
  • pjproject/trunk/tests/cdash/cfg_msvc.py

    r2405 r2410  
    6767                                  cfg_site.OPTIONS) 
    6868 
     69    config_site = "#define PJ_TODO(x)\n" + cfg_site.CONFIG_SITE 
     70    user_mak = cfg_site.USER_MAK 
     71 
    6972    builders = [ 
    7073        builder.MSVCTestBuilder(test_cfg,  
    7174                                target=target, 
    7275                                build_config_name="default", 
    73                                 config_site="#define PJ_TODO(x)\n", 
     76                                config_site=config_site, 
    7477                                exclude=cfg_site.EXCLUDE, 
    7578                                not_exclude=cfg_site.NOT_EXCLUDE) 
  • pjproject/trunk/tests/cdash/cfg_site_sample.py

    r2401 r2410  
    3636OPTIONS = [] 
    3737 
     38# What's the content of config_site.h 
     39CONFIG_SITE = "" 
     40 
     41# What's the content of user.mak 
     42USER_MAK = "" 
     43 
    3844# List of regular expression of test patterns to be excluded 
    3945EXCLUDE = [] 
  • pjproject/trunk/tests/cdash/cfg_symbian.py

    r2405 r2410  
    7272""" 
    7373 
     74    config_Site = config_site1 + cfg_site.CONFIG_SITE 
     75 
    7476    builders = [ 
    7577        builder.SymbianTestBuilder(test_cfg,  
  • pjproject/trunk/tests/pjsua/run.py

    r2398 r2410  
    162162        def wait(self): 
    163163                self.trace("wait") 
    164                 self.proc.wait() 
     164                self.proc.communicate("q") 
     165 
    165166        def trace(self, s): 
    166167                if self.trace_enabled: 
     
    178179                        p.send("q") 
    179180                        p.send("q") 
    180                         p.expect(const.DESTROYED, False) 
    181                         p.wait() 
     181                        is_err = False 
     182                        try: 
     183                                ret = p.expect(const.DESTROYED, False) 
     184                                if not ret: 
     185                                        is_err = True 
     186                        except: 
     187                                is_err = True 
     188                        if is_err: 
     189                                if sys.hexversion >= 0x02060000: 
     190                                        p.proc.terminate() 
     191                                else: 
     192                                        p.wait() 
     193                        else: 
     194                                p.wait() 
    182195        print "Test completed with error: " + errmsg 
    183196        sys.exit(1) 
Note: See TracChangeset for help on using the changeset viewer.