Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Master bugfix protocol list #947

Merged
merged 7 commits into from
Feb 27, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 27 additions & 30 deletions CHANGED
Original file line number Diff line number Diff line change
@@ -1,37 +1,34 @@
2021-02-27 - Feature parse optimize (#926)
2021-02-27 - Merge branch 'master' into master_bugfix_protolist and updated CHANGED
2021-02-27 - Display protocol list
bugfix:
00_SIGNALDuino:
Msg type MC is not displayed in the protocol list

Feature:
00_SIGNALduino.pm: Feature parse optimize (#926)
Modified parse_Mx subs to two arguments, and improved input validation to avoid
perl warnigs if corrupt data is processed.
Addd tests for input validation subs: _limit_to_number and _limit_to_hex
Reworked existing tests to be compatible with new sub format

2021-02-19
00_SIGNALduino:
Addd test for _limit_to_number and _limit_to_hex
Removed sub _limit_to_MC_pattern

* 00_SIGNALduino.pm
Modified parse_Mx subs to two arguments, and improved input validation to avoid perl warnigs if corrupt data is processed.
Addd tests for input validation subs: _limit_to_number and _limit_to_hex
Reworked existing tests to be compatible with new sub format
2021-02-13

* Added parseData test for 41_OREGON to prevent coverage decrease
- Migrated 98 Unittest Tests to FHEM compatible prove test (#940)
* Migrate tests based on 98_unittest to fhem prove compatible test mode
* Migrated more tests and testdat
* Fixed return from prepare_fash
* Move Lib Tests to t Folder,to avoid running these tests under fhem testevn

2021-02-12
00_SIGNALDuino: Bugfix, module runs now without fhemweb instance

2021-02-19 - 00_SIGNALduino
Addd test for _limit_to_number and _limit_to_hex
Removed sub _limit_to_MC_pattern
2021-02-15 - Merge branch 'feature_parse-Optimize' of ssh://github.com/RFD-FHEM/RFFHEM into feature_parse-Optimize
2021-02-13 - 00_SIGNALduino:
corrected rmsg regexes
2021-02-13 -
00_SIGNALduino:
Modified SIGNALduino_Parse_MC to use less parameters and check data to be more robust
SIGNALduino_Parse | check raw´s | extension code for no warnings #917

2021-02-13 -
Tests:
Migrated 98 Unittest Tests to FHEM compatible prove test (#940)
Migrate tests based on 98_unittest to fhem prove compatible test mode
Migrated more tests and testdat
Fixed return from prepare_fash
Move Lib Tests to t Folder,to avoid running these tests under fhem testevn
00_SIGNALDuino:
Bugfix, module runs now without fhemweb instance

2021-01-28 - Remote control SEAV BeSmart S4 (#933)
change elsif to if
TR_502MSV [P34] funktionierte nicht mehr
2021-01-28 -
Feature: Remote control SEAV BeSmart S4 (#933)

2021-01-22 - Set commands changed
2020-12-30 - rename "get raw" to "get rawmsg" (#925)
Expand Down
4 changes: 2 additions & 2 deletions FHEM/00_SIGNALduino.pm
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ use lib::SD_Protocols;


use constant {
SDUINO_VERSION => '3.5.1+20210212',
SDUINO_VERSION => '3.5.1+20210227',
SDUINO_INIT_WAIT_XQ => 1.5, # wait disable device
SDUINO_INIT_WAIT => 2,
SDUINO_INIT_MAXRETRY => 3,
Expand Down Expand Up @@ -3800,7 +3800,7 @@ sub SIGNALduino_FW_getProtocolList {
my $msgtype = '';
my $chkbox;

if (defined $hash->{protocolObject}->getProperty($id,'format') && $hash->{protocolObject}->getProperty($id,'format' eq 'manchester'))
if (defined $hash->{protocolObject}->getProperty($id,'format') && $hash->{protocolObject}->getProperty($id,'format') eq 'manchester')
{
$msgtype = 'MC';
}
Expand Down
2 changes: 1 addition & 1 deletion controls_signalduino.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
UPD 2021-02-27_16:05:28 223927 FHEM/00_SIGNALduino.pm
UPD 2021-02-27_16:48:42 223927 FHEM/00_SIGNALduino.pm
UPD 2020-06-15_17:41:39 17876 FHEM/10_FS10.pm
UPD 2020-05-26_11:51:12 20465 FHEM/10_SD_GT.pm
UPD 2016-09-18_21:22:06 10111 FHEM/14_BresserTemeo.pm
Expand Down
39 changes: 39 additions & 0 deletions t/FHEM/00_SIGNALduino/03_SIGNALduino_FW_getProtocolList.t
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
#!/usr/bin/env perl
use strict;
use warnings;

use Test2::V0;
use Test2::Tools::Compare qw{is field U D match hash bag };
use Test2::Todo;

use File::Basename;
our %defs;
our %attr;

InternalTimer(time()+1, sub() {
my $target = shift;
my $targetHash = $defs{$target};

my $path=dirname(__FILE__);
my $LoadResult = $targetHash->{protocolObject}->LoadHash($path."/test_loadprotohash-ok.pm");

is($LoadResult,undef,"load test protocol hash ");


subtest 'Verify returns of SIGNALduino_FW_getProtocolList ' => sub {
plan(4);
my $ret;
$ret = SIGNALduino_FW_getProtocolList($target);

like($ret,qr,<div>MC</div>,,'MC is located in return');
like($ret,qr,<div>MS</div>,,'MS is located in return');
like($ret,qr,<div>MU</div>,,'MU is located in return');
like($ret,qr,<div>MN</div>,,'MN is located in return');
};

done_testing();
exit(0);

}, 'dummyDuino');

1;