@@ -78,10 +78,10 @@ public async Task PerformanceAnalysis_SELECT_Test()
7878 var fbCommand = new FbCommand ( "SELECT MAX(INT_FIELD) FROM TEST" , Connection ) ;
7979 var maxIntField = await fbCommand . ExecuteScalarAsync ( ) as int ? ;
8080
81- insertCount = GetAffectedTables ( insertCount , await dbInfo . GetInsertCountAsync ( ) ) ;
82- updateCount = GetAffectedTables ( updateCount , await dbInfo . GetUpdateCountAsync ( ) ) ;
83- readSeqCount = GetAffectedTables ( readSeqCount , await dbInfo . GetReadSeqCountAsync ( ) ) ;
84- readIdxCount = GetAffectedTables ( readIdxCount , await dbInfo . GetReadIdxCountAsync ( ) ) ;
81+ insertCount = await GetAffectedTables ( insertCount , await dbInfo . GetInsertCountAsync ( ) ) ;
82+ updateCount = await GetAffectedTables ( updateCount , await dbInfo . GetUpdateCountAsync ( ) ) ;
83+ readSeqCount = await GetAffectedTables ( readSeqCount , await dbInfo . GetReadSeqCountAsync ( ) ) ;
84+ readIdxCount = await GetAffectedTables ( readIdxCount , await dbInfo . GetReadIdxCountAsync ( ) ) ;
8585
8686 Assert . That ( insertCount . ContainsKey ( tableIdTest ) , Is . False ) ;
8787 Assert . That ( updateCount . ContainsKey ( tableIdTest ) , Is . False ) ;
@@ -105,10 +105,10 @@ public async Task PerformanceAnalysis_INSERT_Test()
105105 var fbCommand = new FbCommand ( "INSERT INTO TEST (INT_FIELD) VALUES (900)" , Connection ) ;
106106 await fbCommand . ExecuteNonQueryAsync ( ) ;
107107
108- insertCount = GetAffectedTables ( insertCount , await dbInfo . GetInsertCountAsync ( ) ) ;
109- updateCount = GetAffectedTables ( updateCount , await dbInfo . GetUpdateCountAsync ( ) ) ;
110- readSeqCount = GetAffectedTables ( readSeqCount , await dbInfo . GetReadSeqCountAsync ( ) ) ;
111- readIdxCount = GetAffectedTables ( readIdxCount , await dbInfo . GetReadIdxCountAsync ( ) ) ;
108+ insertCount = await GetAffectedTables ( insertCount , await dbInfo . GetInsertCountAsync ( ) ) ;
109+ updateCount = await GetAffectedTables ( updateCount , await dbInfo . GetUpdateCountAsync ( ) ) ;
110+ readSeqCount = await GetAffectedTables ( readSeqCount , await dbInfo . GetReadSeqCountAsync ( ) ) ;
111+ readIdxCount = await GetAffectedTables ( readIdxCount , await dbInfo . GetReadIdxCountAsync ( ) ) ;
112112
113113 Assert . That ( insertCount . ContainsKey ( tableIdTest ) , Is . True ) ;
114114 Assert . That ( insertCount [ tableIdTest ] , Is . EqualTo ( 1 ) ) ;
@@ -124,7 +124,7 @@ public async Task PerformanceAnalysis_UPDATE_Test()
124124 var tableIdTest = tableNameList [ "TEST" ] ;
125125
126126 var fbCommand = new FbCommand ( "INSERT INTO TEST (INT_FIELD) VALUES (900)" , Connection ) ;
127- fbCommand . ExecuteNonQuery ( ) ;
127+ await fbCommand . ExecuteNonQueryAsync ( ) ;
128128
129129 var dbInfo = new FbDatabaseInfo ( Connection ) ;
130130 var insertCount = await dbInfo . GetInsertCountAsync ( ) ;
@@ -135,10 +135,10 @@ public async Task PerformanceAnalysis_UPDATE_Test()
135135 fbCommand . CommandText = "UPDATE TEST SET SMALLINT_FIELD = 900 WHERE (INT_FIELD = 900)" ;
136136 await fbCommand . ExecuteNonQueryAsync ( ) ;
137137
138- insertCount = GetAffectedTables ( insertCount , await dbInfo . GetInsertCountAsync ( ) ) ;
139- updateCount = GetAffectedTables ( updateCount , await dbInfo . GetUpdateCountAsync ( ) ) ;
140- readSeqCount = GetAffectedTables ( readSeqCount , await dbInfo . GetReadSeqCountAsync ( ) ) ;
141- readIdxCount = GetAffectedTables ( readIdxCount , await dbInfo . GetReadIdxCountAsync ( ) ) ;
138+ insertCount = await GetAffectedTables ( insertCount , await dbInfo . GetInsertCountAsync ( ) ) ;
139+ updateCount = await GetAffectedTables ( updateCount , await dbInfo . GetUpdateCountAsync ( ) ) ;
140+ readSeqCount = await GetAffectedTables ( readSeqCount , await dbInfo . GetReadSeqCountAsync ( ) ) ;
141+ readIdxCount = await GetAffectedTables ( readIdxCount , await dbInfo . GetReadIdxCountAsync ( ) ) ;
142142
143143 Assert . That ( insertCount . ContainsKey ( tableIdTest ) , Is . False ) ;
144144 Assert . That ( updateCount . ContainsKey ( tableIdTest ) , Is . True ) ;
@@ -148,7 +148,7 @@ public async Task PerformanceAnalysis_UPDATE_Test()
148148 Assert . That ( readIdxCount [ tableIdTest ] , Is . EqualTo ( 1 ) ) ;
149149 }
150150
151- IDictionary < short , ulong > GetAffectedTables ( IDictionary < short , ulong > statisticInfoBefore , IDictionary < short , ulong > statisticInfoAfter )
151+ async Task < IDictionary < short , ulong > > GetAffectedTables ( IDictionary < short , ulong > statisticInfoBefore , IDictionary < short , ulong > statisticInfoAfter )
152152 {
153153 var result = new Dictionary < short , ulong > ( ) ;
154154 foreach ( var keyValuePair in statisticInfoAfter )
@@ -164,7 +164,7 @@ IDictionary<short, ulong> GetAffectedTables(IDictionary<short, ulong> statisticI
164164 else
165165 result . Add ( keyValuePair . Key , keyValuePair . Value ) ;
166166 }
167- return result ;
167+ return await Task . FromResult ( result ) ;
168168 }
169169
170170 async Task < IDictionary < string , short > > GetTableNameList ( )
0 commit comments