Menu

#64 Numbers for Delphi Generics units gets included in coverage results

Accepted
nobody
None
Medium
Defect
2020-06-16
2015-02-11
Anonymous
No

Originally created by: marjanve...@gmail.com
Originally owned by: e.kotlya...@gmail.com

What steps will reproduce the problem?
1. Create a class using a generic type from system.generics.*

What is the expected output? What do you see instead?
Just the coverage numbers for my own code. Instead I get to see the coverage results for the code from the system.generics units that gets pulled in as well.

What version of the product are you using? On what operating system?
RC10 64 bit
Win7 64 bit

Please provide any additional information below.

1 Attachments

Discussion

  • Anonymous

    Anonymous - 2015-03-11

    Originally posted by: e.kotlya...@gmail.com

    (No comment was entered for this change.)

    Owner: e.kotlya...@gmail.com
    Status: Accepted

     
  • Jáder Carvalho de Medeiros

    Delphi have some problem with namespace of generics types (maybe because this types is created on runtime and the reference is the unit that this class is created).

    So, to workaround this bug, I created specialized classes that is only to map the generic type to a new specialized type on a new unit.

    In your case (marjanve), try create a unit called File_Logger_Specialized and put all generic types (like a TList<>, TDicionary<>) in this new unit, create a new class for each generic type and replace these generics types on File_Logger unit with the respective new specialized type that you created.

    After this changes, run the codecovarege tool again and check if this bug still happen.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.