Project

General

Profile

User story #188

Updated by Ivan Herrero about 9 years ago

Define the base infrastructure for object introspection.
This would satisfy requirements:
* MARTe-EX-F-2.2.1: The framework shall allow to fully introspect the properties of any of its object.
* MARTe-EX-F-2.2.2: The framework shall allow to introspect the class name of any of its objects.
* MARTe-EX-F-2.2.3: The framework shall allow to introspect the class type of any of its objects.

h1. Source code files modified

* L0Types/BasicTypes.h
* L0Types/CompilerTypes.h
* L0Types/Introspection.h (Moved to L2Objects)
* L0Types/TypeDescriptor.h (Moved to L1Portability)
* L0Types/ZeroTerminatedArray.h
* L1Portability/ErrorManagement.h
* L1Portability/FormatDescriptor.cpp
* L1Portability/TypeDescriptor.*
* L1Portability/StringHelper.h
* L2Objects/ClassRegistryItem.*
* L2Objects/IntrospectionEntry.*
* L2Objects/Introspection.*
* L3Streams/IOBuffer.cpp
* L4Configuration/ConfigurationDatabase.*
* L4Configuration/TypeConversion.*
* L4Configuration/ValidateBasicType.*
* L3Streams/IOBuffer.*
* Lib/IntrospectionParser.*

h1. Architecture & design review

*Date of the review:* 31/07/2015

*Person who did the review:* Andre' Neto

*Version of architecture & design document:* N/A. As per the original MARTe implementation, this is a support function and does not require formal design in UML.

*Result of review:* N/A

*List of non-conformities:* N/A

h1. Code and documentation review

*Date of the review:* 01/02/2016

*Person who did the review:* Andre' Neto

*Result of review:* PASS PASS*

*List of non-conformities:*

* During Specific Walk:
*

File ./Source/Core/BareMetal/L3Streams/IOBufferIntegerPrint.cpp line 531: MARTe::BitSetToInteger(?, ?, ?, 8?, !=0) #1
*

File ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h line 345: MARTe::BitSetToBitSet([1], 0, 8, 1, ?, ?, 8?, !=0) #2
*

File ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h line 286: MARTe::BSToBS([1], 0, 8, 1, ?, 31? | 0?, 8?, !=0) #3
*

File ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h line 105: MARTe::MemoryOperationsHelper::Copy([4], ?, 5?) #31
* ./Source/Core/BareMetal/L1Portability/Environment/Generic/MemoryOperationsHelper_CLIB_Generic.cpp:58:1: Warning 669: Possible data overrun for function 'memcpy(void *, const void *, unsigned long)', argument 3 (size=5) exceeds argument 1 (size=4)
* ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h:101:1: Info 831: Reference cited in prior message
* ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h:105:1: Info 831: Reference cited in prior message
* ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h:227:1: Info 831: Reference cited in prior message
* ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h:242:1: Info 831: Reference cited in prior message
* ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h:286:1: Info 831: Reference cited in prior message
* ./Source/Core/BareMetal/L3Streams/BitSetToInteger.h:345:1: Info 831: Reference cited in prior message
* ./Source/Core/BareMetal/L3Streams/IOBufferIntegerPrint.cpp:528:1: Info 831: Reference cited in prior message
* ./Source/Core/BareMetal/L3Streams/IOBufferIntegerPrint.cpp:531:1: Info 831: Reference cited in prior message
* ./Source/Core/BareMetal/L4Configuration/ParserI.cpp:51:80: Note 9138: null statement not in line by itself [MISRA C++ Rule 6-2-3]

h1. Unit test review

*Date of the review:* 03/02/2015 02/02/2015

*Person who did the review:* Ivan Herrero

*Result of coverage tests review:* PASS

*Result of functional tests review:* PASS

*Result of review:* PASS

*List of non-conformities:*

