New:Introducing Socket Scanning for VS Code Marketplace Extensions.Learn more →
Get Started

ackintosh/toumi

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ackintosh/toumi

Library to include the legacy code.

Source
Packagist
Version
1.1
Version published
Total downloads
3.9K
Maintainers
1
Created
Source

Toumi

A library for including legacy php file.

Build Status

Usage

legacy.php

<?php
function hoge($arg)
{
    return 'hoge' . $arg;
}

somefunction(1234);

function fuga()
{
    $f = function () { echo 'fuga'; };
    call_user_func($f);
}

var_dump(hoge('hogehoge'));
exit;
<?php
// Only function declaration is included.
\Ackintosh\Toumi::load('legacy.php');

class LegacyTest extends PHPUnit_Framework_TestCase
{
    /**
     * @test
     */
    public function hoge()
    {
        $this->assertSame('hogefuga', hoge('fuga'));
    }
}

Author

Akihito Nakano

Keywords

legacy

FAQs

Package last updated on 27 Sep 2017

Related posts