Skip to content

Commit

Permalink
Added a few tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ircmaxell committed Jun 28, 2011
1 parent 076b061 commit fc93886
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions test/Unit/Cipher/Block/Implementation/DESTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,5 +84,15 @@ public function testDecrypt($key, $data, $expected) {
$enc = $cipher->decryptBlock(base64_decode($data), base64_decode($key));
$this->assertEquals($expected, base64_encode($enc));
}

public function testBlockSize() {
$cipher = new \CryptLib\Cipher\Block\Implementation\DES('des');
$this->assertEquals(8, $cipher->getBlockSize('foo'));
}

public function testGetCipher() {
$cipher = new \CryptLib\Cipher\Block\Implementation\DES('des');
$this->assertEquals('des', $cipher->getCipher());
}

}

0 comments on commit fc93886

Please sign in to comment.