54 lines
1.7 KiB
C#
54 lines
1.7 KiB
C#
// Copyright (c) .NET Foundation. All rights reserved.
|
|
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
|
|
|
|
using System;
|
|
using Microsoft.Data.Entity.Infrastructure;
|
|
using Microsoft.Data.Entity.Metadata;
|
|
using Microsoft.Data.Entity.Metadata.Builders;
|
|
using Microsoft.Data.Entity.Relational.Migrations;
|
|
using Microsoft.Data.Entity.Relational.Migrations.Builders;
|
|
using Microsoft.Data.Entity.Relational.Migrations.Infrastructure;
|
|
|
|
namespace Microsoft.AspNet.Diagnostics.Entity.Tests
|
|
{
|
|
public class BloggingContextWithPendingModelChanges : BloggingContext
|
|
{
|
|
public BloggingContextWithPendingModelChanges(IServiceProvider provider, DbContextOptions options)
|
|
: base(provider, options)
|
|
{ }
|
|
|
|
[ContextType(typeof(BloggingContextWithPendingModelChanges))]
|
|
public class BloggingModelSnapshot : ModelSnapshot
|
|
{
|
|
public override IModel Model
|
|
{
|
|
get { return new BasicModelBuilder().Model; }
|
|
}
|
|
}
|
|
|
|
[ContextType(typeof(BloggingContextWithPendingModelChanges))]
|
|
public partial class MigrationOne : Migration
|
|
{
|
|
public override string Id
|
|
{
|
|
get { return "111111111111111_MigrationOne"; }
|
|
}
|
|
|
|
public override string ProductVersion
|
|
{
|
|
get { return CurrentProductVersion; }
|
|
}
|
|
|
|
public override IModel Target
|
|
{
|
|
get { return new BasicModelBuilder().Model; }
|
|
}
|
|
|
|
public override void Up(MigrationBuilder migrationBuilder)
|
|
{ }
|
|
|
|
public override void Down(MigrationBuilder migrationBuilder)
|
|
{ }
|
|
}
|
|
}
|
|
} |