title: Entity Framework Core 1.1 OnModelCreating method not getting called
body: <p>I have created a DBContext class in a .Net Standard 1.4 and have some code for entity configuration, in the OnModelCreating method, but it looks like this method is not getting called and I am getting an error complaining about a column name.</p>
  
  <p>Here is my class:</p>
  
  <pre><code>public partial class TestContext : DbContext
  {
      protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
      {
          optionsBuilder.UseSqlServer(@"Data Source=blah");
      }
  
      protected override void OnModelCreating(ModelBuilder modelBuilder)
      {
          modelBuilder.Entity&lt;TestTable&gt;().HasKey(t =&gt; t.Id).HasName("TestTableId");
          modelBuilder.Entity&lt;TestTable&gt;().ToTable("TestTable");
      }
  
      public virtual DbSet&lt;TestTable&gt; TestTable { get; set; }
  }
  
  public class TestTable
  {
      public Guid Id { get; set; }
      public string Name { get; set; }
  }
  </code></pre>
  
  <p>When I try to query this TestTable, I get an error saying <code>invalid column name "Id"</code></p>
  
  <p>And I don't have <code>Id</code> in the table, and I have <code>TestTableId</code>, and I was hoping the <code>OnModelCreating</code> code I got will take care of that mapping.</p>
  
  <p>Any Ideas?</p>