Coder Social home page Coder Social logo

tkmats's Introduction

Tk Manufacturing Automated Test System (TkMATS)

The Manufacturing Automated Test System is a Python library which provides useful structure for test creation and execution, but does not provide a user-defined method of controlling that test environment. The purpose of this project is to provide the start button and to provide visual feedback as to the actual test that is executing. The implementation is done using a tkinter.Frame subclass which may be embedded into any tkinter-style window.

Status

This package still functions; however, its functionality has been factored into MATS and this package will be abandoned as a standalone package. Please continue to use MATS and refactor any uses of TkMATS to utilize the built-in elements.

Installation

Installation is as easy as pip install tkmats.

Usage

You must set up your test so that it can successfully execute on the MATS. Once it is set up there, then you are just a couple of lines away from converting an ATE-based test to a TkMATS.

We will start with the example application located within the ATE repository. The high-level functional bits are copied here for reference:

# create the sequence of test objects
sequence = [CommunicationTest(), PumpFlowTest()]
ts = TestSequence(sequence=sequence, auto_run=False, loglevel=logging.DEBUG)

# start the test as many times as you wish!
for _ in range(3):
    ts.start()
    sleep(2.0)

Note that the test was simply started using the TestSequence.start() method. Since we are going to have a test frame that comes with TkMATS, then we won't require the automated start and can, instead, rely on the user button supplied. Our complete sequence could be as simple as:

# create the sequence of test objects
sequence = [CommunicationTest(), PumpFlowTest()]
ts = TestSequence(sequence=sequence, auto_run=False, loglevel=logging.DEBUG)

window = tk.Tk()

tkmats_frame = TkMatsFrame(window, ts)
tkmats_frame.grid()

window.mainloop()

Note that most of the added code is related to simply creating the window object within which the TkMatsFrame is to be embedded.

There are two tests that are executed here, one CommunicationTest and one PumpTest. Screenshots of various possible scenarios are shown here:

Communications Test Failure

Communications Test Failure Screenshot

Flow Test Failure

Flow Test Failure Screenshot

All Passing

All Passing Screenshot

Animated Example

Animation of Test

Note that the tests that fail will turn red while the tests that pass will turn green. Any failing tests will trigger a final "fail" at the bottom.

tkmats's People

Contributors

slightlynybbled avatar

Stargazers

Markus Kasten avatar

Watchers

James Cloos avatar  avatar  avatar

tkmats's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.