-
Notifications
You must be signed in to change notification settings - Fork 90
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
Tests failing #16
Comments
What directory are you running the test from? It must be run from the test source directory. Sent from my iPhone
|
I am running it from cppagent/test . Here cppagent is the repository root folder. |
Did you try debugging the set fault and see where it is occurring? Sent from my iPhone
|
gdb run ends with this. Program received signal SIGSEGV, Segmentation fault. Also a backtrace report is here: (gdb) bt |
Looks like a stack corruption. What platform are you testing on? Sent from my iPhone
|
The platform is mentioned as Fedora 21 and GNU Compiler Collection 4.9.2. I am able to reproduce the segmentation fault on Fedora 20 with GNU Compiler Collection 4.8.2. |
Probably compiler related. Not sure if it is a real problem or an artifact of the version. We should do some additional testing. I'll check on os x with some memory profiling. Sent from my iPhone
|
@wsobel, I git reset the commits one by one and found the last commit hash that compiled successfully and tests ran correctly on my machine is 0a7ba0c. Also I noticed AgentTest::testAdapterDeviceCommand test was not there in the above mentioned hash. Another thing I noticed is the error says it couldn't load the file two_devices.xml from samples folder, if you look into the samples folder there is no such two_devices.xml file. Can that be the cause of the error? AgentTest::testAdapterDeviceCommand 3798 ERROR [0] xml.parser: XML: I/O 3798 FATAL [0] agent: Error loading xml configuration: ../samples/two_devices.xml |
I'll check and make sure the file was pushed. Thanks for the analysis. Sent from my iPhone
|
Added and push two_devices.xml |
* Stored checkpoints with a std::vector rather than a raw array allocated on the heap
Refactored storage for checkpoints (#16)
While running the tests i am getting errors. Running on Fedora 21, gcc 4.9.2
Steps followed:
[subho@localhost] test $ (master) ./agent_test
AdapterTest::testAdapter : OK
AgentTest::testConstructor 104 ERROR [0] xml.parser: XML: I/O
104 ERROR [0] xml.parser: XML: warning :
104 ERROR [0] xml.parser: XML: failed to load external entity "../samples/badPath.xml"
104 FATAL [0] agent: Error loading xml configuration: ../samples/badPath.xml
104 FATAL [0] agent: Error detail: XML Error at /home/subho/work/github/cppagent/agent/xml_parser.cpp(74): mDoc = xmlReadFile(aPath.c_str(), NULL, XML_PARSE_NOBLANKS)
XML Error at /home/subho/work/github/cppagent/agent/xml_parser.cpp(74): mDoc = xmlReadFile(aPath.c_str(), NULL, XML_PARSE_NOBLANKS)
: OK
AgentTest::testBadPath : OK
AgentTest::testProbe : OK
AgentTest::testBadXPath 116 ERROR [0] xml.parser: XML: Invalid expression
116 ERROR [0] xml.parser: XML: Invalid expression
116 ERROR [0] xml.parser: XML: Invalid expression
116 ERROR [0] xml.parser: XML: Invalid predicate
116 ERROR [0] xml.parser: XML: Invalid expression
: OK
AgentTest::testXPath : OK
AgentTest::testBadCount : OK
AgentTest::testBadFreq : OK
AgentTest::testGoodPath : OK
AgentTest::testEmptyStream : OK
AgentTest::testBadDevices : OK
AgentTest::testAddAdapter : OK
AgentTest::testAddToBuffer : OK
AgentTest::testAdapter : OK
AgentTest::testCurrentAt : OK
AgentTest::testCurrentAt64 : OK
AgentTest::testCurrentAtOutOfRange : OK
AgentTest::testSampleAtNextSeq : OK
AgentTest::testAdapterCommands : OK
AgentTest::testFileDownload : OK
AgentTest::testFailedFileDownload 410 ERROR [0] agent: Cannot register file: ./BadFileName.xsd: Unable to find file ./BadFileName.xsd
: OK
AgentTest::testDuplicateCheck : OK
AgentTest::testAutoAvailable : OK
AgentTest::testIgnoreTimestamps : OK
AgentTest::testAssetStorage : OK
AgentTest::testAssetError : OK
AgentTest::testAssetBuffer : OK
AgentTest::testPut : OK
AgentTest::testPutBlocking : OK
AgentTest::testPutBlockingFrom : OK
AgentTest::testAdapterAddAsset : OK
AgentTest::testMultiLineAsset : OK
AgentTest::testAssetProbe : OK
AgentTest::testAssetStorageWithoutType : OK
AgentTest::testStreamData : OK
AgentTest::testSequenceNumberRollover : OK
AgentTest::testSampleCount : OK
AgentTest::testStreamDataObserver : OK
AgentTest::testFailWithDuplicateDeviceUUID 3665 ERROR [0] xml.parser: XML: I/O
3665 ERROR [0] xml.parser: XML: warning :
3665 ERROR [0] xml.parser: XML: failed to load external entity "../samples/dup_uuid.xml"
3665 FATAL [0] agent: Error loading xml configuration: ../samples/dup_uuid.xml
3665 FATAL [0] agent: Error detail: XML Error at /home/subho/work/github/cppagent/agent/xml_parser.cpp(74): mDoc = xmlReadFile(aPath.c_str(), NULL, XML_PARSE_NOBLANKS)
XML Error at /home/subho/work/github/cppagent/agent/xml_parser.cpp(74): mDoc = xmlReadFile(aPath.c_str(), NULL, XML_PARSE_NOBLANKS)
: OK
AgentTest::testMultipleDisconnect : OK
AgentTest::testRelativeTime : OK
AgentTest::testRelativeParsedTime : OK
AgentTest::testRelativeParsedTimeDetection : OK
AgentTest::testRelativeOffsetDetection : OK
AgentTest::testDynamicCalibration : OK
AgentTest::testInitialTimeSeriesValues : OK
AgentTest::testUUIDChange : OK
AgentTest::testFilterValues : OK
AgentTest::testReferences : OK
AgentTest::testDiscrete : OK
AgentTest::testUpcaseValues : OK
AgentTest::testConditionSequence : OK
AgentTest::testAssetRemoval : OK
AgentTest::testAssetRemovalByAdapter : OK
AgentTest::testAssetAdditionOfAssetChanged12 : OK
AgentTest::testAssetAdditionOfAssetRemoved13 : OK
AgentTest::testAssetPrependId : OK
AgentTest::testBadAsset 3773 ERROR [0] xml.parser: XML: file://111.xml:1:
3773 ERROR [0] xml.parser: XML: parser
3773 ERROR [0] xml.parser: XML: error :
3773 ERROR [0] xml.parser: XML: Opening and ending tag mismatch: CuttingItem line 1 and CuttingItmems
3773 ERROR [0] xml.parser: XML: 0
3773 ERROR [0] xml.parser: XML: ^
3773 ERROR [0] xml.parser: XML: file://111.xml:1:
3773 ERROR [0] xml.parser: XML: parser
3773 ERROR [0] xml.parser: XML: error :
3773 ERROR [0] xml.parser: XML: Opening and ending tag mismatch: CuttingItem line 1 and CuttingToolLifeCycle
3773 ERROR [0] xml.parser: XML: nominal="0">0
3773 ERROR [0] xml.parser: XML: ^
3773 ERROR [0] xml.parser: XML: file://111.xml:1:
3773 ERROR [0] xml.parser: XML: parser
3773 ERROR [0] xml.parser: XML: error :
3773 ERROR [0] xml.parser: XML: Opening and ending tag mismatch: CuttingItem line 1 and CuttingTool
3774 ERROR [0] xml.parser: XML: </CuttingTool
3774 ERROR [0] xml.parser: XML: ^
3774 ERROR [0] xml.parser: XML: file://111.xml:2:
3774 ERROR [0] xml.parser: XML: parser
3774 ERROR [0] xml.parser: XML: error :
3774 ERROR [0] xml.parser: XML: Premature end of data in tag CuttingItems line 1
3774 ERROR [0] xml.parser: XML:
3774 ERROR [0] xml.parser: XML: ^
3774 ERROR [0] xml.parser: XML: file://111.xml:2:
3774 ERROR [0] xml.parser: XML: parser
3774 ERROR [0] xml.parser: XML: error :
3774 ERROR [0] xml.parser: XML: Premature end of data in tag CuttingToolLifeCycle line 1
3774 ERROR [0] xml.parser: XML:
3774 ERROR [0] xml.parser: XML: ^
3774 ERROR [0] xml.parser: XML: file://111.xml:2:
3774 ERROR [0] xml.parser: XML: parser
3774 ERROR [0] xml.parser: XML: error :
3774 ERROR [0] xml.parser: XML: Premature end of data in tag CuttingTool line 1
3774 ERROR [0] xml.parser: XML:
3774 ERROR [0] xml.parser: XML: ^
3774 ERROR [0] xml.parser: Cannot parse asset XML, Unknown execption occurred
3774 ERROR [0] agent: addAssete: Error parsing asset
: OK
AgentTest::testAssetWithSimpleCuttingItems : OK
AgentTest::testRemoveLastAssetChanged : OK
AgentTest::testRemoveAllAssets : OK
AgentTest::testEmptyLastItemFromAdapter : OK
AgentTest::testAdapterDeviceCommand 3798 ERROR [0] xml.parser: XML: I/O
3798 ERROR [0] xml.parser: XML: warning :
3798 ERROR [0] xml.parser: XML: failed to load external entity "../samples/two_devices.xml"
3798 FATAL [0] agent: Error loading xml configuration: ../samples/two_devices.xml
3798 FATAL [0] agent: Error detail: XML Error at /home/subho/work/github/cppagent/agent/xml_parser.cpp(74): mDoc = xmlReadFile(aPath.c_str(), NULL, XML_PARSE_NOBLANKS)
XML Error at /home/subho/work/github/cppagent/agent/xml_parser.cpp(74): mDoc = xmlReadFile(aPath.c_str(), NULL, XML_PARSE_NOBLANKS)
Segmentation fault (core dumped)
The text was updated successfully, but these errors were encountered: