extface 0.2.5 → 0.3.0a

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0f43e7be656154e78b1e024bb74d6dbc833998e9
4
- data.tar.gz: e3287aa51199d87998f457a52011fd3228ee25ed
3
+ metadata.gz: 9b8000acc6d03fcd00d25bdeaecbf6570bdd3a36
4
+ data.tar.gz: 4adb5af73958105ca882659f95c5c93aba749801
5
5
  SHA512:
6
- metadata.gz: 7a1bc3344bfcc42fd1e215f21d3bf4f68a10f85f07d2cccd9bed97945ceecf25c713e610963975653e5d7241baa5ac0e37d7457af7a004b85c323e8983d952f0
7
- data.tar.gz: f4e0d647d299eb222e418b7556206ee86b45cd51d33aad8ec180d5407a563ff8089d9d24a01963e5eb2f277695aeed55e0a6492c724500c8e262aa4476e6cbf4
6
+ metadata.gz: 65f3e6b3f232ec6275bc667aaa34ca74b0ed1227978c3704ca1e4b119a9f1f36d886ed465bb915961ca5e28aedb043b41dafc49893f06968e65cec0d4ca78fa5
7
+ data.tar.gz: 87caa97854fff5fd6c665a65812cf9c3d863b683c5470d96cae4cca4e2458b6c2967e907212137236685d9bc4b34e545b571dc4f6b38c5f64021df7f70d681a1
@@ -0,0 +1,23 @@
1
+ window.extface_fiscal_jobs = [];
2
+ document.extface_fiscal_monitor = function(url) {
3
+ if (!!window.EventSource) {
4
+ var source = new EventSource(url);
5
+ var modal = $('#extface_fiscal_monitor');
6
+ var message = $('#extface_fiscal_message');
7
+
8
+ source.onmessage = function(e) {
9
+ message.html(e.data);
10
+ };
11
+
12
+ source.onopen = function(e) {
13
+ window.extface_fiscal_jobs.push(url);
14
+ modal.modal('show');
15
+ };
16
+
17
+ source.onerror = function(e) {
18
+ window.extface_fiscal_jobs.splice( $.inArray(url, window.extface_jobs), 1 );
19
+ source.close();
20
+ if (window.extface_fiscal_jobs.length == 0) setTimeout(function(){modal.modal('hide');},1000);
21
+ };
22
+ }
23
+ };
@@ -2,6 +2,8 @@ module Extface
2
2
  class ApplicationController < ActionController::Base
3
3
  prepend_before_filter :include_extra_module
4
4
 
5
+ helper_method :extface
6
+
5
7
  def index
6
8
  end
7
9
 
@@ -17,5 +19,9 @@ module Extface
17
19
  def include_extra_module
18
20
  self.class.send(:include, extface_mapping.i_extra_module) if extface_mapping.i_extra_module.present?
19
21
  end
22
+
23
+ def extface
24
+ try(extface_mapping.mount_point) || super # rails 4.1 fixed named route for engines mounted for resources
25
+ end
20
26
  end
21
27
  end
@@ -14,12 +14,14 @@ module Extface
14
14
  else
15
15
  #redis = Redis.new
16
16
  response.stream.write("data: Job #{@job.id} waiting for device connection...\n\n")
17
- Extface.redis_block do |r|
18
- r.subscribe(@job.id) do |on|
19
- on.message do |event, data|
20
- #p "data: #{data}\n\n"
21
- response.stream.write("data: #{data}\n\n") unless data == 'OK'
22
- r.unsubscribe if data == "Job #{@job.id} completed!" || data == "Job #{@job.id} failed!"
17
+ Timeout.timeout(Extface.device_timeout) do #never stay too long, TODO add SSE option to reconnect
18
+ Extface.redis_block do |r|
19
+ r.subscribe(@job.id) do |on|
20
+ on.message do |event, data|
21
+ p "@@@@ #{event}: #{data}\n\n"
22
+ response.stream.write("data: #{data}\n\n") unless data == 'OK'
23
+ r.unsubscribe if data == "Job #{@job.id} completed!" || data == "Job #{@job.id} failed!" #FIXME stupid
24
+ end
23
25
  end
24
26
  end
25
27
  end
@@ -54,5 +54,18 @@ module Extface
54
54
  end
55
55
  job
56
56
  end
57
+
58
+ #initial billing module fiscalization support
59
+ def fiscalize(billing_account, detailed = false)
60
+ if billing_account.instance_of?(Billing::Account) && billing_account.valid?
61
+ driver.sale_and_pay_items_session(
62
+ [].tap() do |payments|
63
+ billing_account.payments.each do |payment|
64
+ payments << Extface::Driver::Base::Fiscal::SaleItem.new(price: payment.value.to_f, text1: payment.description)
65
+ end
66
+ end
67
+ )
68
+ end
69
+ end
57
70
  end
58
71
  end
@@ -15,7 +15,9 @@ module Extface
15
15
  NAME = 'Daisy FX1200 (Serial)'.freeze
16
16
 
17
17
  RESPONSE_TIMEOUT = 3 #seconds
18
- INVALID_FRAME_RETRIES = 6 #seconds
18
+ INVALID_FRAME_RETRIES = 6 #count (bad length, bad checksum)
19
+ ACKS_MAX_WAIT = 60 #count / nothing is forever
20
+ NAKS_MAX_COUNT = 3 #count
19
21
 
