GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 100.0% 9 / 0 / 9
Functions: 100.0% 1 / 0 / 1
Branches: 86.7% 13 / 0 / 15

src/energyplus/ForwardTranslator/ForwardTranslateOutputControlReportingTolerances.cpp
Line Branch Exec Source
1 /***********************************************************************************************************************
2 * OpenStudio(R), Copyright (c) Alliance for Energy Innovation, LLC.
3 * See also https://openstudio.net/license
4 ***********************************************************************************************************************/
5
6 #include "../ForwardTranslator.hpp"
7 #include "../../model/Model.hpp"
8 #include "../../model/OutputControlReportingTolerances.hpp"
9 #include <utilities/idd/OutputControl_ReportingTolerances_FieldEnums.hxx>
10 #include "../../utilities/idd/IddEnums.hpp"
11 #include <utilities/idd/IddEnums.hxx>
12 #include <utilities/idd/IddFactory.hxx>
13
14 using namespace openstudio::model;
15
16 using namespace std;
17
18 namespace openstudio {
19
20 namespace energyplus {
21
22 11 boost::optional<IdfObject> ForwardTranslator::translateOutputControlReportingTolerances(OutputControlReportingTolerances& modelObject) {
23
24
2/2
✓ Branch 1 taken 11 times.
✓ Branch 4 taken 11 times.
11 IdfObject idfObject = createAndRegisterIdfObject(openstudio::IddObjectType::OutputControl_ReportingTolerances, modelObject);
25
26 11 boost::optional<double> value;
27
28
3/4
✓ Branch 1 taken 11 times.
✓ Branch 4 taken 11 times.
✓ Branch 7 taken 11 times.
✗ Branch 8 not taken.
22 if ((value = modelObject.toleranceforTimeCoolingSetpointNotMet())) {
29
2/2
✓ Branch 1 taken 11 times.
✓ Branch 4 taken 11 times.
11 idfObject.setDouble(OutputControl_ReportingTolerancesFields::ToleranceforTimeCoolingSetpointNotMet, value.get());
30 }
31
32
3/4
✓ Branch 1 taken 11 times.
✓ Branch 4 taken 11 times.
✓ Branch 7 taken 11 times.
✗ Branch 8 not taken.
22 if ((value = modelObject.toleranceforTimeHeatingSetpointNotMet())) {
33
2/2
✓ Branch 1 taken 11 times.
✓ Branch 4 taken 11 times.
11 idfObject.setDouble(OutputControl_ReportingTolerancesFields::ToleranceforTimeHeatingSetpointNotMet, value.get());
34 }
35
36
1/1
✓ Branch 1 taken 11 times.
22 return idfObject;
37 11 }
38
39 } // namespace energyplus
40
41 } // namespace openstudio
42