Skip to content

Commit

Permalink
DEV: Update darwin test_cluster.zapt
Browse files Browse the repository at this point in the history
  • Loading branch information
jmeg-sfy committed Dec 15, 2021
1 parent 77b61aa commit bbea0a6
Show file tree
Hide file tree
Showing 3 changed files with 4,805 additions and 2,153 deletions.
12 changes: 9 additions & 3 deletions src/darwin/Framework/CHIP/templates/partials/test_cluster.zapt
Original file line number Diff line number Diff line change
Expand Up @@ -135,19 +135,25 @@ ResponseHandler {{> subscribeDataCallback}} = nil;
{{#if expectedConstraints.minValue}}
{
{{> actualValue}}
XCTAssertGreaterThanOrEqual([actualValue {{asObjectiveCNumberType "" type true}}Value], {{expectedConstraints.minValue}});
if (actualValue != nil) {
XCTAssertGreaterThanOrEqual([actualValue {{asObjectiveCNumberType "" type true}}Value], {{expectedConstraints.minValue}});
}
}
{{/if}}
{{#if expectedConstraints.maxValue}}
{
{{> actualValue}}
XCTAssertLessThanOrEqual([actualValue {{asObjectiveCNumberType "" type true}}Value], {{expectedConstraints.maxValue}});
if (actualValue != nil) {
XCTAssertLessThanOrEqual([actualValue {{asObjectiveCNumberType "" type true}}Value], {{expectedConstraints.maxValue}});
}
}
{{/if}}
{{#if expectedConstraints.notValue}}
{
{{> actualValue}}
XCTAssertNotEqual([actualValue {{asObjectiveCNumberType "" type true}}Value], {{expectedConstraints.notValue}});
if (actualValue != nil) {
XCTAssertNotEqual([actualValue {{asObjectiveCNumberType "" type true}}Value], {{expectedConstraints.notValue}});
}
}
{{/if}}
{{/if}}
Expand Down
Loading

0 comments on commit bbea0a6

Please sign in to comment.