20
22
  TAX_GROUPS_MAP = {
21
23
  1 => "\xc0",
@@ -33,16 +35,12 @@ module Extface
33
35
  include Extface::Driver::Daisy::CommandsFx1200
34
36
 
35
37
  def handle(buffer) #buffer is filled with multiple pushes, wait for full frame (ACKs)STX..PA2..PA1..ETX
36
- if buffer[/^\x16+$/] # skip if only ACKs
37
- return buffer.length
38
+ if frame_len = buffer.index("\x03") || buffer.index("\x16") || buffer.index("\x15")
39
+ rpush buffer[0..frame_len]
40
+ return frame_len+1 # return number of bytes processed
38
41
  else
39
- if frame_len = buffer.index("\x03") || buffer.index("\x15")
40
- rpush buffer[0..frame_len]
41
- return frame_len+1 # return number of bytes processed
42
- else
43
- #TODO check buffer.length
44
- return 0 #no bytes processed
45
- end
42
+ #TODO check buffer.length
43
+ return 0 #no bytes processed
46
44
  end
47
45
  end
48
46
 
@@ -188,16 +186,38 @@ module Extface
188
186
  def fsend(cmd, data = "") #return data or nil
189
187
  packet_data = build_packet(cmd, data)
190
188
  result = false
191
- INVALID_FRAME_RETRIES.times do |retries|
189
+ invalid_frames = 0
190
+ nak_messages = 0
191
+ push packet_data
192
+ ACKS_MAX_WAIT.times do |retries|
192
193
  errors.clear
193
- push packet_data
194
194
  if resp = frecv(RESPONSE_TIMEOUT)
195
195
  if resp.valid?
196
- result = resp.data
197
- break
196
+ human_status_errors(resp.status)
197
+ if errors.empty?
198
+ result = resp.data
199
+ break
200
+ else
201
+ raise errors.full_messages.join(',')
202
+ end
203
+ else #ack, nak or bad
204
+ if resp.nak?
205
+ nak_messages += 1
206
+ if nak_messages > NAKS_MAX_COUNT
207
+ errors.add :base, "#{NAKS_MAX_COUNT} NAKs Received. Abort!"
208
+ break
209
+ end
210
+ elsif !resp.ack?
211
+ invalid_frames += 1
212
+ if nak_messages > INVALID_FRAME_RETRIES
213
+ errors.add :base, "#{INVALID_FRAME_RETRIES} Broken Packets Received. Abort!"
214
+ break
215
+ end
216
+ end
217
+ push packet_data unless resp.ack?
198
218
  end
199
219
  end
200
- errors.add :base, "#{INVALID_FRAME_RETRIES} Broken Packets Received. Abort!"
220
+ errors.add :base, "#{ACKS_MAX_WAIT} ACKs Received. Abort!"
201
221
  end
202
222
  return result
203
223
  end
@@ -257,13 +277,13 @@ module Extface
257
277
 
258
278
  #errors.add :base, "Print Doc Allowed" unless (status[2].ord & 0x40).zero?
259
279
  #errors.add :base, "Non Fiscal Doc Open" unless (status[2].ord & 0x20).zero?
260
- errors.add :base, "Less Paper (Control)" unless (status[2].ord & 0x20).zero?
280
+ #errors.add :base, "Less Paper (Control)" unless (status[2].ord & 0x20).zero?
261
281
  #errors.add :base, "Fiscal Doc Open" unless (status[2].ord & 0x08).zero?
262
282
  errors.add :base, "No Paper (Control)" unless (status[2].ord & 0x04).zero?
263
283
  errors.add :base, "Less Paper" unless (status[2].ord & 0x02).zero?
264
284
  errors.add :base, "No Paper" unless (status[2].ord & 0x01).zero?
265
285
 
266
- case (status[3] & 0x7f)
286
+ case (status[3].ord & 0x7f)
267
287
  when 1 then errors.add :base, "Operation will result in the overflow"
268
288
  when 3 then errors.add :base, "No more sales for this doc"
269
289
  when 4 then errors.add :base, "No more payments for this doc"
@@ -313,26 +333,46 @@ module Extface
313
333
  @frame = match.to_a.first
314
334
  @len, @seq, @cmd, @data, @status, @bcc = match.captures
315
335
  else
316
- #TODO look for NAK
336
+ if buffer[/^\x16+$/] # only ACKs
337
+ @ack = true
338
+ elsif buffer.index("\x15")
339
+ @nak = true
340
+ end
317
341
  end
318
342
  end
319
343
 
344
+ def ack? #should wait, response is yet to come
345
+ !!@ack
346
+ end
347
+
348
+ def nak? #should retry command with same seq
349
+ !!@nak
350
+ end
351
+
320
352
  private
353
+ def unpacked_msg?
354
+ ack? || nak?
355
+ end
356
+
321
357
  def bcc_validation
322
- sum = 0
323
- frame[1..-6].each_byte do |byte|
324
- sum += byte
325
- end
326
- calc_bcc = "".tap() do |tbcc|
327
- 4.times do |halfbyte|
328
- tbcc.insert 0, (0x30 + ((sum >> (halfbyte*4)) & 0x0f)).chr
358
+ unless unpacked_msg?
359
+ sum = 0
360
+ frame[1..-6].each_byte do |byte|
361
+ sum += byte
362
+ end unless frame.nil?
363
+ calc_bcc = "".tap() do |tbcc|
364
+ 4.times do |halfbyte|
365
+ tbcc.insert 0, (0x30 + ((sum >> (halfbyte*4)) & 0x0f)).chr
366
+ end
329
367
  end
368
+ errors.add(:bcc, I18n.t('errors.messages.invalid')) if bcc != calc_bcc
330
369
  end
331
- errors.add(:bcc, I18n.t('errors.messages.invalid')) if bcc != calc_bcc
332
370
  end
333
371
 
334
372
  def len_validation
335
- errors.add(:len, I18n.t('errors.messages.invalid')) if len.ord != (frame[1..-6].length + 0x20)
373
+ unless unpacked_msg?
374
+ errors.add(:len, I18n.t('errors.messages.invalid')) if frame.nil? || len.ord != (frame[1..-6].length + 0x20)
375
+ end
336
376
  end
337
377
  end
338
378
  end
@@ -213,9 +213,10 @@ module Extface
213
213
  if stat_frame.valid?
214
214
  break if stat_frame.ready?
215
215
  else
216
- status_invalid_responses -= 1
217
- unless status_invalid_responses < INVALID_FRAME_RETRIES
216
+ status_invalid_responses += 1
217
+ if status_invalid_responses > INVALID_FRAME_RETRIES
218
218
  errors.add :base, "#{INVALID_FRAME_RETRIES} Broken Packets Received. Abort!"
219
+ break
219
220
  end
220
221
  end
221
222
  end
@@ -1,3 +1,3 @@
1
1
  module Extface
2
- VERSION = "0.2.5"
2
+ VERSION = "0.3.0a"
3
3
  end
Binary file
@@ -5211,3 +5211,718 @@ ExtfaceTest: test_truth
5211
5211
  -----------------------
5212
5212
   (0.1ms) rollback transaction
5213
5213
  Completed in 7ms
5214
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
5215
+  (199.6ms) DROP TABLE "extface_devices"
5216
+  (115.5ms) CREATE TABLE "extface_devices" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "uuid" varchar(255), "name" varchar(255), "extfaceable_id" integer, "extfaceable_type" varchar(255), "driver_id" integer, "created_at" datetime, "updated_at" datetime) 
5217
+  (106.3ms) DROP TABLE "extface_drivers"
5218
+  (107.2ms) CREATE TABLE "extface_drivers" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "type" varchar(255), "settings" text, "created_at" datetime, "updated_at" datetime) 
5219
+  (106.3ms) DROP TABLE "extface_jobs"
5220
+  (106.9ms) CREATE TABLE "extface_jobs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "device_id" integer, "created_at" datetime, "updated_at" datetime, "description" varchar(255), "error" varchar(255), "failed_at" datetime, "completed_at" datetime, "connected_at" datetime) 
5221
+  (0.2ms) select sqlite_version(*)
5222
+  (106.1ms) CREATE INDEX "index_extface_jobs_on_device_id" ON "extface_jobs" ("device_id")
5223
+  (107.7ms) DROP TABLE "extface_serial_configs"
5224
+  (131.7ms) CREATE TABLE "extface_serial_configs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "driver_id" integer, "serial_boud_rate" integer, "serial_data_length" integer, "serial_parity_check" integer, "serial_stop_bits" integer, "serial_handshake" integer, "created_at" datetime, "updated_at" datetime) 
5225
+  (131.0ms) DROP TABLE "shops"
5226
+  (132.0ms) CREATE TABLE "shops" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) 
5227
+  (0.3ms) SELECT version FROM "schema_migrations"
5228
+  (0.1ms) begin transaction
5229
+ Fixture Delete (0.1ms) DELETE FROM "extface_serial_configs"
5230
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-17 22:18:54', '2014-07-17 22:18:54', 980190962, 258259918)
5231
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-17 22:18:54', '2014-07-17 22:18:54', 298486374, 599072141)
5232
+ Fixture Delete (0.1ms) DELETE FROM "extface_devices"
5233
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID1', 'MyString1', '2014-07-17 22:18:54', '2014-07-17 22:18:54', 980190962, 'Shop', 980190962, 258259918)
5234
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID2', 'MyString2', '2014-07-17 22:18:54', '2014-07-17 22:18:54', 298486374, 'Shop', 980190962, 599072141)
5235
+ Fixture Delete (0.1ms) DELETE FROM "extface_drivers"
5236
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::GenericPos', '2014-07-17 22:18:54', '2014-07-17 22:18:54', 258259918)
5237
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarTsp200', '2014-07-17 22:18:54', '2014-07-17 22:18:54', 412842077)
5238
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarScp700', '2014-07-17 22:18:54', '2014-07-17 22:18:54', 599072141)
5239
+ Fixture Delete (0.1ms) DELETE FROM "extface_jobs"
5240
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-17 22:18:54', '2014-07-17 22:18:54', 980190962)
5241
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-17 22:18:54', '2014-07-17 22:18:54', 298486374)
5242
+ Fixture Delete (0.1ms) DELETE FROM "shops"
5243
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-17 22:18:54', '2014-07-17 22:18:54', 980190962)
5244
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-17 22:18:54', '2014-07-17 22:18:54', 298486374)
5245
+  (130.4ms) commit transaction
5246
+  (0.1ms) begin transaction
5247
+ ---------------------------------------------------------
5248
+ Extface::DevicesControllerTest: test_should_create_device
5249
+ ---------------------------------------------------------
5250
+ Extface::Device Load (0.3ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5251
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5252
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5253
+ Processing by Extface::DevicesController#create as HTML
5254
+ Parameters: {"shop_id"=>"980190962", "device"=>{"driver_class"=>"Extface::Driver::GenericPos"}}
5255
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5256
+  (0.1ms) SAVEPOINT active_record_1
5257
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5258
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5259
+ SQL (0.2ms) INSERT INTO "extface_drivers" ("created_at", "type", "updated_at") VALUES (?, ?, ?) [["created_at", "2014-07-17 22:18:54.644998"], ["type", "Extface::Driver::GenericPos"], ["updated_at", "2014-07-17 22:18:54.644998"]]
5260
+ SQL (0.1ms) INSERT INTO "extface_devices" ("created_at", "driver_id", "extfaceable_id", "extfaceable_type", "name", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-07-17 22:18:54.652262"], ["driver_id", 599072142], ["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["name", "3c131956f1b49b7709ad9403e385727f"], ["updated_at", "2014-07-17 22:18:54.652262"], ["uuid", "3c131956f1b49b7709ad9403e385727f"]]
5261
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5262
+ Redirected to
5263
+ Completed 500 Internal Server Error in 25ms
5264
+  (0.1ms) rollback transaction
5265
+  (0.0ms) begin transaction
5266
+ ----------------------------------------------------------
5267
+ Extface::DevicesControllerTest: test_should_destroy_device
5268
+ ----------------------------------------------------------
5269
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5270
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5271
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5272
+ Processing by Extface::DevicesController#destroy as HTML
5273
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5274
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5275
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5276
+  (0.1ms) SAVEPOINT active_record_1
5277
+ SQL (0.1ms) DELETE FROM "extface_devices" WHERE "extface_devices"."id" = ? [["id", 980190962]]
5278
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5279
+ Completed 500 Internal Server Error in 2ms
5280
+  (0.1ms) rollback transaction
5281
+  (0.0ms) begin transaction
5282
+ ----------------------------------------------------
5283
+ Extface::DevicesControllerTest: test_should_get_edit
5284
+ ----------------------------------------------------
5285
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5286
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5287
+ Processing by Extface::DevicesController#edit as HTML
5288
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5289
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5290
+ Extface::Device Load (0.0ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5291
+ Completed 500 Internal Server Error in 11ms
5292
+  (0.1ms) rollback transaction
5293
+  (0.1ms) begin transaction
5294
+ -----------------------------------------------------
5295
+ Extface::DevicesControllerTest: test_should_get_index
5296
+ -----------------------------------------------------
5297
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5298
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5299
+ Processing by Extface::DevicesController#index as HTML
5300
+ Parameters: {"shop_id"=>"980190962"}
5301
+ Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5302
+ Extface::Device Load (0.2ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"]]
5303
+ Completed 500 Internal Server Error in 7ms
5304
+  (0.1ms) rollback transaction
5305
+  (0.1ms) begin transaction
5306
+ ---------------------------------------------------
5307
+ Extface::DevicesControllerTest: test_should_get_new
5308
+ ---------------------------------------------------
5309
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5310
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5311
+ Processing by Extface::DevicesController#new as HTML
5312
+ Parameters: {"shop_id"=>"980190962"}
5313
+ Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5314
+ Completed 500 Internal Server Error in 3ms
5315
+  (0.1ms) rollback transaction
5316
+  (0.0ms) begin transaction
5317
+ -------------------------------------------------------
5318
+ Extface::DevicesControllerTest: test_should_show_device
5319
+ -------------------------------------------------------
5320
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5321
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5322
+ Processing by Extface::DevicesController#show as HTML
5323
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5324
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5325
+ Extface::Device Load (0.0ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5326
+ Completed 500 Internal Server Error in 4ms
5327
+  (0.1ms) rollback transaction
5328
+  (0.0ms) begin transaction
5329
+ ---------------------------------------------------------
5330
+ Extface::DevicesControllerTest: test_should_update_device
5331
+ ---------------------------------------------------------
5332
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5333
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5334
+ Processing by Extface::DevicesController#update as HTML
5335
+ Parameters: {"shop_id"=>"980190962", "device"=>{"name"=>"new_name"}, "id"=>"980190962"}
5336
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5337
+ Extface::Device Load (0.0ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5338
+  (0.0ms) SAVEPOINT active_record_1
5339
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" = 'new_name' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5340
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" = 'MyUUID1' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5341
+ SQL (0.2ms) UPDATE "extface_devices" SET "name" = ?, "updated_at" = ? WHERE "extface_devices"."id" = 980190962 [["name", "new_name"], ["updated_at", "2014-07-17 22:18:54.713439"]]
5342
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5343
+ Redirected to
5344
+ Completed 500 Internal Server Error in 5ms
5345
+  (0.1ms) rollback transaction
5346
+  (0.1ms) begin transaction
5347
+ -------------------------------------------------
5348
+ Extface::JobsControllerTest: test_should_show_job
5349
+ -------------------------------------------------
5350
+ Extface::Job Load (0.1ms) SELECT "extface_jobs".* FROM "extface_jobs" WHERE "extface_jobs"."id" = ? LIMIT 1 [["id", 980190962]]
5351
+  (0.1ms) rollback transaction
5352
+  (0.1ms) begin transaction
5353
+ -----------------------
5354
+ ExtfaceTest: test_truth
5355
+ -----------------------
5356
+  (0.0ms) rollback transaction
5357
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
5358
+  (111.5ms) DROP TABLE "extface_devices"
5359
+  (107.4ms) CREATE TABLE "extface_devices" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "uuid" varchar(255), "name" varchar(255), "extfaceable_id" integer, "extfaceable_type" varchar(255), "driver_id" integer, "created_at" datetime, "updated_at" datetime) 
5360
+  (106.4ms) DROP TABLE "extface_drivers"
5361
+  (115.4ms) CREATE TABLE "extface_drivers" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "type" varchar(255), "settings" text, "created_at" datetime, "updated_at" datetime) 
5362
+  (114.6ms) DROP TABLE "extface_jobs"
5363
+  (107.0ms) CREATE TABLE "extface_jobs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "device_id" integer, "created_at" datetime, "updated_at" datetime, "description" varchar(255), "error" varchar(255), "failed_at" datetime, "completed_at" datetime, "connected_at" datetime) 
5364
+  (0.3ms) select sqlite_version(*)
5365
+  (105.9ms) CREATE INDEX "index_extface_jobs_on_device_id" ON "extface_jobs" ("device_id")
5366
+  (114.6ms) DROP TABLE "extface_serial_configs"
5367
+  (131.5ms) CREATE TABLE "extface_serial_configs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "driver_id" integer, "serial_boud_rate" integer, "serial_data_length" integer, "serial_parity_check" integer, "serial_stop_bits" integer, "serial_handshake" integer, "created_at" datetime, "updated_at" datetime) 
5368
+  (139.3ms) DROP TABLE "shops"
5369
+  (123.7ms) CREATE TABLE "shops" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) 
5370
+  (0.3ms) SELECT version FROM "schema_migrations"
5371
+  (0.1ms) begin transaction
5372
+ Fixture Delete (0.1ms) DELETE FROM "extface_serial_configs"
5373
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-18 10:32:32', '2014-07-18 10:32:32', 980190962, 258259918)
5374
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-18 10:32:32', '2014-07-18 10:32:32', 298486374, 599072141)
5375
+ Fixture Delete (0.1ms) DELETE FROM "extface_devices"
5376
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID1', 'MyString1', '2014-07-18 10:32:32', '2014-07-18 10:32:32', 980190962, 'Shop', 980190962, 258259918)
5377
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID2', 'MyString2', '2014-07-18 10:32:32', '2014-07-18 10:32:32', 298486374, 'Shop', 980190962, 599072141)
5378
+ Fixture Delete (0.1ms) DELETE FROM "extface_drivers"
5379
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::GenericPos', '2014-07-18 10:32:32', '2014-07-18 10:32:32', 258259918)
5380
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarTsp200', '2014-07-18 10:32:32', '2014-07-18 10:32:32', 412842077)
5381
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarScp700', '2014-07-18 10:32:32', '2014-07-18 10:32:32', 599072141)
5382
+ Fixture Delete (0.1ms) DELETE FROM "extface_jobs"
5383
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-18 10:32:32', '2014-07-18 10:32:32', 980190962)
5384
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-18 10:32:32', '2014-07-18 10:32:32', 298486374)
5385
+ Fixture Delete (0.1ms) DELETE FROM "shops"
5386
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-18 10:32:32', '2014-07-18 10:32:32', 980190962)
5387
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-18 10:32:32', '2014-07-18 10:32:32', 298486374)
5388
+  (126.1ms) commit transaction
5389
+  (0.1ms) begin transaction
5390
+ -------------------------------------------------
5391
+ Extface::JobsControllerTest: test_should_show_job
5392
+ -------------------------------------------------
5393
+ Extface::Job Load (0.3ms) SELECT "extface_jobs".* FROM "extface_jobs" WHERE "extface_jobs"."id" = ? LIMIT 1 [["id", 980190962]]
5394
+  (0.1ms) rollback transaction
5395
+  (0.1ms) begin transaction
5396
+ ---------------------------------------------------------
5397
+ Extface::DevicesControllerTest: test_should_create_device
5398
+ ---------------------------------------------------------
5399
+ Extface::Device Load (0.2ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5400
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5401
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5402
+ Processing by Extface::DevicesController#create as HTML
5403
+ Parameters: {"shop_id"=>"980190962", "device"=>{"driver_class"=>"Extface::Driver::GenericPos"}}
5404
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5405
+  (0.1ms) SAVEPOINT active_record_1
5406
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5407
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5408
+ SQL (0.2ms) INSERT INTO "extface_drivers" ("created_at", "type", "updated_at") VALUES (?, ?, ?) [["created_at", "2014-07-18 10:32:32.496777"], ["type", "Extface::Driver::GenericPos"], ["updated_at", "2014-07-18 10:32:32.496777"]]
5409
+ SQL (0.1ms) INSERT INTO "extface_devices" ("created_at", "driver_id", "extfaceable_id", "extfaceable_type", "name", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-07-18 10:32:32.503470"], ["driver_id", 599072142], ["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["name", "2e01a96126669b56d56b9f1a2ff03628"], ["updated_at", "2014-07-18 10:32:32.503470"], ["uuid", "2e01a96126669b56d56b9f1a2ff03628"]]
5410
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5411
+ Redirected to
5412
+ Completed 500 Internal Server Error in 23ms
5413
+  (0.1ms) rollback transaction
5414
+  (0.1ms) begin transaction
5415
+ ----------------------------------------------------------
5416
+ Extface::DevicesControllerTest: test_should_destroy_device
5417
+ ----------------------------------------------------------
5418
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5419
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5420
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5421
+ Processing by Extface::DevicesController#destroy as HTML
5422
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5423
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5424
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5425
+  (0.0ms) SAVEPOINT active_record_1
5426
+ SQL (0.1ms) DELETE FROM "extface_devices" WHERE "extface_devices"."id" = ? [["id", 980190962]]
5427
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5428
+ Completed 500 Internal Server Error in 2ms
5429
+  (0.1ms) rollback transaction
5430
+  (0.1ms) begin transaction
5431
+ ----------------------------------------------------
5432
+ Extface::DevicesControllerTest: test_should_get_edit
5433
+ ----------------------------------------------------
5434
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5435
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5436
+ Processing by Extface::DevicesController#edit as HTML
5437
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5438
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5439
+ Extface::Device Load (0.0ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5440
+ Completed 500 Internal Server Error in 20ms
5441
+  (0.1ms) rollback transaction
5442
+  (0.1ms) begin transaction
5443
+ -----------------------------------------------------
5444
+ Extface::DevicesControllerTest: test_should_get_index
5445
+ -----------------------------------------------------
5446
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5447
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5448
+ Processing by Extface::DevicesController#index as HTML
5449
+ Parameters: {"shop_id"=>"980190962"}
5450
+ Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5451
+ Extface::Device Load (0.2ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"]]
5452
+ Completed 500 Internal Server Error in 6ms
5453
+  (0.1ms) rollback transaction
5454
+  (0.1ms) begin transaction
5455
+ ---------------------------------------------------
5456
+ Extface::DevicesControllerTest: test_should_get_new
5457
+ ---------------------------------------------------
5458
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5459
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5460
+ Processing by Extface::DevicesController#new as HTML
5461
+ Parameters: {"shop_id"=>"980190962"}
5462
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5463
+ Completed 500 Internal Server Error in 3ms
5464
+  (0.1ms) rollback transaction
5465
+  (0.1ms) begin transaction
5466
+ -------------------------------------------------------
5467
+ Extface::DevicesControllerTest: test_should_show_device
5468
+ -------------------------------------------------------
5469
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5470
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5471
+ Processing by Extface::DevicesController#show as HTML
5472
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5473
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5474
+ Extface::Device Load (0.0ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5475
+ Completed 500 Internal Server Error in 4ms
5476
+  (0.1ms) rollback transaction
5477
+  (0.1ms) begin transaction
5478
+ ---------------------------------------------------------
5479
+ Extface::DevicesControllerTest: test_should_update_device
5480
+ ---------------------------------------------------------
5481
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5482
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5483
+ Processing by Extface::DevicesController#update as HTML
5484
+ Parameters: {"shop_id"=>"980190962", "device"=>{"name"=>"new_name"}, "id"=>"980190962"}
5485
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5486
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5487
+  (0.1ms) SAVEPOINT active_record_1
5488
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" = 'new_name' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5489
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" = 'MyUUID1' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5490
+ SQL (0.2ms) UPDATE "extface_devices" SET "name" = ?, "updated_at" = ? WHERE "extface_devices"."id" = 980190962 [["name", "new_name"], ["updated_at", "2014-07-18 10:32:32.565471"]]
5491
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5492
+ Redirected to
5493
+ Completed 500 Internal Server Error in 6ms
5494
+  (0.1ms) rollback transaction
5495
+  (0.1ms) begin transaction
5496
+ -----------------------
5497
+ ExtfaceTest: test_truth
5498
+ -----------------------
5499
+  (0.0ms) rollback transaction
5500
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
5501
+  (191.0ms) DROP TABLE "extface_devices"
5502
+  (115.1ms) CREATE TABLE "extface_devices" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "uuid" varchar(255), "name" varchar(255), "extfaceable_id" integer, "extfaceable_type" varchar(255), "driver_id" integer, "created_at" datetime, "updated_at" datetime) 
5503
+  (106.4ms) DROP TABLE "extface_drivers"
5504
+  (107.0ms) CREATE TABLE "extface_drivers" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "type" varchar(255), "settings" text, "created_at" datetime, "updated_at" datetime) 
5505
+  (107.6ms) DROP TABLE "extface_jobs"
5506
+  (107.3ms) CREATE TABLE "extface_jobs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "device_id" integer, "created_at" datetime, "updated_at" datetime, "description" varchar(255), "error" varchar(255), "failed_at" datetime, "completed_at" datetime, "connected_at" datetime) 
5507
+  (0.1ms) select sqlite_version(*)
5508
+  (107.1ms) CREATE INDEX "index_extface_jobs_on_device_id" ON "extface_jobs" ("device_id")
5509
+  (114.5ms) DROP TABLE "extface_serial_configs"
5510
+  (115.5ms) CREATE TABLE "extface_serial_configs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "driver_id" integer, "serial_boud_rate" integer, "serial_data_length" integer, "serial_parity_check" integer, "serial_stop_bits" integer, "serial_handshake" integer, "created_at" datetime, "updated_at" datetime) 
5511
+  (139.2ms) DROP TABLE "shops"
5512
+  (123.6ms) CREATE TABLE "shops" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) 
5513
+  (0.3ms) SELECT version FROM "schema_migrations"
5514
+  (0.1ms) begin transaction
5515
+ Fixture Delete (0.2ms) DELETE FROM "extface_serial_configs"
5516
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-18 12:44:44', '2014-07-18 12:44:44', 980190962, 258259918)
5517
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-18 12:44:44', '2014-07-18 12:44:44', 298486374, 599072141)
5518
+ Fixture Delete (0.1ms) DELETE FROM "extface_devices"
5519
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID1', 'MyString1', '2014-07-18 12:44:44', '2014-07-18 12:44:44', 980190962, 'Shop', 980190962, 258259918)
5520
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID2', 'MyString2', '2014-07-18 12:44:44', '2014-07-18 12:44:44', 298486374, 'Shop', 980190962, 599072141)
5521
+ Fixture Delete (0.1ms) DELETE FROM "extface_drivers"
5522
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::GenericPos', '2014-07-18 12:44:44', '2014-07-18 12:44:44', 258259918)
5523
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarTsp200', '2014-07-18 12:44:44', '2014-07-18 12:44:44', 412842077)
5524
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarScp700', '2014-07-18 12:44:44', '2014-07-18 12:44:44', 599072141)
5525
+ Fixture Delete (0.1ms) DELETE FROM "extface_jobs"
5526
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-18 12:44:44', '2014-07-18 12:44:44', 980190962)
5527
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-18 12:44:44', '2014-07-18 12:44:44', 298486374)
5528
+ Fixture Delete (0.1ms) DELETE FROM "shops"
5529
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-18 12:44:44', '2014-07-18 12:44:44', 980190962)
5530
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-18 12:44:44', '2014-07-18 12:44:44', 298486374)
5531
+  (127.0ms) commit transaction
5532
+  (0.1ms) begin transaction
5533
+ -------------------------------------------------
5534
+ Extface::JobsControllerTest: test_should_show_job
5535
+ -------------------------------------------------
5536
+ Extface::Job Load (0.3ms) SELECT "extface_jobs".* FROM "extface_jobs" WHERE "extface_jobs"."id" = ? LIMIT 1 [["id", 980190962]]
5537
+  (0.1ms) rollback transaction
5538
+  (0.1ms) begin transaction
5539
+ -----------------------
5540
+ ExtfaceTest: test_truth
5541
+ -----------------------
5542
+  (0.1ms) rollback transaction
5543
+  (0.1ms) begin transaction
5544
+ ---------------------------------------------------------
5545
+ Extface::DevicesControllerTest: test_should_create_device
5546
+ ---------------------------------------------------------
5547
+ Extface::Device Load (0.2ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5548
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5549
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5550
+ Processing by Extface::DevicesController#create as HTML
5551
+ Parameters: {"shop_id"=>"980190962", "device"=>{"driver_class"=>"Extface::Driver::GenericPos"}}
5552
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5553
+  (0.1ms) SAVEPOINT active_record_1
5554
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5555
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5556
+ SQL (0.2ms) INSERT INTO "extface_drivers" ("created_at", "type", "updated_at") VALUES (?, ?, ?) [["created_at", "2014-07-18 12:44:45.172626"], ["type", "Extface::Driver::GenericPos"], ["updated_at", "2014-07-18 12:44:45.172626"]]
5557
+ SQL (0.2ms) INSERT INTO "extface_devices" ("created_at", "driver_id", "extfaceable_id", "extfaceable_type", "name", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-07-18 12:44:45.179600"], ["driver_id", 599072142], ["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["name", "50bd03ba39a62e88276c5271c40f6e03"], ["updated_at", "2014-07-18 12:44:45.179600"], ["uuid", "50bd03ba39a62e88276c5271c40f6e03"]]
5558
+  (0.1ms) RELEASE SAVEPOINT active_record_1
5559
+ Redirected to
5560
+ Completed 500 Internal Server Error in 26ms
5561
+  (0.1ms) rollback transaction
5562
+  (0.0ms) begin transaction
5563
+ ----------------------------------------------------------
5564
+ Extface::DevicesControllerTest: test_should_destroy_device
5565
+ ----------------------------------------------------------
5566
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5567
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5568
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5569
+ Processing by Extface::DevicesController#destroy as HTML
5570
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5571
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5572
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5573
+  (0.0ms) SAVEPOINT active_record_1
5574
+ SQL (0.1ms) DELETE FROM "extface_devices" WHERE "extface_devices"."id" = ? [["id", 980190962]]
5575
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5576
+ Completed 500 Internal Server Error in 2ms
5577
+  (0.1ms) rollback transaction
5578
+  (0.1ms) begin transaction
5579
+ ----------------------------------------------------
5580
+ Extface::DevicesControllerTest: test_should_get_edit
5581
+ ----------------------------------------------------
5582
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5583
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5584
+ Processing by Extface::DevicesController#edit as HTML
5585
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5586
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5587
+ Extface::Device Load (0.0ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5588
+ Completed 500 Internal Server Error in 17ms
5589
+  (0.1ms) rollback transaction
5590
+  (0.0ms) begin transaction
5591
+ -----------------------------------------------------
5592
+ Extface::DevicesControllerTest: test_should_get_index
5593
+ -----------------------------------------------------
5594
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5595
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5596
+ Processing by Extface::DevicesController#index as HTML
5597
+ Parameters: {"shop_id"=>"980190962"}
5598
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5599
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"]]
5600
+ Completed 500 Internal Server Error in 4ms
5601
+  (0.1ms) rollback transaction
5602
+  (0.0ms) begin transaction
5603
+ ---------------------------------------------------
5604
+ Extface::DevicesControllerTest: test_should_get_new
5605
+ ---------------------------------------------------
5606
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5607
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5608
+ Processing by Extface::DevicesController#new as HTML
5609
+ Parameters: {"shop_id"=>"980190962"}
5610
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5611
+ Completed 500 Internal Server Error in 3ms
5612
+  (0.1ms) rollback transaction
5613
+  (0.1ms) begin transaction
5614
+ -------------------------------------------------------
5615
+ Extface::DevicesControllerTest: test_should_show_device
5616
+ -------------------------------------------------------
5617
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5618
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5619
+ Processing by Extface::DevicesController#show as HTML
5620
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5621
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5622
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5623
+ Completed 500 Internal Server Error in 5ms
5624
+  (0.1ms) rollback transaction
5625
+  (0.0ms) begin transaction
5626
+ ---------------------------------------------------------
5627
+ Extface::DevicesControllerTest: test_should_update_device
5628
+ ---------------------------------------------------------
5629
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5630
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5631
+ Processing by Extface::DevicesController#update as HTML
5632
+ Parameters: {"shop_id"=>"980190962", "device"=>{"name"=>"new_name"}, "id"=>"980190962"}
5633
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5634
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5635
+  (0.1ms) SAVEPOINT active_record_1
5636
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" = 'new_name' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5637
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" = 'MyUUID1' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5638
+ SQL (0.2ms) UPDATE "extface_devices" SET "name" = ?, "updated_at" = ? WHERE "extface_devices"."id" = 980190962 [["name", "new_name"], ["updated_at", "2014-07-18 12:44:45.234785"]]
5639
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5640
+ Redirected to
5641
+ Completed 500 Internal Server Error in 6ms
5642
+  (0.1ms) rollback transaction
5643
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
5644
+  (163.2ms) DROP TABLE "extface_devices"
5645
+  (106.8ms) CREATE TABLE "extface_devices" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "uuid" varchar(255), "name" varchar(255), "extfaceable_id" integer, "extfaceable_type" varchar(255), "driver_id" integer, "created_at" datetime, "updated_at" datetime) 
5646
+  (114.6ms) DROP TABLE "extface_drivers"
5647
+  (107.3ms) CREATE TABLE "extface_drivers" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "type" varchar(255), "settings" text, "created_at" datetime, "updated_at" datetime) 
5648
+  (106.4ms) DROP TABLE "extface_jobs"
5649
+  (107.1ms) CREATE TABLE "extface_jobs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "device_id" integer, "created_at" datetime, "updated_at" datetime, "description" varchar(255), "error" varchar(255), "failed_at" datetime, "completed_at" datetime, "connected_at" datetime) 
5650
+  (0.2ms) select sqlite_version(*)
5651
+  (106.2ms) CREATE INDEX "index_extface_jobs_on_device_id" ON "extface_jobs" ("device_id")
5652
+  (337.0ms) DROP TABLE "extface_serial_configs"
5653
+  (115.5ms) CREATE TABLE "extface_serial_configs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "driver_id" integer, "serial_boud_rate" integer, "serial_data_length" integer, "serial_parity_check" integer, "serial_stop_bits" integer, "serial_handshake" integer, "created_at" datetime, "updated_at" datetime) 
5654
+  (122.6ms) DROP TABLE "shops"
5655
+  (140.3ms) CREATE TABLE "shops" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) 
5656
+  (0.3ms) SELECT version FROM "schema_migrations"
5657
+  (0.1ms) begin transaction
5658
+ Fixture Delete (0.1ms) DELETE FROM "extface_serial_configs"
5659
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-18 19:39:04', '2014-07-18 19:39:04', 980190962, 258259918)
5660
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-18 19:39:04', '2014-07-18 19:39:04', 298486374, 599072141)
5661
+ Fixture Delete (0.1ms) DELETE FROM "extface_devices"
5662
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID1', 'MyString1', '2014-07-18 19:39:04', '2014-07-18 19:39:04', 980190962, 'Shop', 980190962, 258259918)
5663
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID2', 'MyString2', '2014-07-18 19:39:04', '2014-07-18 19:39:04', 298486374, 'Shop', 980190962, 599072141)
5664
+ Fixture Delete (0.1ms) DELETE FROM "extface_drivers"
5665
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::GenericPos', '2014-07-18 19:39:04', '2014-07-18 19:39:04', 258259918)
5666
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarTsp200', '2014-07-18 19:39:04', '2014-07-18 19:39:04', 412842077)
5667
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarScp700', '2014-07-18 19:39:04', '2014-07-18 19:39:04', 599072141)
5668
+ Fixture Delete (0.1ms) DELETE FROM "extface_jobs"
5669
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-18 19:39:04', '2014-07-18 19:39:04', 980190962)
5670
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-18 19:39:04', '2014-07-18 19:39:04', 298486374)
5671
+ Fixture Delete (0.1ms) DELETE FROM "shops"
5672
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-18 19:39:04', '2014-07-18 19:39:04', 980190962)
5673
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-18 19:39:04', '2014-07-18 19:39:04', 298486374)
5674
+  (126.6ms) commit transaction
5675
+  (0.2ms) begin transaction
5676
+ -----------------------
5677
+ ExtfaceTest: test_truth
5678
+ -----------------------
5679
+  (0.0ms) rollback transaction
5680
+  (0.0ms) begin transaction
5681
+ ---------------------------------------------------------
5682
+ Extface::DevicesControllerTest: test_should_create_device
5683
+ ---------------------------------------------------------
5684
+ Extface::Device Load (0.2ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5685
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5686
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5687
+ Processing by Extface::DevicesController#create as HTML
5688
+ Parameters: {"shop_id"=>"980190962", "device"=>{"driver_class"=>"Extface::Driver::GenericPos"}}
5689
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5690
+  (0.1ms) SAVEPOINT active_record_1
5691
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5692
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5693
+ SQL (0.3ms) INSERT INTO "extface_drivers" ("created_at", "type", "updated_at") VALUES (?, ?, ?) [["created_at", "2014-07-18 19:39:04.499951"], ["type", "Extface::Driver::GenericPos"], ["updated_at", "2014-07-18 19:39:04.499951"]]
5694
+ SQL (0.2ms) INSERT INTO "extface_devices" ("created_at", "driver_id", "extfaceable_id", "extfaceable_type", "name", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-07-18 19:39:04.507355"], ["driver_id", 599072142], ["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["name", "0bf2b4baa741ae713aff8c84b8ac723d"], ["updated_at", "2014-07-18 19:39:04.507355"], ["uuid", "0bf2b4baa741ae713aff8c84b8ac723d"]]
5695
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5696
+ Redirected to
5697
+ Completed 500 Internal Server Error in 24ms
5698
+  (0.1ms) rollback transaction
5699
+  (0.1ms) begin transaction
5700
+ ----------------------------------------------------------
5701
+ Extface::DevicesControllerTest: test_should_destroy_device
5702
+ ----------------------------------------------------------
5703
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5704
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5705
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5706
+ Processing by Extface::DevicesController#destroy as HTML
5707
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5708
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5709
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5710
+  (0.0ms) SAVEPOINT active_record_1
5711
+ SQL (0.1ms) DELETE FROM "extface_devices" WHERE "extface_devices"."id" = ? [["id", 980190962]]
5712
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5713
+ Completed 500 Internal Server Error in 2ms
5714
+  (0.1ms) rollback transaction
5715
+  (0.1ms) begin transaction
5716
+ ----------------------------------------------------
5717
+ Extface::DevicesControllerTest: test_should_get_edit
5718
+ ----------------------------------------------------
5719
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5720
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5721
+ Processing by Extface::DevicesController#edit as HTML
5722
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5723
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5724
+ Extface::Device Load (0.0ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5725
+ Completed 500 Internal Server Error in 9ms
5726
+  (0.1ms) rollback transaction
5727
+  (0.1ms) begin transaction
5728
+ -----------------------------------------------------
5729
+ Extface::DevicesControllerTest: test_should_get_index
5730
+ -----------------------------------------------------
5731
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5732
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5733
+ Processing by Extface::DevicesController#index as HTML
5734
+ Parameters: {"shop_id"=>"980190962"}
5735
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5736
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"]]
5737
+ Completed 500 Internal Server Error in 4ms
5738
+  (0.1ms) rollback transaction
5739
+  (0.1ms) begin transaction
5740
+ ---------------------------------------------------
5741
+ Extface::DevicesControllerTest: test_should_get_new
5742
+ ---------------------------------------------------
5743
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5744
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5745
+ Processing by Extface::DevicesController#new as HTML
5746
+ Parameters: {"shop_id"=>"980190962"}
5747
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5748
+ Completed 500 Internal Server Error in 10ms
5749
+  (0.1ms) rollback transaction
5750
+  (0.1ms) begin transaction
5751
+ -------------------------------------------------------
5752
+ Extface::DevicesControllerTest: test_should_show_device
5753
+ -------------------------------------------------------
5754
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5755
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5756
+ Processing by Extface::DevicesController#show as HTML
5757
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5758
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5759
+ Extface::Device Load (0.0ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5760
+ Completed 500 Internal Server Error in 4ms
5761
+  (0.1ms) rollback transaction
5762
+  (0.1ms) begin transaction
5763
+ ---------------------------------------------------------
5764
+ Extface::DevicesControllerTest: test_should_update_device
5765
+ ---------------------------------------------------------
5766
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5767
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5768
+ Processing by Extface::DevicesController#update as HTML
5769
+ Parameters: {"shop_id"=>"980190962", "device"=>{"name"=>"new_name"}, "id"=>"980190962"}
5770
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5771
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5772
+  (0.1ms) SAVEPOINT active_record_1
5773
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" = 'new_name' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5774
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" = 'MyUUID1' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5775
+ SQL (0.2ms) UPDATE "extface_devices" SET "name" = ?, "updated_at" = ? WHERE "extface_devices"."id" = 980190962 [["name", "new_name"], ["updated_at", "2014-07-18 19:39:04.562945"]]
5776
+  (0.0ms) RELEASE SAVEPOINT active_record_1
5777
+ Redirected to
5778
+ Completed 500 Internal Server Error in 6ms
5779
+  (0.1ms) rollback transaction
5780
+  (0.1ms) begin transaction
5781
+ -------------------------------------------------
5782
+ Extface::JobsControllerTest: test_should_show_job
5783
+ -------------------------------------------------
5784
+ Extface::Job Load (0.2ms) SELECT "extface_jobs".* FROM "extface_jobs" WHERE "extface_jobs"."id" = ? LIMIT 1 [["id", 980190962]]
5785
+  (0.1ms) rollback transaction
5786
+ ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"
5787
+  (134.4ms) DROP TABLE "extface_devices"
5788
+  (107.1ms) CREATE TABLE "extface_devices" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "uuid" varchar(255), "name" varchar(255), "extfaceable_id" integer, "extfaceable_type" varchar(255), "driver_id" integer, "created_at" datetime, "updated_at" datetime) 
5789
+  (106.2ms) DROP TABLE "extface_drivers"
5790
+  (107.1ms) CREATE TABLE "extface_drivers" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "type" varchar(255), "settings" text, "created_at" datetime, "updated_at" datetime) 
5791
+  (107.2ms) DROP TABLE "extface_jobs"
5792
+  (107.1ms) CREATE TABLE "extface_jobs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "device_id" integer, "created_at" datetime, "updated_at" datetime, "description" varchar(255), "error" varchar(255), "failed_at" datetime, "completed_at" datetime, "connected_at" datetime) 
5793
+  (0.3ms) select sqlite_version(*)
5794
+  (122.3ms) CREATE INDEX "index_extface_jobs_on_device_id" ON "extface_jobs" ("device_id")
5795
+  (130.9ms) DROP TABLE "extface_serial_configs"
5796
+  (140.0ms) CREATE TABLE "extface_serial_configs" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "driver_id" integer, "serial_boud_rate" integer, "serial_data_length" integer, "serial_parity_check" integer, "serial_stop_bits" integer, "serial_handshake" integer, "created_at" datetime, "updated_at" datetime) 
5797
+  (122.6ms) DROP TABLE "shops"
5798
+  (123.6ms) CREATE TABLE "shops" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) 
5799
+  (0.3ms) SELECT version FROM "schema_migrations"
5800
+  (0.1ms) begin transaction
5801
+ Fixture Delete (0.2ms) DELETE FROM "extface_serial_configs"
5802
+ Fixture Insert (0.2ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-31 12:14:43', '2014-07-31 12:14:43', 980190962, 258259918)
5803
+ Fixture Insert (0.1ms) INSERT INTO "extface_serial_configs" ("serial_boud_rate", "serial_data_length", "serial_parity_check", "serial_stop_bits", "serial_handshake", "created_at", "updated_at", "id", "driver_id") VALUES (1, 1, 1, 1, 1, '2014-07-31 12:14:43', '2014-07-31 12:14:43', 298486374, 599072141)
5804
+ Fixture Delete (0.1ms) DELETE FROM "extface_devices"
5805
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID1', 'MyString1', '2014-07-31 12:14:43', '2014-07-31 12:14:43', 980190962, 'Shop', 980190962, 258259918)
5806
+ Fixture Insert (0.1ms) INSERT INTO "extface_devices" ("uuid", "name", "created_at", "updated_at", "id", "extfaceable_type", "extfaceable_id", "driver_id") VALUES ('MyUUID2', 'MyString2', '2014-07-31 12:14:43', '2014-07-31 12:14:43', 298486374, 'Shop', 980190962, 599072141)
5807
+ Fixture Delete (0.2ms) DELETE FROM "extface_drivers"
5808
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::GenericPos', '2014-07-31 12:14:43', '2014-07-31 12:14:43', 258259918)
5809
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarTsp200', '2014-07-31 12:14:43', '2014-07-31 12:14:43', 412842077)
5810
+ Fixture Insert (0.1ms) INSERT INTO "extface_drivers" ("type", "created_at", "updated_at", "id") VALUES ('Extface::Driver::StarScp700', '2014-07-31 12:14:43', '2014-07-31 12:14:43', 599072141)
5811
+ Fixture Delete (0.1ms) DELETE FROM "extface_jobs"
5812
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-31 12:14:43', '2014-07-31 12:14:43', 980190962)
5813
+ Fixture Insert (0.1ms) INSERT INTO "extface_jobs" ("device_id", "created_at", "updated_at", "id") VALUES (NULL, '2014-07-31 12:14:43', '2014-07-31 12:14:43', 298486374)
5814
+ Fixture Delete (0.1ms) DELETE FROM "shops"
5815
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-31 12:14:43', '2014-07-31 12:14:43', 980190962)
5816
+ Fixture Insert (0.1ms) INSERT INTO "shops" ("created_at", "updated_at", "id") VALUES ('2014-07-31 12:14:43', '2014-07-31 12:14:43', 298486374)
5817
+  (127.7ms) commit transaction
5818
+  (0.1ms) begin transaction
5819
+ -------------------------------------------------
5820
+ Extface::JobsControllerTest: test_should_show_job
5821
+ -------------------------------------------------
5822
+ Extface::Job Load (0.5ms) SELECT "extface_jobs".* FROM "extface_jobs" WHERE "extface_jobs"."id" = ? LIMIT 1 [["id", 980190962]]
5823
+  (0.2ms) rollback transaction
5824
+  (0.1ms) begin transaction
5825
+ -----------------------
5826
+ ExtfaceTest: test_truth
5827
+ -----------------------
5828
+  (0.1ms) rollback transaction
5829
+  (0.1ms) begin transaction
5830
+ ---------------------------------------------------------
5831
+ Extface::DevicesControllerTest: test_should_create_device
5832
+ ---------------------------------------------------------
5833
+ Extface::Device Load (0.3ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5834
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5835
+ Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5836
+ Processing by Extface::DevicesController#create as HTML
5837
+ Parameters: {"shop_id"=>"980190962", "device"=>{"driver_class"=>"Extface::Driver::GenericPos"}}
5838
+ Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5839
+  (0.1ms) SAVEPOINT active_record_1
5840
+ Extface::Device Exists (0.2ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5841
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" IS NULL AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5842
+ SQL (0.4ms) INSERT INTO "extface_drivers" ("created_at", "type", "updated_at") VALUES (?, ?, ?) [["created_at", "2014-07-31 12:14:44.062806"], ["type", "Extface::Driver::GenericPos"], ["updated_at", "2014-07-31 12:14:44.062806"]]
5843
+ SQL (0.2ms) INSERT INTO "extface_devices" ("created_at", "driver_id", "extfaceable_id", "extfaceable_type", "name", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-07-31 12:14:44.075855"], ["driver_id", 599072142], ["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["name", "7b75ae09c644bca9b9e8ca6a0de5c64e"], ["updated_at", "2014-07-31 12:14:44.075855"], ["uuid", "7b75ae09c644bca9b9e8ca6a0de5c64e"]]
5844
+  (0.1ms) RELEASE SAVEPOINT active_record_1
5845
+ Redirected to
5846
+ Completed 500 Internal Server Error in 55ms
5847
+  (0.2ms) rollback transaction
5848
+  (0.1ms) begin transaction
5849
+ ----------------------------------------------------------
5850
+ Extface::DevicesControllerTest: test_should_destroy_device
5851
+ ----------------------------------------------------------
5852
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5853
+  (0.1ms) SELECT COUNT(*) FROM "extface_devices"
5854
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5855
+ Processing by Extface::DevicesController#destroy as HTML
5856
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5857
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5858
+ Extface::Device Load (0.2ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5859
+  (0.1ms) SAVEPOINT active_record_1
5860
+ SQL (0.2ms) DELETE FROM "extface_devices" WHERE "extface_devices"."id" = ? [["id", 980190962]]
5861
+  (0.1ms) RELEASE SAVEPOINT active_record_1
5862
+ Completed 500 Internal Server Error in 3ms
5863
+  (0.1ms) rollback transaction
5864
+  (0.1ms) begin transaction
5865
+ ----------------------------------------------------
5866
+ Extface::DevicesControllerTest: test_should_get_edit
5867
+ ----------------------------------------------------
5868
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5869
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5870
+ Processing by Extface::DevicesController#edit as HTML
5871
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5872
+ Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5873
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5874
+ Completed 500 Internal Server Error in 30ms
5875
+  (0.1ms) rollback transaction
5876
+  (0.1ms) begin transaction
5877
+ -----------------------------------------------------
5878
+ Extface::DevicesControllerTest: test_should_get_index
5879
+ -----------------------------------------------------
5880
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5881
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5882
+ Processing by Extface::DevicesController#index as HTML
5883
+ Parameters: {"shop_id"=>"980190962"}
5884
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5885
+ Extface::Device Load (0.2ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"]]
5886
+ Completed 500 Internal Server Error in 5ms
5887
+  (0.1ms) rollback transaction
5888
+  (0.1ms) begin transaction
5889
+ ---------------------------------------------------
5890
+ Extface::DevicesControllerTest: test_should_get_new
5891
+ ---------------------------------------------------
5892
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5893
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5894
+ Processing by Extface::DevicesController#new as HTML
5895
+ Parameters: {"shop_id"=>"980190962"}
5896
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5897
+ Completed 500 Internal Server Error in 3ms
5898
+  (0.1ms) rollback transaction
5899
+  (0.1ms) begin transaction
5900
+ -------------------------------------------------------
5901
+ Extface::DevicesControllerTest: test_should_show_device
5902
+ -------------------------------------------------------
5903
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5904
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5905
+ Processing by Extface::DevicesController#show as HTML
5906
+ Parameters: {"shop_id"=>"980190962", "id"=>"980190962"}
5907
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5908
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5909
+ Completed 500 Internal Server Error in 5ms
5910
+  (0.1ms) rollback transaction
5911
+  (0.1ms) begin transaction
5912
+ ---------------------------------------------------------
5913
+ Extface::DevicesControllerTest: test_should_update_device
5914
+ ---------------------------------------------------------
5915
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."id" = ? LIMIT 1 [["id", 980190962]]
5916
+ Shop Load (0.0ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = ? LIMIT 1 [["id", 980190962]]
5917
+ Processing by Extface::DevicesController#update as HTML
5918
+ Parameters: {"shop_id"=>"980190962", "device"=>{"name"=>"new_name"}, "id"=>"980190962"}
5919
+ Shop Load (0.1ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 980190962 LIMIT 1
5920
+ Extface::Device Load (0.1ms) SELECT "extface_devices".* FROM "extface_devices" WHERE "extface_devices"."extfaceable_id" = ? AND "extface_devices"."extfaceable_type" = ? AND "extface_devices"."id" = ? LIMIT 1 [["extfaceable_id", 980190962], ["extfaceable_type", "Shop"], ["id", 980190962]]
5921
+  (0.1ms) SAVEPOINT active_record_1
5922
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."name" = 'new_name' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5923
+ Extface::Device Exists (0.1ms) SELECT 1 AS one FROM "extface_devices" WHERE ("extface_devices"."uuid" = 'MyUUID1' AND "extface_devices"."id" != 980190962 AND "extface_devices"."extfaceable_id" = 980190962 AND "extface_devices"."extfaceable_type" = 'Shop') LIMIT 1
5924
+ SQL (0.2ms) UPDATE "extface_devices" SET "name" = ?, "updated_at" = ? WHERE "extface_devices"."id" = 980190962 [["name", "new_name"], ["updated_at", "2014-07-31 12:14:44.155806"]]
5925
+  (0.1ms) RELEASE SAVEPOINT active_record_1
5926
+ Redirected to
5927
+ Completed 500 Internal Server Error in 6ms
5928
+  (0.2ms) rollback transaction
data/test/test_helper.rb CHANGED
@@ -23,7 +23,7 @@ end
23
23
  module Extface
24
24
  class ActionController::TestCase
25
25
  setup do
26
- @routes = Engine.routes
26
+ @routes = Extface::Engine.routes
27
27
  end
28
28
  end
29
29
  end
metadata CHANGED
@@ -1,69 +1,69 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: extface
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.3.0a
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alex Vangelov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-15 00:00:00.000000000 Z
11
+ date: 2014-07-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: 4.0.5
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: 4.0.5
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: redis
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '0'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: redis-namespace
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '0'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '>='
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: sqlite3
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - '>='
59
+ - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - '>='
66
+ - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  description: Extface allows use of Cash Registers, Fiscal and POS printers without
@@ -81,6 +81,7 @@ files:
81
81
  - Rakefile
82
82
  - app/assets/javascripts/extface/application.js
83
83
  - app/assets/javascripts/extface/devices.js
84
+ - app/assets/javascripts/extface/extface_fiscal_monitor.js
84
85
  - app/assets/javascripts/extface/jobs.js
85
86
  - app/assets/stylesheets/extface/application.css
86
87
  - app/assets/stylesheets/extface/devices.css
@@ -225,14 +226,14 @@ require_paths:
225
226
  - lib
226
227
  required_ruby_version: !ruby/object:Gem::Requirement
227
228
  requirements:
228
- - - '>='
229
+ - - ">="
229
230
  - !ruby/object:Gem::Version
230
231
  version: '0'
231
232
  required_rubygems_version: !ruby/object:Gem::Requirement
232
233
  requirements:
233
- - - '>='
234
+ - - ">"
234
235
  - !ruby/object:Gem::Version
235
- version: '0'
236
+ version: 1.3.1
236
237
  requirements: []
237
238
  rubyforge_project:
238
239
  rubygems_version: 2.2.2