Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Table 14: Tests in SensorWithGraphResourceTest

SensorWithGraphDAOTest


Name

Expected result

Parameters

Actual result

SuccessComments
1getSensorLinkedWithGraphsCorrectly()

Expect a result that is not null.


Returns something that is not null.Yes
2
getUserTabsSQLException()

Throws a SQLException that in return throws a DatabaseException.


A DatabaseException is thrown.Yes

Table 15: Tests in SensorWithGraphDAOTest

GaugeGraphSettings tests

GaugeGraphService


Name

Expected result

Parameters

Actual result

SuccessComments
1





Table 13: Test in SensorServiceTest

SensorSettingsResourceTest


Name

Expected result

Parameters

Actual result

SuccessComments
1





2





3





Table 14: Tests in SensorWithGraphResourceTest

GaugeGraphSettingsDAOTest


Name

Expected result

Parameters

Actual result

SuccessComments
1getSensorSettingsForGauge()

Expect a result that is not null.


Returns something that is not null.Yes
2
getSensorSettingsForLinechart()

Expect a result that is not null.


A DatabaseException is thrown.Yes
3getSensorSettingsForGaugeException()Throws a SQLException that in return throws a DatabaseException.
A DatabaseException is thrown.No

Table 15: Tests in SensorWithGraphDAOTest

DtoTest

This class tests if the DTO's do not contain any logic and only getters and setters. The testPojoStructureAndBehavior() function executes this test. Pojo is a dependency that can be used for this kind of testing.

...