<?php

namespace Bolt\Extension\Leskis\BoltFieldGeojson\Tests;

use Bolt\Tests\BoltUnitTest;
use Bolt\Extension\Leskis\BoltFieldGeojson\BoltFieldGeojsonExtension;

/**
 * BoltFieldGeojson testing class.
 *
 * @author Nicolas Béhier-Dévigne
 */
class ExtensionTest extends BoltUnitTest
{
    /**
     * Ensure that the BoltSendEmailForNewContent extension loads correctly.
     */
    public function testExtensionBasics()
    {
        $app = $this->getApp(false);
        $extension = new BoltSendEmailForNewContentExtension($app);

        $name = $extension->getName();
        $this->assertSame($name, 'BoltSendEmailForNewContent');
        $this->assertInstanceOf('\Bolt\Extension\ExtensionInterface', $extension);
    }

    public function testExtensionComposerJson()
    {
        $composerJson = json_decode(file_get_contents(dirname(__DIR__) . '/composer.json'), true);

        // Check that the 'bolt-class' key correctly matches an existing class
        $this->assertArrayHasKey('bolt-class', $composerJson['extra']);
        $this->assertTrue(class_exists($composerJson['extra']['bolt-class']));

        // Check that the 'bolt-assets' key points to the correct directory
        $this->assertArrayHasKey('bolt-assets', $composerJson['extra']);
        $this->assertSame('web', $composerJson['extra']['bolt-assets']);
    }
}

<?php

namespace Bolt\Extension\Leskis\BoltSendEmailForNewContent\Tests;

use Bolt\Tests\BoltUnitTest;
use Bolt\Extension\Leskis\BoltSendEmailForNewContent\BoltSendEmailForNewContentExtension;

/**
 * BoltSendEmailForNewContent testing class.
 *
 * @author Nicolas Béhier-Dévigne
 */
class ExtensionTest extends BoltUnitTest
{
    /**
     * Ensure that the BoltSendEmailForNewContent extension loads correctly.
     */
    public function testExtensionBasics()
    {
        $app = $this->getApp(false);
        $extension = new BoltSendEmailForNewContentExtension($app);

        $name = $extension->getName();
        $this->assertSame($name, 'BoltSendEmailForNewContent');
        $this->assertInstanceOf('\Bolt\Extension\ExtensionInterface', $extension);
    }

    public function testExtensionComposerJson()
    {
        $composerJson = json_decode(file_get_contents(dirname(__DIR__) . '/composer.json'), true);

        // Check that the 'bolt-class' key correctly matches an existing class
        $this->assertArrayHasKey('bolt-class', $composerJson['extra']);
        $this->assertTrue(class_exists($composerJson['extra']['bolt-class']));

        // Check that the 'bolt-assets' key points to the correct directory
        $this->assertArrayHasKey('bolt-assets', $composerJson['extra']);
        $this->assertSame('web', $composerJson['extra']['bolt-assets']);
    }
}

Fix first functional test class
Fix first functional test class