Forum Discussion

VasanthVijay's avatar
VasanthVijay
Contributor
9 years ago

how to add class in odt using jscirpt?

Hello All,

                Good morning.

                 I want to create class in odt.While using jscript.If suppoes that class is already exists mean need to update the property.Otherwise just create class.

 

  • baxatob's avatar
    baxatob
    9 years ago

    [IMHO] The ODT implementation in TestComplete is really obsolete. If you need an object-oriented way to design your tests you can use a Python as a project language - it gives a full power of object-driven testing and may be more. 

  • Manfred_F's avatar
    Manfred_F
    Regular Contributor

    Yes,

    sad to say, they removed it. Too few people recognized the value:

    - separation of test data and test functions

    - separation of sequence control from test functions

    - sequence control via a hierarchical model, which is configurable per script during runtime (!!)

     

    I'm really sad, wondering what they will cancel next?

    • baxatob's avatar
      baxatob
      Community Hero

      [IMHO] The ODT implementation in TestComplete is really obsolete. If you need an object-oriented way to design your tests you can use a Python as a project language - it gives a full power of object-driven testing and may be more. 

      • Manfred_F's avatar
        Manfred_F
        Regular Contributor

        Hi baxatob,

        that's OK, but take a look at what I'm doing with ODT and You will see.

         

        ODT is generic, the ODT tree can be changed during runtime. I use this to implement generic standard tests for functions which work similar e.g. with different dialogs. I've implemented this in a way that even provides me hierarchical standard tests.

        Would You use generic mechanisms in Phyton? It can be done e.g. in VBA, I know. You generate scripting code during runtime, execute it, and maybe delete it afterwards. These are highly sophisticated solutions, but: are they clearly readable and understandable?

        Of course, You can avoid generic mechanisms. Just add all the options in Your testing code and execute these blocks on condition.

        The advantage of the generic ODT solution is: The ODT tree is adapted. After the test, it reflects 1:1 the log tree, so I get maximum transparency. ODT provides a model based test control flow. Model based working is superior to purely sourcecode based work, [IMHO].

  • Manfred_F's avatar
    Manfred_F
    Regular Contributor

    If You want to use ODT nevertheless:

    How an ODT class can be created or modified is explained in the help system, including examples. So, ...read.