Unit tests for DiagramContainer#32
Conversation
Details: - Debug function call fixed in DiagramContainer constructor - "new_backend" parameter name deleted in deleted DiagramContainer and Element constructors - source and header files added to test.pro file
Details: - Switching to test fixture - ParentReferencingWorks test is failing, printing additional information
Details: - Bug fix in DiagramContainer::parent function
…tDiagramContainer Details: - Using QSignalSpy class, testlib added to Qt components in test.pro
Details:
- test.pro file now includes every cpp and header file
- backend and serial_port tests create an object
|
@KGergo88 I've been trying to improve the coverage but checking Coveralls results for the diagram_container.cpp and hpp files the analytics seems to be off. Seems to me like random lines are marked as uncovered (example lines 160-169 in diagram_container.cpp). Checking other files I found some other lines marked uncovered that seem inaccurate (example measurement_data_protocoll.hpp lines 53/54/65, diagram.hpp line 59). I've tried looking into it but could not find the cause yet. Any ideas? Should I open a separate issue for this and carry on with finishing up this PR regardless? |
Yep, that is odd. You can also try to generate coverage locally with this script: https://github.com/KGergo88/RDB_Diplomaterv_Monitor/blob/master/tests/test_coverage.py If that says ok, then we could merge it. |
Great, thanks! :) This does give me some different numbers and the line-by-line analysis is more usable so I can refine the tests. |
|
Strange, this should be more or less the same. Maybe the Coveralls data is created wrong? See last line here: https://github.com/KGergo88/RDB_Diplomaterv_Monitor/blob/master/.travis.yml |

Tests added for DiagramContainer. Coverage is not complete.