mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2024-09-15 08:56:01 +00:00
20862be7d0
- slim/slim: ^3.1 - symfony/expression-language: ^3.4 - fxp/composer-asset-plugin: ~1.3 - bower-asset/vue: ^2.5 - bower-asset/vue-resource: ^1.5
38 lines
968 B
PHP
38 lines
968 B
PHP
<?php
|
|
|
|
/*
|
|
* This file is part of the Fxp Composer Asset Plugin package.
|
|
*
|
|
* (c) François Pluchino <francois.pluchino@gmail.com>
|
|
*
|
|
* For the full copyright and license information, please view the LICENSE
|
|
* file that was distributed with this source code.
|
|
*/
|
|
|
|
namespace Fxp\Composer\AssetPlugin\Tests\Converter;
|
|
|
|
use Fxp\Composer\AssetPlugin\Converter\NpmPackageUtil;
|
|
|
|
/**
|
|
* Tests of npm package util.
|
|
*
|
|
* @author François Pluchino <francois.pluchino@gmail.com>
|
|
*/
|
|
class NpmPackageUtilTest extends AbstractPackageConverterTest
|
|
{
|
|
public function testConvertName()
|
|
{
|
|
$packageName = '@vendor/package';
|
|
$expected = 'vendor--package';
|
|
|
|
$this->assertSame($expected, NpmPackageUtil::convertName($packageName));
|
|
}
|
|
|
|
public function testRevertName()
|
|
{
|
|
$packageName = 'vendor--package';
|
|
$expected = '@vendor/package';
|
|
|
|
$this->assertSame($expected, NpmPackageUtil::revertName($packageName));
|
|
}
|
|
}
|