Skip to content
/ expect Public
forked from matt-allan/expect

A pure PHP alternative to expect - This is a one-class version that supports a hierarchy of expectations

License

Notifications You must be signed in to change notification settings

dana321/expect

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Expect

This package is a pure PHP alternative to expect, the Unix tool. This package doesn't depend on the PECL package either.

Expect lets you script interactions with interactive terminal applications.

Why?

The original author wrote this "because I wrote an interactive CLI program and needed to write automated tests for it. Apparently people use the real expect for scripting ftp and telnet workflows, so I guess you could use it for that too."

I have modified this for my own uses.

Installation

For now, copy the Expect.php file to your own project and use include_once with the path of the file to add it

API

This version does not support chaining of commands. It follows the program flow as defined within your php application.

Examples

There is an example in the source file Expect.php

About

A pure PHP alternative to expect - This is a one-class version that supports a hierarchy of expectations

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 100.0%