1

Closed

Designer Intermittent add/find template test failures on VS2013

description

I am seeing some tests failing intermittently on VS2013. These tests always pass on VS2012 they also pass on re-run. Would be good to investigate and figure out the root cause of the problem to make sure it is not a bug in the designer. See the build history on the CI box. Here is an example from the build log when the problem happens:

[15:16:07] Passed FindDbContextTemplate_finds_the_EF5_CSharp_web_site_template_when_targeting_dotNET4_web_site_with_CSharp
[15:16:11] Failed FindDbContextTemplate_finds_the_EF5_CSharp_web_site_template_when_targeting_dotNET4_5_web_site_with_CSharp
[15:16:11] Standard Output Messages:
[15:16:11]
[15:16:11]
[15:16:11] Debug Trace:
[15:16:11] Web Publish Package: Entering ProjectOpened
[15:16:11] Web Publish Package: Creating a new project publish data
[15:16:11] Web Publish Package: Exiting ProjectOpened
[15:16:11] Web Publish Package: Entering GetPublishableProjectCfg
[15:16:11] Web Publish Package: Exiting GetPublishableProjectCfg
[15:16:11]
[15:16:11] Passed FindDbContextTemplate_finds_the_EF5_VB_web_site_template_when_targeting_dotNET4_web_site_with_VB
[15:16:11]EXEC : error Message: [C:\BuildAgent\work\f2d314923a6e49a8\EFDesigner.msbuild]
[15:16:11] Test method EFDesigner.InProcTests.AutomaticDbContextTests.FindDbContextTemplate_finds_the_EF5_CSharp_web_site_template_when_targeting_dotNET4_5_web_site_with_CSharp threw exception:
[15:16:11] System.InvalidOperationException: Sequence contains no matching element
[15:16:11] Stack Trace:
[15:16:11] at System.Windows.Forms.Control.MarshaledInvoke(Control caller, Delegate method, Object[] args, Boolean synchronous)
[15:16:11] at System.Windows.Forms.Control.Invoke(Delegate method, Object[] args)
[15:16:11] at System.Windows.Forms.Control.Invoke(Delegate method)
[15:16:11] at Microsoft.VisualStudio.TestTools.VsIdeTesting.UIThreadInvoker.Invoke(Delegate method)
[15:16:11] at EFDesignerTestInfrastructure.VS.UITestRunner.Execute(Action action) in c:\BuildAgent\work\f2d314923a6e49a8\test\TestInfrastructure\VS\UITestRunner.cs:line 31
[15:16:11] at EFDesigner.InProcTests.AutomaticDbContextTests.FindDbContextTemplate_finds_the_EF5_CSharp_web_site_template_when_targeting_dotNET4_5_web_site_with_CSharp() in c:\BuildAgent\work\f2d314923a6e49a8\test\InProcTests\AutomaticDbContextTests.cs:line 144
[15:16:12] Passed FindDbContextTemplate_finds_the_EF5_VB_web_site_template_when_targeting_dotNET4_5_web_site_with_VB
[15:16:12] Passed FindDbContextTemplate_finds_the_EF6_CSharp_template
[15:16:15] Passed FindDbContextTemplate_finds_the_EF6_VB_template
[15:16:15] Passed FindDbContextTemplate_finds_the_EF6_CSharp_web_site_template
[15:16:15] Passed FindDbContextTemplate_finds_the_EF6_VB_web_site_template
[15:16:37] Passed AddDbContextTemplates_does_not_add_the_template_items_to_the_item_collection_when_targeting_dotNET3_5
[15:16:37] Passed AddDbContextTemplates_adds_the_template_items_nested_under_the_EDMX_item
[15:16:43] Passed AddDbContextTemplates_does_not_nest_existing_tt_files_or_non_tt_files_added_at_the_same_time_as_the_template_items
[15:17:00] Failed AddDbContextTemplates_adds_the_template_items_to_the_item_collection_for_a_website_project
[15:17:00] Standard Output Messages:
[15:17:00]
[15:17:00]
[15:17:00] Debug Trace:
[15:17:00] Web Publish Package: Entering ProjectOpened
[15:17:00] Web Publish Package: Creating a new project publish data
[15:17:00] Web Publish Package: Exiting ProjectOpened
[15:17:00] Web Publish Package: Entering GetPublishableProjectCfg
[15:17:00] Web Publish Package: Exiting GetPublishableProjectCfg
[15:17:00] There are now 1 Edit Locks, and 1 Read Locks.
[15:17:00]
[15:17:00]EXEC : error Message: [C:\BuildAgent\work\f2d314923a6e49a8\EFDesigner.msbuild]
[15:17:00] Assert.IsTrue failed.
[15:17:00] Stack Trace:
[15:17:00] at System.Windows.Forms.Control.MarshaledInvoke(Control caller, Delegate method, Object[] args, Boolean synchronous)
[15:17:00] at System.Windows.Forms.Control.Invoke(Delegate method, Object[] args)
[15:17:00] at System.Windows.Forms.Control.Invoke(Delegate method)
[15:17:00] at Microsoft.VisualStudio.TestTools.VsIdeTesting.UIThreadInvoker.Invoke(Delegate method)
[15:17:00] at EFDesignerTestInfrastructure.VS.UITestRunner.Execute(Action action) in c:\BuildAgent\work\f2d314923a6e49a8\test\TestInfrastructure\VS\UITestRunner.cs:line 31
[15:17:00] at EFDesigner.InProcTests.AutomaticDbContextTests.AddDbContextTemplates_adds_the_template_items_to_the_item_collection_for_a_website_project() in c:\BuildAgent\work\f2d314923a6e49a8\test\InProcTests\AutomaticDbContextTests.cs:line 304
[15:17:06] Passed AddAndNestCodeGenTemplates_does_not_fail_if_EDMX_project_item_is_null
[15:17:06] Passed AddNewItemDialogFilter_only_accepts_items_with_file_names_for_well_known_template_types
[15:17:06] Passed ChangeEntityTypeShapeFillColorTest