* Object::Clone(), and Object::Initialise() are not tested, but it is fine because they are not really implemented, yet.
* LexicalAnalyzer.cpp, IOBufferFloatPrint.cpp, and IOBuffer.cpp have some error handdling branches not covered, that consist of a bit more than a simple error reporting sentence. Anyway, they have been left uncovered, because the error is hard to simulate.
* The following tests


Only
on Windows platform fail:

[----------] Global test environment tear-down
[==========] 2502 tests from 75 test cases ran. (78098 ms total)
[ PASSED ] 2462 tests.
[ FAILED ] 40 tests, listed below:
[ FAILED ] AnyObjectGTest.TestGetType_Scalar_String
[ FAILED ] AnyTypeGTest.TestAnyType_ConstCharPointerToConst
[ FAILED ] BufferedStreamIGTest.TestPrintFormatted_CCString_BufferSize_1
[ FAILED ] BufferedStreamIGTest.TestPrintFormatted_CCString_BufferSize_2
[ FAILED ] BufferedStreamIGTest.TestPrintFormatted_CCString_BufferSize_8
[ FAILED ] BufferedStreamIGTest.TestPrintFormatted_CCString_BufferSize_64
[ FAILED ] BufferedStreamIGTest.TestPrintFormatted_CCString_BufferSize_128
[ FAILED ] BufferedStreamIGTest.TestPrintFormatted_CCString_BufferSize_1024
[ FAILED ] ConfigurationDatabaseGTest.TestCopy
[ FAILED ] DirectoryGTest.TestGetLastAccessTime_ReRead
[ FAILED ] DirectoryGTest.TestGetLastAccessTime_ReRead2
[ FAILED ] IOBufferGTest.TestPrintFormatted_CCString
[ FAILED ] JsonParserGTest.TestParseVector
[ FAILED ] JsonParserGTest.TestParseMatrix
[ FAILED ] LoadableLibraryGTest.TestOpenCloseLibrary
[ FAILED ] LoadableLibraryGTest.TestCloseLibrary
[ FAILED ] LoadableLibraryGTest.TestLoadFunction
[ FAILED ] LoadableLibraryGTest.TestLoadFunctionSquareBracketsOperator
[ FAILED ] LoadableLibraryGTest.TestGetModule
[ FAILED ] MutexSemGTest.TestIsRecursive
[ FAILED ] MutexSemGTest.TestRecursiveOff
[ FAILED ] StreamMemoryReferenceGTest.TestAnyTypeOperator
[ FAILED ] StreamStringGTest.TestAnyTypeOperator
[ FAILED ] ThreadsGTest.TestBeginThreadStacksize0
[ FAILED ] TypeConversionGTest.TestInt32ToCArrayVector
[ FAILED ] TypeConversionGTest.TestUInt32ToCArrayVector
[ FAILED ] TypeConversionGTest.TestFloat32ToCArrayVector
[ FAILED ] TypeConversionGTest.TestCCStringToCArrayVector
[ FAILED ] TypeConversionGTest.TestCArrayToInt32Vector
[ FAILED ] TypeConversionGTest.TestCArrayToUInt32Vector
[ FAILED ] TypeConversionGTest.TestCArrayToFloat32Vector
[ FAILED ] TypeConversionGTest.TestFloat32ToCArrayMatrixStaticToStatic
[ FAILED ] TypeConversionGTest.TestCArrayToFloat32MatrixStaticToStatic
[ FAILED ] TypeConversionGTest.TestCArrayToFloat32MatrixStaticToHeap
[ FAILED ] TypeConversionGTest.TestCArrayToCCStringVector
[ FAILED ] TypeConversionGTest.TestCArrayToCCStringMatrix
[ FAILED ] StandardParserGTest.TestParseVector
[ FAILED ] StandardParserGTest.TestParseMatrix
[ FAILED ] XMLParserGTest.TestParseVector
[ FAILED ] XMLParserGTest.TestParseMatrix

Back