Topic
  • 4 replies
  • Latest Post - ‏2012-12-07T04:30:43Z by RichaM
RichaM
RichaM
70 Posts

Pinned topic Rhapsody 7.6.1.2 test conductor code coverage issue in assertion based test

‏2012-12-03T09:28:17Z |
Hi
I want to test my rhapsody class with assertion based testing mode using test conductor
I am using rhapsody 7.6.1.2 and visual studio 2008 as a compiler

The configuration :: environment has been tailor made by us. Which is using visual studio 2008 internally as a compiler

I created test architecture on class ABC. If I enable compute code coverage option then it gives error as "Code coverage not yet supported for MyConfiguration environment"

Can anyone tell me, how can I get code coverage of my class? What changes I need to do in my configuration so that rhapsody will start generating code coverage?

Thanks in advance
Updated on 2012-12-07T04:30:43Z at 2012-12-07T04:30:43Z by RichaM
  • chr_btc-es
    chr_btc-es
    69 Posts

    Re: Rhapsody 7.6.1.2 test conductor code coverage issue in assertion based test

    ‏2012-12-03T15:57:59Z  
    Hi,

    to be able to compute code coverage, TC needs to know the used compiler. This is deduced from the name of the CG environment if one of these standard environments is used: Microsoft, MSVC, MSVC9, Cygwin, Linux (and the corresponding MicroC environments).
    If your compile environment has a different name, you need to provide information which compiler is used in an options file. Attached is an options file for Microsoft VS 2008 compiler, version is the major version number of the cl.exe. Enter the path to the options file in the tag 'CodeCoverageOptionsFileName' of the CG Configuration (if the file is in the project folder, you can enter the file name. Or enter a relative or absolute path to the file).

    A template of the options file with supported entries is part of the TC installation: <Rhapsosy>/TestConductor>/TCCodeAnnotationOptions.xml

    Regards, Christian.
  • CodeDeveloper
    CodeDeveloper
    5 Posts

    Re: Rhapsody 7.6.1.2 test conductor code coverage issue in assertion based test

    ‏2012-12-06T06:31:17Z  
    Hi Christian,

    I have query on following line
    <Compiler name="MSVC" version="1500" />

    Can you tell me, what does this version = 1500 specifies? As I have tried putting different values like 1800, 1499, its working. But if i use 800, 8000 , then its not working. Could you able to give exact mapping of this number with visual studio version?

    Thanks
  • chr_btc-es
    chr_btc-es
    69 Posts

    Re: Rhapsody 7.6.1.2 test conductor code coverage issue in assertion based test

    ‏2012-12-06T11:04:56Z  
    Hi Christian,

    I have query on following line
    <Compiler name="MSVC" version="1500" />

    Can you tell me, what does this version = 1500 specifies? As I have tried putting different values like 1800, 1499, its working. But if i use 800, 8000 , then its not working. Could you able to give exact mapping of this number with visual studio version?

    Thanks
    Hi,

    this is the version number of the compiler (cl.exe), in the format which is used in the built in _MSC_VER define. For example, when using VS 2008:

    $ cl.exe
    Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 15.00.21022.08 for 80x86
    Copyright (C) Microsoft Corporation. All rights reserved.

    usage: cl http:// option... filename... http:// /link linkoption...

    _MSC_VER is defined as 1500.

    Regards, Christian.
  • RichaM
    RichaM
    70 Posts

    Re: Rhapsody 7.6.1.2 test conductor code coverage issue in assertion based test

    ‏2012-12-07T04:30:43Z  
    Hi,

    this is the version number of the compiler (cl.exe), in the format which is used in the built in _MSC_VER define. For example, when using VS 2008:

    $ cl.exe
    Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 15.00.21022.08 for 80x86
    Copyright (C) Microsoft Corporation. All rights reserved.

    usage: cl http:// option... filename... http:// /link linkoption...

    _MSC_VER is defined as 1500.

    Regards, Christian.
    Thanks a lot Chris

    Our thing has started working...