file attachments

Closed Dec 12, 2016 at 10:45 PM by RoMiller
EF Team Triage: We are transitioning this project to GitHub (https://github.com/aspnet/EntityFramework6). As part of this transition we are bulk closing a large number of issues in order that our new issue tracker will accurately reflect the work that our team is planning to complete on the EF6.x code base.

Moving forwards, our team will be fixing bugs, implementing small improvements, and accepting community contributions to the EF6.x code base. Larger feature work and innovation will happen in the EF Core code base (https://github.com/aspnet/EntityFramework). Closing a feature request in the EF6.x project does not exclude us implementing the feature in EF Core. In fact, a number of popular feature requests for EF have already been implemented in EF Core (alternate keys, batching in SaveChanges, etc.).

This is a bulk message to indicate that this issue was closed and not ported to the new issue tracker. The reasons for not porting this particular issue to GitHub may include:
  • It was a bug report that does not contain sufficient information for us to be able to reproduce it
  • It was a question, but sufficient time has passed that it's not clear that taking the time to answer it would provide value to the person who asked it
  • It is a feature request that we are realistically not going to implement on the EF6.x code base
    Although this issue was not ported, you may still re-open it in the new issue tracker for our team to reconsider (https://github.com/aspnet/EntityFramework6/issues). We will no longer be monitoring this issue tracker for comments, so please do not reply here.

comments

RoMiller wrote Jul 11, 2013 at 11:05 PM

EF Team Triage: We should test that this scenario works. Once we confirm it's just a test issue we can punt this issue to Future.

moozzyk wrote Jul 22, 2013 at 5:26 PM

It seems that the tests are trying to look for templates in a stale folder. When the folder does not exist the test fail. Attaching a trx file. The run was started on 7/22 (pawelka_PAWELKA-DEV 2013-07-22 08_56_51.trx) but the test was trying to load templates from c:\Source\EFDesigner\test\InProcTests\bin\Debug\TestResults\pawelka_PAWELKA-DEV 2013-04-18 11_33_44\DbContextCSharpNet45Web

moozzyk wrote Jul 22, 2013 at 5:28 PM

Attaching the file.

moozzyk wrote Jul 22, 2013 at 5:29 PM

Attaching the file.

RoMiller wrote Dec 12, 2013 at 9:40 PM

EF Team Triage: Moving issues with Impact set to Low out of the 6.1.0 release as we only have time to address High and Medium issues in this release. We will re-triage these issues for future releases.

This does not exclude someone outside of the Microsoft EF team from contributing the change/fix in 6.1.0.