Guest User

Untitled

a guest
Feb 28th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.73 KB | None | 0 0
  1. [alexbcoles@mondiale do_mysql (jdbc)]$ jruby -S rake spec
  2. (in /Users/alexbcoles/git-repos/do/do_mysql)
  3. /usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rake-0.8.3/lib/rake/gempackagetask.rb:13:Warning: Gem::manage_gems is deprecated and will be removed on or after March 2009.
  4. mkdir -p pkg/classes
  5.  
  6. DataObjects::Mysql
  7. - should expose the proper DataObjects classes
  8. - should connect successfully via TCP
  9. - should be able to send queries asynchronously in parallel
  10. - should return the current character set
  11. - should support changing the character set (PENDING: JDBC API does not provide an easy way to get the current character set)
  12. - should raise an error when opened with an invalid server uri
  13.  
  14. DataObjects::Mysql::Connection
  15. - should raise an error when attempting to execute a bad query
  16. - should raise an error when executing a bad reader
  17. - should not raise a connection closed error after an incorrect query
  18. - should not raise a connection closed error after an incorrect reader
  19.  
  20. DataObjects::Mysql::Reader
  21. - should raise an error when you pass too many or too few types for the expected result set
  22. - shouldn't raise an error when you pass NO types for the expected result set
  23. JDBC TypeName INTEGER
  24. JDBC Metadata scale 0
  25. Ruby Type Fixnum
  26. JDBC TypeName VARCHAR
  27. JDBC Metadata scale 0
  28. Ruby Type String
  29. JDBC TypeName TIMESTAMP
  30. JDBC Metadata scale 0
  31. Ruby Type DateTime
  32. JDBC TypeName INTEGER
  33. JDBC Metadata scale 0
  34. Ruby Type Fixnum
  35. JDBC TypeName CHAR
  36. JDBC Metadata scale 0
  37. Ruby Type String
  38. JDBC TypeName VARCHAR
  39. JDBC Metadata scale 0
  40. Ruby Type String
  41. JDBC TypeName VARCHAR
  42. JDBC Metadata scale 0
  43. Ruby Type String
  44. JDBC TypeName VARCHAR
  45. JDBC Metadata scale 0
  46. Ruby Type String
  47. JDBC TypeName BLOB
  48. JDBC Metadata scale 0
  49. Ruby Type String
  50. JDBC TypeName VARCHAR
  51. JDBC Metadata scale 0
  52. Ruby Type String
  53. JDBC TypeName MEDIUMBLOB
  54. JDBC Metadata scale 0
  55. Ruby Type String
  56. JDBC TypeName VARCHAR
  57. JDBC Metadata scale 0
  58. Ruby Type String
  59. JDBC TypeName LONGBLOB
  60. JDBC Metadata scale 0
  61. Ruby Type String
  62. JDBC TypeName TINYINT
  63. JDBC Metadata scale 0
  64. Ruby Type TrueClass
  65. JDBC TypeName SMALLINT
  66. JDBC Metadata scale 0
  67. Ruby Type Fixnum
  68. JDBC TypeName MEDIUMINT
  69. JDBC Metadata scale 0
  70. Ruby Type Fixnum
  71. JDBC TypeName BIGINT
  72. JDBC Metadata scale 0
  73. Ruby Type Bignum
  74. JDBC TypeName FLOAT
  75. JDBC Metadata scale 31
  76. Ruby Type String
  77. JDBC TypeName DOUBLE
  78. JDBC Metadata scale 2
  79. Ruby Type Float
  80. JDBC TypeName DECIMAL
  81. JDBC Metadata scale 2
  82. Ruby Type BigDecimal
  83. JDBC TypeName DATE
  84. JDBC Metadata scale 0
  85. Ruby Type Date
  86. JDBC TypeName DATETIME
  87. JDBC Metadata scale 0
  88. Ruby Type DateTime
  89. JDBC TypeName TIMESTAMP
  90. JDBC Metadata scale 0
  91. Ruby Type DateTime
  92. JDBC TypeName CHAR
  93. JDBC Metadata scale 0
  94. Ruby Type String
  95. JDBC TypeName INTEGER
  96. JDBC Metadata scale 0
  97. Ruby Type Fixnum
  98. JDBC TypeName CHAR
  99. JDBC Metadata scale 0
  100. Ruby Type String
  101. JDBC TypeName VARCHAR
  102. JDBC Metadata scale 0
  103. Ruby Type String
  104. JDBC TypeName VARCHAR
  105. JDBC Metadata scale 0
  106. Ruby Type String
  107. JDBC TypeName VARCHAR
  108. JDBC Metadata scale 0
  109. Ruby Type String
  110. JDBC TypeName BLOB
  111. JDBC Metadata scale 0
  112. Ruby Type String
  113. JDBC TypeName VARCHAR
  114. JDBC Metadata scale 0
  115. Ruby Type String
  116. JDBC TypeName MEDIUMBLOB
  117. JDBC Metadata scale 0
  118. Ruby Type String
  119. JDBC TypeName VARCHAR
  120. JDBC Metadata scale 0
  121. Ruby Type String
  122. JDBC TypeName LONGBLOB
  123. JDBC Metadata scale 0
  124. Ruby Type String
  125. JDBC TypeName TINYINT
  126. JDBC Metadata scale 0
  127. Ruby Type TrueClass
  128. JDBC TypeName SMALLINT
  129. JDBC Metadata scale 0
  130. Ruby Type Fixnum
  131. JDBC TypeName MEDIUMINT
  132. JDBC Metadata scale 0
  133. Ruby Type Fixnum
  134. JDBC TypeName BIGINT
  135. JDBC Metadata scale 0
  136. Ruby Type Bignum
  137. JDBC TypeName FLOAT
  138. JDBC Metadata scale 31
  139. Ruby Type String
  140. JDBC TypeName DOUBLE
  141. JDBC Metadata scale 2
  142. Ruby Type Float
  143. JDBC TypeName DECIMAL
  144. JDBC Metadata scale 2
  145. Ruby Type BigDecimal
  146. JDBC TypeName DATE
  147. JDBC Metadata scale 0
  148. Ruby Type Date
  149. JDBC TypeName DATETIME
  150. JDBC Metadata scale 0
  151. Ruby Type DateTime
  152. JDBC TypeName TIMESTAMP
  153. JDBC Metadata scale 0
  154. Ruby Type DateTime
  155. JDBC TypeName CHAR
  156. JDBC Metadata scale 0
  157. Ruby Type String
  158. JDBC TypeName INTEGER
  159. JDBC Metadata scale 0
  160. Ruby Type Fixnum
  161. JDBC TypeName VARCHAR
  162. JDBC Metadata scale 0
  163. Ruby Type String
  164. JDBC TypeName TIMESTAMP
  165. JDBC Metadata scale 0
  166. Ruby Type DateTime
  167. JDBC TypeName INTEGER
  168. JDBC Metadata scale 0
  169. Ruby Type Fixnum
  170. JDBC TypeName VARCHAR
  171. JDBC Metadata scale 0
  172. Ruby Type String
  173. JDBC TypeName TIMESTAMP
  174. JDBC Metadata scale 0
  175. Ruby Type DateTime
  176. JDBC TypeName VARCHAR
  177. JDBC Metadata scale 0
  178. Ruby Type String
  179. JDBC TypeName VARCHAR
  180. JDBC Metadata scale 0
  181. Ruby Type String
  182. JDBC TypeName VARCHAR
  183. JDBC Metadata scale 0
  184. Ruby Type String
  185. JDBC TypeName VARCHAR
  186. JDBC Metadata scale 0
  187. Ruby Type String
  188. JDBC TypeName VARCHAR
  189. JDBC Metadata scale 0
  190. Ruby Type String
  191. JDBC TypeName TIMESTAMP
  192. JDBC Metadata scale 0
  193. Ruby Type Time
  194. - should return the proper number of fields
  195. - should raise an exception if .values is called after reading all available rows
  196. - should fetch the proper number of rows
  197. - should contain tainted strings
  198. - should return DB nulls as nil
  199. - should not convert empty strings to null
  200.  
  201. DataObjects::Mysql::Reader Date, Time, and DateTime
  202. - should return nil when the time is 0
  203. JDBC TypeName TIMESTAMP
  204. JDBC Metadata scale 0
  205. Ruby Type DateTime
  206. - should return DateTimes using the current locale's Time Zone
  207. - should return 2009-01-08T01:44:16-11:00 offset to the current locale's Time Zone if they were inserted using a different timezone (PENDING: We don't support non-local date input yet)
  208. - should return 2009-01-08T03:54:16-08:50 offset to the current locale's Time Zone if they were inserted using a different timezone (PENDING: We don't support non-local date input yet)
  209. - should return 2009-01-08T04:44:16-08:00 offset to the current locale's Time Zone if they were inserted using a different timezone (PENDING: We don't support non-local date input yet)
  210. - should return 2009-01-08T15:44:16+03:00 offset to the current locale's Time Zone if they were inserted using a different timezone (PENDING: We don't support non-local date input yet)
  211. - should return 2009-01-08T18:14:16+05:30 offset to the current locale's Time Zone if they were inserted using a different timezone (PENDING: We don't support non-local date input yet)
  212.  
  213. DataObjects::Mysql::Reader executing a non-query
  214. - should return a Result
  215. - should be able to determine the affected_rows
  216. - should yield the last inserted id
  217. - should be able to determine the affected_rows (FAILED - 1)
  218. - should raise an error when executing an invalid query
  219.  
  220. DataObjects::Mysql::Command Executing a Reader
  221. - should log reader queries when the level is Debug (0)
  222. - shouldn't log reader queries when the level isn't Debug (0)
  223.  
  224. DataObjects::Mysql::Command Executing a Non-Query
  225. - should log non-query statements when the level is Debug (0)
  226. - shouldn't log non-query statements when the level isn't Debug (0)
  227.  
  228. DataObjects::Mysql::Transaction
  229. - should execute "XA START 'id'" on #begin
  230. - should execute "XA COMMIT 'id'" on #commit
  231. - should execute ["XA END 'id'", "XA ROLLBACK 'id'"] on #rollback
  232. - should execute "XA ROLLBACK 'id'" on #rollback_prepared
  233. - should execute ["XA END 'id'", "XA PREPARE 'id'"] on #prepare
  234.  
  235. Pending:
  236. DataObjects::Mysql should support changing the character set (JDBC API does not provide an easy way to get the current character set)
  237. Called from /usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rspec-1.1.11/lib/spec/example/example_methods.rb:81:in `instance_eval'
  238. DataObjects::Mysql::Reader Date, Time, and DateTime should return 2009-01-08T01:44:16-11:00 offset to the current locale's Time Zone if they were inserted using a different timezone (We don't support non-local date input yet)
  239. Called from /usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rspec-1.1.11/lib/spec/example/example_methods.rb:81:in `instance_eval'
  240. DataObjects::Mysql::Reader Date, Time, and DateTime should return 2009-01-08T03:54:16-08:50 offset to the current locale's Time Zone if they were inserted using a different timezone (We don't support non-local date input yet)
  241. Called from /usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rspec-1.1.11/lib/spec/example/example_methods.rb:81:in `instance_eval'
  242. DataObjects::Mysql::Reader Date, Time, and DateTime should return 2009-01-08T04:44:16-08:00 offset to the current locale's Time Zone if they were inserted using a different timezone (We don't support non-local date input yet)
  243. Called from /usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rspec-1.1.11/lib/spec/example/example_methods.rb:81:in `instance_eval'
  244. DataObjects::Mysql::Reader Date, Time, and DateTime should return 2009-01-08T15:44:16+03:00 offset to the current locale's Time Zone if they were inserted using a different timezone (We don't support non-local date input yet)
  245. Called from /usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rspec-1.1.11/lib/spec/example/example_methods.rb:81:in `instance_eval'
  246. DataObjects::Mysql::Reader Date, Time, and DateTime should return 2009-01-08T18:14:16+05:30 offset to the current locale's Time Zone if they were inserted using a different timezone (We don't support non-local date input yet)
  247. Called from /usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rspec-1.1.11/lib/spec/example/example_methods.rb:81:in `instance_eval'
  248.  
  249. 1)
  250. 'DataObjects::Mysql::Reader executing a non-query should be able to determine the affected_rows' FAILED
  251. expected: 2,
  252. got: 1 (using ==)
  253. spec/integration/do_mysql_spec.rb:301:
  254.  
  255. Finished in 5.54791 seconds
  256.  
  257. 39 examples, 1 failure, 6 pending
  258. rake aborted!
  259. Command /usr/local/jruby-1.1.5/bin/jruby -I"/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rspec-1.1.11/lib" "/usr/local/jruby-1.1.5/lib/ruby/gems/1.8/gems/rspec-1.1.11/bin/spec" "spec/integration/do_mysql_spec.rb" "spec/integration/logging_spec.rb" "spec/integration/quoting_spec.rb" "spec/unit/transaction_spec.rb" --format specdoc --colour --loadby random failed
Add Comment
Please, Sign In to add comment