Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
reziamini committed Dec 22, 2020
1 parent fb26e56 commit c44d974
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/DirectivesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -148,12 +148,15 @@ public function testImageDirective()
public function testStyleDirective()
{
$this->assertEquals("<link href='http://localhost/style.css' rel='stylesheet'>", $this->compiler->compileString("@style('style.css')"));
$this->assertEquals("<link href='https://localhost/style.css' rel='stylesheet'>", $this->compiler->compileString("@style('style.css', true)"));
}

public function testScriptDirective()
{
$this->assertEquals("<script src='http://localhost/script.js' defer></script>", $this->compiler->compileString("@script('script.js', true)"));
$this->assertEquals("<script src='http://localhost/script.js' defer></script>", $this->compiler->compileString("@script('script.js', false, true)"));
$this->assertEquals("<script src='http://localhost/script.js'></script>", $this->compiler->compileString("@script('script.js')"));
$this->assertEquals("<script src='https://localhost/script.js'></script>", $this->compiler->compileString("@script('script.js', true)"));
$this->assertEquals("<script src='https://localhost/script.js' defer></script>", $this->compiler->compileString("@script('script.js', true, true)"));
}

public function testConfigDirectiveStyle()
Expand Down

0 comments on commit c44d974

Please sign in to comment.