PHP Classes

File: tests/unit/StackTest.php

Recommend this page to a friend!
  Classes of Jon Lawrence   Equation Operating System   tests/unit/StackTest.php   Download  
File: tests/unit/StackTest.php
Role: Unit test script
Content type: text/plain
Description: For testing
Class: Equation Operating System
Solve equations with multiple variables
Author: By
Last change:
Date: 8 years ago
Size: 417 bytes
 

Contents

Class file image Download
<?php

require_once __DIR__ . "/../../vendor/autoload.php";

use
jlawrence\eos\Stack;

class
StackTest extends PHPUnit_Framework_TestCase
{
    public function
testClearGetStack()
    {
       
$stack = new Stack();
       
$stack->push("1");
       
$stack->push("2");
       
$this->assertEquals(array("1", "2"), $stack->getStack());
       
$stack->clear();
       
$this->assertFalse($stack->getStack());
    }
}