Skip to content
This repository has been archived by the owner on Nov 19, 2019. It is now read-only.

Commit

Permalink
ensures that the validation list is never null to fix #75
Browse files Browse the repository at this point in the history
  • Loading branch information
travi committed Nov 27, 2014
1 parent b65607d commit ebd914f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ public function addValidations($list, $form)

public function getDependencies()
{
$this->lazyInitializeList('validations');
$this->sortStyleSheets();

return $this->requirementLists;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -660,11 +660,12 @@ public function testEmptyStringNotAddedWhenReturnedAsDependency()

public function testThatEmptyListsReturnedIfNoDependenciesToList()
{
$dependencies = $this->dependencyManager->getDependencies();
$dependencies = $this->dependencyManager->getDependenciesInProperForm();

$this->assertEmpty(array(), $dependencies['css']);
$this->assertEquals(array(), $dependencies['js']);
$this->assertEquals(array(), $dependencies['clientTemplates']);
$this->assertEquals(array(), $dependencies['validations']);
}

public function testThatCriticalJsListIncludesModernizr()
Expand Down

0 comments on commit ebd914f

Please sign in to comment.