system test run error message
<p>I am trying to run this system test. I made sure that the device information is in the database. </p>

<p>When I ran the test it constantly gives me an error message:</p>

<blockquote>
  <p>Test method SystemTests.Tests.EmailNotification.TestAddDeviceToAccount
  threw exception:  System.InvalidOperationException: Sequence contains
  no elements.</p>
</blockquote>

<p>any help please </p>

<pre><code>public void TestAddDeviceToAccount()//Test to AssDeviceToAccount
{
    //string Fccid = "OPS2";
    //string SerialNumber = "101";
    //string emailAddress = "m.koneru2@spectrumBridge.com";

    using (WSPlusEntities dc = WSPlusEntities.GetContext())
    {
         Device d1 = dc.Devices.Where(d =&gt; d.FCCID == "OPS2" &amp;&amp; d.SerialNumber == "101").Single();
         d1.NetworkId = 1;
         //var deviceList = dc1.Devices.Where(d =&gt; d.FCCID == "OPS2" &amp;&amp; d.SerialNumber == "102").ToList();
         //foreach (var d2 in deviceList)
         //d2.NetworkId = 1;
         dc.SaveChanges();
    } 
}
</code></pre>
