Skip to content

Commit

Permalink
Make Script.Name virtual as well so c# scripts can use their type name (
Browse files Browse the repository at this point in the history
#540)

* Make Script.Name virtual as well so c# scripts can use their type name
  • Loading branch information
flin-8 committed Nov 20, 2020
1 parent 0e40145 commit 81877ab
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/dbup-core/Engine/SqlScript.cs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public SqlScript(string name, string contents, SqlScriptOptions sqlScriptOptions
/// <summary>
/// Gets the name of the script.
/// </summary>
public string Name { get; }
public virtual string Name { get; }

/// <summary>
/// Create a <see cref="SqlScript"/> from a file using Default encoding
Expand Down
2 changes: 1 addition & 1 deletion src/dbup-tests/ApprovalFiles/dbup-core.approved.cs
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ public class SqlScript
public SqlScript(string name, string contents) { }
public SqlScript(string name, string contents, DbUp.Engine.SqlScriptOptions sqlScriptOptions) { }
public virtual string Contents { get; }
public string Name { get; }
public virtual string Name { get; }
public DbUp.Engine.SqlScriptOptions SqlScriptOptions { get; }
public static DbUp.Engine.SqlScript FromFile(string path) { }
public static DbUp.Engine.SqlScript FromFile(string path, System.Text.Encoding encoding) { }
Expand Down

0 comments on commit 81877ab

Please sign in to comment.