Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Answered

Test generated from task recording doesn't compile

(0) ShareShare
ReportReport
Posted on by 65

Following this article: https://learn.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/perf-test/testing-validation

  1. Created a Task Recording and saved as a Developer download
  2. Using VS 2019
  3. Selected Dynamics 365 -> Addins -> Import Task Recording
  4. Created a new projects.
  5. Solution builds with no issue.
  6. In Test Explorer when the test is run the error message is "One or more modules is missing."   Says the error is on the attributes line:  [SysCodeGenAttribute(),SysTestMethodAttribute()
  7.     [SysCodeGenAttribute(),SysTestMethodAttribute()]
        public void testMethod()
        {
            using (var c = ClientContext::create())
            {
            .....
            }
        }
  8. Test Explorer is set to x64 processor.
  9. I would also expect the attribute line to be in a different color instead of the default black characters.
  10. When the solution is built the output window under the Test drop-down shows:  

========== Test discovery finished: 1 Tests found in 1.6 sec ==========
ProjectData: Could not find project with GUID 2e6650d2-06aa-476d-a25c-efdf0d3e0343
ProjectData: Could not find project with GUID 2e6650d2-06aa-476d-a25c-efdf0d3e0343
ProjectData: Could not find project with GUID a93726d1-e1cc-482b-b16f-3e5322527f6e
ProjectData: Could not find project with GUID a93726d1-e1cc-482b-b16f-3e5322527f6e
ProjectData: Could not find project with GUID 2e6650d2-06aa-476d-a25c-efdf0d3e0343
ProjectData: Could not find project with GUID 2e6650d2-06aa-476d-a25c-efdf0d3e0343
ProjectData: Could not find project with GUID a93726d1-e1cc-482b-b16f-3e5322527f6e
ProjectData: Could not find project with GUID a93726d1-e1cc-482b-b16f-3e5322527f6e

Is importing a task recording supported in VS2019?

Am I missing a package, reference and/or model?

Any assistance is appreciated.

Thanks

Duane

  • Verified answer
    huijij Profile Picture
    huijij 19,811 on at
    RE: Test generated from task recording doesn't compile

    Hi sir,

    This error indicates that you are missing a model reference in your model. If you look up the SysCodeGenAttribute class, you will find out which model this class belongs to. Then update your model's model reference to include this reference. You have to use the next menu path in Visual Studio to update the model reference. Dynamics 365 > Model Management > Update Model Parameters.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Congratulations to the January Top 10 leaders!

Check out the January community rock stars...

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,162 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,962 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans