Add copy constructor to deployment parameters (#1497)
This commit is contained in:
parent
19839ed308
commit
21d9ec64f0
|
|
@ -78,6 +78,27 @@ namespace Microsoft.AspNetCore.Server.IntegrationTesting
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public DeploymentParameters(DeploymentParameters parameters)
|
||||||
|
{
|
||||||
|
foreach (var propertyInfo in typeof(DeploymentParameters).GetProperties())
|
||||||
|
{
|
||||||
|
if (propertyInfo.CanWrite)
|
||||||
|
{
|
||||||
|
propertyInfo.SetValue(this, propertyInfo.GetValue(parameters));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach (var kvp in parameters.EnvironmentVariables)
|
||||||
|
{
|
||||||
|
EnvironmentVariables.Add(kvp);
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach (var kvp in parameters.PublishEnvironmentVariables)
|
||||||
|
{
|
||||||
|
PublishEnvironmentVariables.Add(kvp);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public ServerType ServerType { get; set; }
|
public ServerType ServerType { get; set; }
|
||||||
|
|
||||||
public RuntimeFlavor RuntimeFlavor { get; set; }
|
public RuntimeFlavor RuntimeFlavor { get; set; }
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue