Skip to content
This repository was archived by the owner on Dec 24, 2022. It is now read-only.

Commit 0c12e07

Browse files
committed
fix white-space
1 parent d321873 commit 0c12e07

File tree

1 file changed

+108
-108
lines changed

1 file changed

+108
-108
lines changed

src/ServiceStack.OrmLite.Oracle.Tests/ForeignKeyAttributeTests.cs

Lines changed: 108 additions & 108 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66

77
namespace ServiceStack.OrmLite.Tests
88
{
9-
[TestFixture]
10-
public class ForeignKeyAttributeTests : OrmLiteTestBase
11-
{
9+
[TestFixture]
10+
public class ForeignKeyAttributeTests : OrmLiteTestBase
11+
{
1212
[TestFixtureSetUp]
1313
public void Setup()
1414
{
@@ -33,26 +33,26 @@ private void DropTables(IDbConnection dbConnection)
3333
}
3434

3535
[Test]
36-
public void CanCreateSimpleForeignKey()
37-
{
36+
public void CanCreateSimpleForeignKey()
37+
{
3838
using (var dbConnection = OpenDbConnection())
3939
{
4040
dbConnection.DropAndCreateTable<TypeWithSimpleForeignKey>();
4141
}
4242
}
43-
44-
[Test]
45-
public void ForeignWithOnDeleteCascadeCreatesOk()
46-
{
43+
44+
[Test]
45+
public void ForeignWithOnDeleteCascadeCreatesOk()
46+
{
4747
using (var dbConn = OpenDbConnection())
4848
{
4949
dbConn.DropAndCreateTable<TypeWithOnDeleteCascade>();
5050
}
5151
}
52-
53-
[Test]
54-
public void ForeignWithOnDeleteCascadeWorks()
55-
{
52+
53+
[Test]
54+
public void ForeignWithOnDeleteCascadeWorks()
55+
{
5656
using (var dbConnection = OpenDbConnection())
5757
{
5858
dbConnection.DropAndCreateTable<TypeWithOnDeleteCascade>();
@@ -69,19 +69,19 @@ public void ForeignWithOnDeleteCascadeWorks()
6969
Assert.AreEqual(0, dbConnection.Select<TypeWithOnDeleteCascade>().Count);
7070
}
7171
}
72-
73-
[Test]
74-
public void ForeignWithOnDeleteCascadeAndOnUpdateCascadeCreatesOk()
75-
{
72+
73+
[Test]
74+
public void ForeignWithOnDeleteCascadeAndOnUpdateCascadeCreatesOk()
75+
{
7676
using (var dbConn = OpenDbConnection())
7777
{
7878
dbConn.DropAndCreateTable<TypeWithOnDeleteAndUpdateCascade>();
7979
}
80-
}
81-
82-
[Test]
83-
public void ForeignWithOnDeleteNoActionCreatesOk()
84-
{
80+
}
81+
82+
[Test]
83+
public void ForeignWithOnDeleteNoActionCreatesOk()
84+
{
8585
using (var dbConn = OpenDbConnection())
8686
{
8787
dbConn.DropAndCreateTable<TypeWithOnDeleteNoAction>();
@@ -105,10 +105,10 @@ public void ForeignWithOnDeleteNoActionThrowsException()
105105
Assert.Catch<Exception>(() => dbConnection.Delete<ReferencedType>(r => r.Id == 1));
106106
}
107107
}
108-
109-
[Test]
110-
public void ForeignWithOnDeleteRestrictCreatesOk()
111-
{
108+
109+
[Test]
110+
public void ForeignWithOnDeleteRestrictCreatesOk()
111+
{
112112
using (var dbConn = OpenDbConnection())
113113
{
114114
dbConn.DropAndCreateTable<TypeWithOnDeleteRestrict>();
@@ -133,9 +133,9 @@ public void ForeignWithOnDeleteRestrictThrowsException()
133133
}
134134
}
135135

136-
[Test]
137-
public void ForeignWithOnDeleteSetDefaultCreatesOk()
138-
{
136+
[Test]
137+
public void ForeignWithOnDeleteSetDefaultCreatesOk()
138+
{
139139
using (var dbConn = OpenDbConnection())
140140
{
141141
dbConn.DropAndCreateTable<TypeWithOnDeleteSetDefault>();
@@ -159,10 +159,10 @@ public void ForeignWithOnDeleteSetDefaultThrowsException()
159159
Assert.Catch<Exception>(() => dbConnection.Delete<ReferencedType>(r => r.Id == 1));
160160
}
161161
}
162-
163-
[Test]
164-
public void ForeignWithOnDeleteSetNullCreatesOk()
165-
{
162+
163+
[Test]
164+
public void ForeignWithOnDeleteSetNullCreatesOk()
165+
{
166166
using (var dbConn = OpenDbConnection())
167167
{
168168
dbConn.DropAndCreateTable<TypeWithOnDeleteSetNull>();
@@ -210,84 +210,84 @@ public void CanAddForeignKey()
210210
dbConnection.DropAndCreateTable<TypeWithNoForeignKeyInitially>();
211211
dbConnection.AddForeignKey<TypeWithNoForeignKeyInitially, ReferencedType>(
212212
t => t.RefId, tr => tr.Id, OnFkOption.NoAction, OnFkOption.Cascade, "FK_ADDED");
213-
}
213+
}
214214
}
215-
}
216-
217-
public class ReferencedType
218-
{
219-
public int Id { get; set; }
220-
}
215+
}
216+
217+
public class ReferencedType
218+
{
219+
public int Id { get; set; }
220+
}
221221

222222
[Alias("TWSKF")]
223-
public class TypeWithSimpleForeignKey
224-
{
225-
[AutoIncrement]
226-
public int Id { get; set; }
227-
[References(typeof(ReferencedType))]
228-
public int RefId { get; set; }
229-
}
230-
231-
[Alias("TWODC")]
232-
public class TypeWithOnDeleteCascade
233-
{
234-
[AutoIncrement]
235-
public int Id { get; set; }
236-
237-
[ForeignKey(typeof(ReferencedType), OnDelete = "CASCADE", ForeignKeyName="FK_DC")]
238-
public int? RefId { get; set; }
239-
}
240-
241-
[Alias("TWODUC")]
242-
public class TypeWithOnDeleteAndUpdateCascade
243-
{
244-
[AutoIncrement]
245-
public int Id { get; set; }
246-
247-
[ForeignKey(typeof(ReferencedType), OnDelete = "CASCADE", OnUpdate = "CASCADE", ForeignKeyName="FK_DC_UC")]
248-
public int? RefId { get; set; }
249-
}
250-
251-
[Alias("TWODNA")]
252-
public class TypeWithOnDeleteNoAction
253-
{
254-
[AutoIncrement]
255-
public int Id { get; set; }
256-
257-
[ForeignKey(typeof(ReferencedType), OnDelete = "NO ACTION", ForeignKeyName="FK_DNA")]
258-
public int? RefId { get; set; }
259-
}
260-
261-
[Alias("TWODNR")]
262-
public class TypeWithOnDeleteRestrict
263-
{
264-
[AutoIncrement]
265-
public int Id { get; set; }
266-
267-
[ForeignKey(typeof(ReferencedType), OnDelete = "RESTRICT", ForeignKeyName="FK_DR")]
268-
public int? RefId { get; set; }
269-
}
270-
271-
[Alias("TWODDF")]
272-
public class TypeWithOnDeleteSetDefault
273-
{
274-
[AutoIncrement]
275-
public int Id { get; set; }
276-
277-
[Default(typeof(int), "17")]
278-
[ForeignKey(typeof(ReferencedType), OnDelete = "SET DEFAULT", ForeignKeyName="FK_DDF")]
279-
public int RefId { get; set; }
280-
}
281-
282-
[Alias("TWODSN")]
283-
public class TypeWithOnDeleteSetNull
284-
{
285-
[AutoIncrement]
286-
public int Id { get; set; }
287-
288-
[ForeignKey(typeof(ReferencedType), OnDelete = "SET NULL", ForeignKeyName="FK_SN")]
289-
public int? RefId { get; set; }
290-
}
223+
public class TypeWithSimpleForeignKey
224+
{
225+
[AutoIncrement]
226+
public int Id { get; set; }
227+
[References(typeof(ReferencedType))]
228+
public int RefId { get; set; }
229+
}
230+
231+
[Alias("TWODC")]
232+
public class TypeWithOnDeleteCascade
233+
{
234+
[AutoIncrement]
235+
public int Id { get; set; }
236+
237+
[ForeignKey(typeof(ReferencedType), OnDelete = "CASCADE", ForeignKeyName = "FK_DC")]
238+
public int? RefId { get; set; }
239+
}
240+
241+
[Alias("TWODUC")]
242+
public class TypeWithOnDeleteAndUpdateCascade
243+
{
244+
[AutoIncrement]
245+
public int Id { get; set; }
246+
247+
[ForeignKey(typeof(ReferencedType), OnDelete = "CASCADE", OnUpdate = "CASCADE", ForeignKeyName = "FK_DC_UC")]
248+
public int? RefId { get; set; }
249+
}
250+
251+
[Alias("TWODNA")]
252+
public class TypeWithOnDeleteNoAction
253+
{
254+
[AutoIncrement]
255+
public int Id { get; set; }
256+
257+
[ForeignKey(typeof(ReferencedType), OnDelete = "NO ACTION", ForeignKeyName = "FK_DNA")]
258+
public int? RefId { get; set; }
259+
}
260+
261+
[Alias("TWODNR")]
262+
public class TypeWithOnDeleteRestrict
263+
{
264+
[AutoIncrement]
265+
public int Id { get; set; }
266+
267+
[ForeignKey(typeof(ReferencedType), OnDelete = "RESTRICT", ForeignKeyName = "FK_DR")]
268+
public int? RefId { get; set; }
269+
}
270+
271+
[Alias("TWODDF")]
272+
public class TypeWithOnDeleteSetDefault
273+
{
274+
[AutoIncrement]
275+
public int Id { get; set; }
276+
277+
[Default(typeof(int), "17")]
278+
[ForeignKey(typeof(ReferencedType), OnDelete = "SET DEFAULT", ForeignKeyName = "FK_DDF")]
279+
public int RefId { get; set; }
280+
}
281+
282+
[Alias("TWODSN")]
283+
public class TypeWithOnDeleteSetNull
284+
{
285+
[AutoIncrement]
286+
public int Id { get; set; }
287+
288+
[ForeignKey(typeof(ReferencedType), OnDelete = "SET NULL", ForeignKeyName = "FK_SN")]
289+
public int? RefId { get; set; }
290+
}
291291

292292
[Alias("TWONFKI")]
293293
public class TypeWithNoForeignKeyInitially

0 commit comments

Comments
 (0)