File tree Expand file tree Collapse file tree
src/EssSharp.Integration/Setup Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -203,7 +203,7 @@ internal static IntegrationTestSettingsConnection GetEssConnection( EssServerRol
203203 if ( Connections ? . FirstOrDefault ( conn => conn ? . Role == role ) is not IntegrationTestSettingsConnection connection )
204204 throw new Exception ( $@ "A connection with the { role } role is not available") ;
205205
206- return connection ;
206+ return connection . Clone ( ) as IntegrationTestSettingsConnection ;
207207 }
208208
209209 /// <summary />
Original file line number Diff line number Diff line change 1- namespace EssSharp . Integration . Setup
1+ using System ;
2+
3+ namespace EssSharp . Integration . Setup
24{
35 /// <summary />
46 public class IntegrationTestSettings
@@ -11,25 +13,39 @@ public class IntegrationTestSettings
1113 }
1214
1315 /// <summary />
14- public class IntegrationTestSettingsConnection
16+ public class IntegrationTestSettingsConnection : ICloneable
1517 {
1618 /// <summary />
1719 public string Server { get ; set ; }
20+
1821 /// <summary />
1922 public string Username { get ; set ; }
23+
2024 /// <summary />
2125 public string Password { get ; set ; }
26+
2227 /// <summary />
2328 public EssServerRole Role { get ; set ; }
29+
30+ /// <inheritdoc />
31+ public object Clone ( ) => new IntegrationTestSettingsConnection ( )
32+ {
33+ Server = this . Server ,
34+ Username = this . Username ,
35+ Password = this . Password ,
36+ Role = this . Role
37+ } ;
2438 }
2539
2640 /// <summary />
2741 public enum Role
2842 {
2943 /// <summary />
3044 ServiceAdministrator ,
45+
3146 /// <summary />
3247 PowerUser ,
48+
3349 /// <summary />
3450 User
3551 }
You can’t perform that action at this time.
0 commit comments