Skip to content

Commit

Permalink
Add null check for empty values
Browse files Browse the repository at this point in the history
  • Loading branch information
hxtree committed Jan 2, 2022
1 parent eb7f237 commit eec75ce
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CODING_STANDARDS.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,3 +100,5 @@
```

Rule inherited from [PHP](https://github.com/php/php-src/edit/master/CODING_STANDARDS.md).

5. All code must adhere to automated coding style checks.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ docker run -it --mount type=bind,source="$(pwd)"/,target=/application/ phpmarkup
* Update or add tests to avoid the change breaking in future releases.

```
docker run -it --mount type=bind,source="$(pwd)"/,target=/application/ phpmarkup:latest composer qa
docker run -it --mount type=bind,source="$(pwd)"/,target=/application/ phpmarkup:latest composer qc
```

### Step 4
Expand Down
2 changes: 2 additions & 0 deletions tests/src/Unit/Element/AbstractElementTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ public function testGetArgByName()
{
$this->element->args['test'] = 'pass';
$this->assertEquals('pass', $this->element->getArgByName('test'));

$this->assertEquals(null, $this->element->getArgByName('doesntexist'));
}

/**
Expand Down

0 comments on commit eec75ce

Please sign in to comment.