Adding Custom Tests; Introduction; References; Changing The Error Messages In A Test Script - Extreme Networks Sentriant AG Software User's Manual

Hide thumbs Also See for Sentriant AG:
Table of Contents

Advertisement

System Administration

Adding Custom Tests

Introduction

Sentriant AG is an efficient, flexible and extensible testing platform. All tests are implemented in the
object oriented programming language called Python. Python is a well- respected, clean, and efficient
scripting language. Because the language is object oriented and the Sentriant AG test platform is
extensible, new tests can be developed easily.
Existing tests can also be extended using inheritance—a programming language's ability to derive one
class/script from another class and override and extend methods of that class.
You need some programming experience to extend and add tests. If you have previously used Perl to
complete these tasks, you might find that Python is a better choice as a programming language for the
tasks described in the following sections.
CAUTION
You should familiarize yourself with Python and with the rest of the Sentriant AG product before attempting to create
custom test scripts.

References

This version of Sentriant AG uses Python v2.4.1.
Python home:
http://www.python.org/
Python 2.4.1 tutorial:
http://www.python.org/doc/2.4.1/tut/tut.html
Python language reference:
http://www.python.org/doc/2.4.1/
Sample test scripts are on the Sentriant AG CD in the

Changing the Error Messages in a Test Script

Using Python, try changing the error messages in an existing test script. This task can help you to
familiarize yourself with the Sentriant AG scripting API. Each Sentriant AG test script defines a test
class. To change an error message, create a new script that derives a new test class from an existing test
class and modify the return hash of the
For example, to change an error message:
1 Log in as
root
2 Open the
/sampleScripts/myCheckSoftwareNotAllowed.py
editor.
322
runTest
to the Sentriant AG server using SSH.
folder.
/sampleScripts
method.
file on the Sentriant AG CD in a text
Sentriant AG Software Users Guide, Version 5.3

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sentriant ag 5.3

Table of Contents