You are here

public function JSDelivrTest::test_setgetScheme in Libraries CDN API 7

@covers ::setScheme() @covers ::getScheme()

File

tests/src/Plugin/LibrariesCDN/JSDelivrTest.php, line 47
Contains \Drupal\Tests\Libraries_cdn\Plugin\LibrariesCDN\JSDelivrTest.

Class

JSDelivrTest
@coversDefaultClass \Drupal\libraries_cdn\Plugin\LibrariesCDN\JSDelivr

Namespace

Drupal\Tests\libraries_cdn\Plugin\LibrariesCDN

Code

public function test_setgetScheme() {
  $this
    ->assertEquals('http', $this->plugin
    ->getScheme());
  $this
    ->assertEquals('ftp', $this->plugin
    ->getScheme('ftp'));
  $this->plugin
    ->setScheme('https');
  $this
    ->assertEquals('https', $this->plugin
    ->getScheme());
  $this->plugin
    ->setScheme();
  $this
    ->assertEquals('http', $this->plugin
    ->getScheme());
}