PHP Package: kkszymanowski/traitor

Trait library for PHP allowing easy creation of test doubles for unit tests.

Current Version: 1.1.0
Last Updated: 2024-01-29
PHP Requirement: >=5.4
Dependencies:
phpunit/phpunit
⚠️ To ensure full functionality, the above dependencies might be required.

Package Description

Traitor is a PHP library that provides a simple and efficient way to create mock objects and stubs for unit testing. It helps developers write test cases with minimal effort and supports various testing scenarios.

📦 Show all available classes🔗 View on GitHub

Download Latest Version: 1.1.0

Download Download v1.1.0

Code Integration Example

Make sure to include the correct namespace and class paths for proper usage.

<?php
// Example from PHPlibraries.com
require_once 'libs/kkszymanowski/traitor/1.1.0/loader.php';
require_once 'libs/sebastianbergmann/phpunit/12.4.1/loader.php';

use kkszymanowski\traitor\MockBuilder;

$obj = new MockBuilder();
echo '✅ Test OK: ' . get_class($obj);
?>

We aim to make using PHP packages easier without Composer. If something doesn't work, let us know — we'll fix it promptly.

Community Discussion

Ask questions, share tips, or report issues below.