Refactore all test to be independent

This commit is contained in:
Jakub Zelenka 2018-05-17 20:15:14 +01:00
parent 3bb4d28798
commit 4aabe3c966
26 changed files with 306 additions and 108 deletions

21
tests/gnupgt.inc Normal file
View file

@ -0,0 +1,21 @@
<?php
require_once __DIR__ . "/vars.inc";
class gnupgt {
static function import_key()
{
global $testkey;
self::delete_key();
$gpg = new gnupg();
$gpg->import($testkey);
}
static function delete_key()
{
@unlink(__DIR__ . "/pubring.gpg");
@unlink(__DIR__ . "/secring.gpg");
}
}