Jump to content

Wagner Landgraf

Members
  • Content Count

    33
  • Joined

  • Last visited

Community Reputation

8 Neutral

1 Follower

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Wagner Landgraf

    Records, Generics and RTTI meets FireDAC

    Until you start using it. You are actually adding one right now.
  2. Wagner Landgraf

    TestInsight 1.1.9.0 released

    Great, now tests are uniquely identified! Thank you, I guess I'm on the right path. Congrats for the great tool.
  3. Wagner Landgraf

    TestInsight 1.1.9.0 released

    Ok. Reading the code I think TI is just not prepared for it. In many places you consider the test name to be ClassName + TestName, as in: function GetFullQualifiedName(const test: ITest): string; begin Result := (test as TObject).ClassName + '.' + test.Name; end; Also, TTestInsightListener.StartSuite and EndSuite are not implemented, and I believe that's what would allow a tree-like structure in the IDE plugin. I also don't know how the plugin handles the information sent to it, but from what is available in TTestInsightResult and no StartSuite/EndSuite information I believe it's not trivial to show the results reflecting the original tree structure. Thanks for your help!
  4. Wagner Landgraf

    TestInsight 1.1.9.0 released

    I tried it again, I must be doing something wrong. This is what I get when I run it for the first time. Some warnings: And then remaining tests passed. The tests that are not replicated and grouped by database: And the tests that are supposed to be replicated and grouped by database: If I click "group by type" it doesn't help much: Finally, I must say that all tests were run in the first place. Note that what I do is to run the application with Ctrl+Shift+F9.
  5. Wagner Landgraf

    TestInsight 1.1.9.0 released

    The tests are organized more or less this way (never mind some unfriendly names): As you can see, there are several setups (NativeSQLite, FireDacMSSQL, etc.). For each of then, there is a test suite named "TTestBasicCriteria" for example, with several test methods. This is all setup dynamically by a code like this, which gathers all registered "Aurelius tests" and then create the proper DUnit tests based on it: // Wrap all registered tests into a single test setup for initial set up and final tear down } for Setup in AureliusDBSetups do begin testconfig := TTestConfig.Create(Setup); DBTest := CreateSuiteFromConfig(testConfig, Setup.Name); RegisterTest(DBTest); if Setup.RemoteDB then begin testConfig := TRemoteDBTestConfig.Create(Setup); DBTest := CreateSuiteFromConfig(testConfig, Setup.Name + ' - Remote'); RegisterTest(DBTest); end; if Setup.GenericDB then begin testConfig := TGenericDBTestConfig.Create(Setup); DBTest := CreateSuiteFromConfig(testConfig, Setup.Name + ' - Generic'); RegisterTest(DBTest); end; end; You can also see some of the test cases are not replicated among all databases, because it doesn't make sense - like TTestMemoryDataset, for example.
  6. Wagner Landgraf

    TestInsight 1.1.9.0 released

    Of course no one is forcing me! 🙂 It's just it's a nice tool with several benefits that I'd love to use. I will see what I will do. My case is different, I also use test inheritance when applicable but as I said, in my case I have hundreds of tests, spread over different TTestCase objects because it makes sense - logical grouping, different setup and teardown mechanisms, etc. Then all of those tests are grouped by decorators to work with different "Setups" - different databases, for example. So they are actually the same test, even double clicking won't solve because they will all point to the same source code.
  7. Wagner Landgraf

    TestInsight 1.1.9.0 released

    1. This is (almost) a showstopper for me, unless I'm not fully understanding or building my tests wrongly. The thing is TMS Aurelius for example has thousands and thousands of tests. Reason is tests are replicated in several scenarios: for MySQL, for SQL Server, for Oracle, using RemoteDB, not using RemoteDB, etc.. Thus information about hierarchy is a must to understand which tests failed in which situation (the test was a "SaveBlob", but was it with SQL Server or Firebird? Using RemoteDB? Etc.) Not sure if there is an alternative way to do so or TI was not built for such scenario? 2. Ok, I will check it again with more attention. 3. Ok, I will check it also, thanks a lot.
  8. Wagner Landgraf

    TestInsight 1.1.9.0 released

    Thanks @Stefan Glienke. I'm not sure if you prefer I open an issue, but I consider this more a discussion, so will ask it here first. I'm trying to use Test Insight with my tests as-is, but I'm having some issues which relates to my understanding of how it works. For example: 1. Hierarchy My tests have some hierarchical structure that are displayed in the DUnit GUI test runner. I manually use several test decorators to organize it, and sometimes I register test with dots in names to organize it. When using TestInsight, the results are not displayed in the same structure, but all test results are displayed in a "flat" layout. Is this known, intentional, or there is something I could do to improve it? 2. Loop I understand the tests keep running in a loop? Or at least I can't finalize the test application, which seems to keep running in background. Is this also the normal behavior? 3. Test selection I understand that I can select the tests to be executed, but only after one initial execution of all tests are performed. My tests take a lot of time to execute, so that's not a viable option. Is there a workaround to be able to select the tests to be executed before they are actually first executed? Thanks!
  9. Wagner Landgraf

    Your RAD Studio 10.4 Sydney issues

    There you go: https://en.delphipraxis.net/topic/2887-you-rad-studio-104-sydney-appreciated-features-and-bug-fixes/
  10. Share here what you liked the most about 10.4 Sydney, be it new features or bug fixes you were waiting for. For issues and complains, use this topic: https://en.delphipraxis.net/topic/2885-your-rad-studio-104-sydney-issues/
  11. Wagner Landgraf

    Your RAD Studio 10.4 Sydney issues

    Will there also be a topic for 10.4 Sydney appreciated new features and bugs fixed?
  12. Wagner Landgraf

    RTTI info for TBytes using runtime packages

    Indeed. Thanks all for your help!
  13. Wagner Landgraf

    RTTI info for TBytes using runtime packages

    Yes, I'm saying that I had it working considering both type info were equal. Same situation as this. The code in point here is JSON serialization. User pass one generic TValue (or an object with lots of properties) and I check the type of the TValue (or property) and serialize it accordingly. So I check if a type is TBytes and serialize it as base64-encoded. As far as I know, this works find with an app using runtime packages and TBytes, just in this application it doesn't. I guess. So as I said, instead of checking if the value being serialized has the same type info as TBytes, I would have to check if the type name is "TArray<System.byte>" or maybe check if it's an array of type byte. It's a valid solution, although still makes me uncomfortable that such issues might happen with other types.
  14. Wagner Landgraf

    RTTI info for TBytes using runtime packages

    Thanks @Stefan Glienke. That makes sense, even though I'm (almost) sure I had this working in other applications built with runtime (i.e., having TBytes being recognized as the same type from two different packages). The difference here is that this is an application from a customer and is a huge one - it's an ERP composed of hundreds of packages. If that's the case, I suppose there is no workaround using Delphi builtin types, and I would have to create my own type in my library. Or check for the type name instead of type info (which would be slower). In summary, a kludge...
  15. Wagner Landgraf

    RTTI info for TBytes using runtime packages

    @David Heffernan, thanks, I'm aware of that. The key here is that I don't know what else I'm supposed to do tomake sure that both modules are linking to rtl, as I checked everything I know of (listed above). @Remy Lebeau, I don't see any option "Enable with runtime packages" for packages. I believe it's implicit? I have added "rtl" to the package requires list, and also to the packages needed by the application. I believe this is enough, but obviously something else is missing.
×