make tests compatible with older php syntax (phpunit still requires 5.6), update readme, update examples to ease testing modbus
parent
6137326277
commit
7ea3d8007e
@ -0,0 +1,20 @@ |
||||
language: php |
||||
|
||||
sudo: false |
||||
|
||||
cache: |
||||
directories: |
||||
- $HOME/.composer/cache |
||||
|
||||
php: |
||||
- 5.6 |
||||
- 7.0 |
||||
|
||||
before_install: |
||||
- travis_retry composer self-update |
||||
|
||||
install: |
||||
- travis_retry composer update --no-interaction |
||||
|
||||
script: |
||||
- composer test-ci |
@ -0,0 +1,12 @@ |
||||
<?php |
||||
|
||||
$ipPrefix = '192.192.15.'; // change to '' if you want to allow request to be sent to every possible ip |
||||
|
||||
$ip = '192.192.15.51'; |
||||
if (isset($_GET['ip']) && filter_var($ipPrefix . $_GET['ip'], FILTER_VALIDATE_IP)) { |
||||
$ip = $ipPrefix . $_GET['ip']; |
||||
} |
||||
|
||||
$unitId = isset($_GET['unitid']) ? (int)$_GET['unitid'] : 0; |
||||
$reference = isset($_GET['reference']) ? (int)$_GET['reference'] : 12288; |
||||
$quantity = isset($_GET['quantity']) ? (int)$_GET['quantity'] : 6; |
Loading…
Reference in new issue