From 2e88f194bcbf1614c1b3c0bf79fcc0765a9bf79e Mon Sep 17 00:00:00 2001 From: Urban Rotnik Date: Tue, 17 Dec 2019 14:21:05 +0100 Subject: [PATCH] Fix tests --- .../javascripts/repositories/renderers/new_renderers.js | 2 +- spec/models/repository_date_range_value_spec.rb | 6 +++--- spec/models/repository_date_time_range_value_base_spec.rb | 2 +- spec/models/repository_date_time_range_value_spec.rb | 6 +++--- spec/models/repository_time_range_value_spec.rb | 6 +++--- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/app/assets/javascripts/repositories/renderers/new_renderers.js b/app/assets/javascripts/repositories/renderers/new_renderers.js index b4c430d29..21c4e41c3 100644 --- a/app/assets/javascripts/repositories/renderers/new_renderers.js +++ b/app/assets/javascripts/repositories/renderers/new_renderers.js @@ -1,4 +1,4 @@ -/* global ListColumnHelper ChecklistColumnHelper Status SmartAnnotation I18n GLOBAL_CONSTANTS DateTimeHelper formatJS */ +/* global ListColumnHelper ChecklistColumnHelper Status SmartAnnotation I18n GLOBAL_CONSTANTS DateTimeHelper */ $.fn.dataTable.render.newRowName = function(formId, $cell) { $cell.html(` diff --git a/spec/models/repository_date_range_value_spec.rb b/spec/models/repository_date_range_value_spec.rb index 4f4bdc00e..16eeff295 100644 --- a/spec/models/repository_date_range_value_spec.rb +++ b/spec/models/repository_date_range_value_spec.rb @@ -20,7 +20,7 @@ describe RepositoryDateRangeValue, type: :model do { start_time: Time.utc(2000, 10, 10).to_s, end_time: Time.utc(2000, 10, 12).to_s - } + }.to_json end it do @@ -33,7 +33,7 @@ describe RepositoryDateRangeValue, type: :model do { start_time: Time.utc(2000, 10, 10).to_s, end_time: Time.utc(2000, 10, 11, 4, 11).to_s - } + }.to_json end it do @@ -57,7 +57,7 @@ describe RepositoryDateRangeValue, type: :model do { start_time: Time.now.utc.to_s, end_time: (Time.now.utc + 1.day).to_s - } + }.to_json end it do diff --git a/spec/models/repository_date_time_range_value_base_spec.rb b/spec/models/repository_date_time_range_value_base_spec.rb index e79886229..7ffdf78ab 100644 --- a/spec/models/repository_date_time_range_value_base_spec.rb +++ b/spec/models/repository_date_time_range_value_base_spec.rb @@ -35,7 +35,7 @@ describe RepositoryDateTimeRangeValueBase, type: :model do { start_time: Time.now.utc.to_s, end_time: (Time.zone.now + 2.days).utc.to_s - } + }.to_json end context 'when update data' do diff --git a/spec/models/repository_date_time_range_value_spec.rb b/spec/models/repository_date_time_range_value_spec.rb index 1ba1059fb..059d0dc7d 100644 --- a/spec/models/repository_date_time_range_value_spec.rb +++ b/spec/models/repository_date_time_range_value_spec.rb @@ -20,7 +20,7 @@ describe RepositoryDateTimeRangeValue, type: :model do { start_time: Time.utc(2000, 10, 10).to_s, end_time: Time.utc(2000, 10, 12).to_s - } + }.to_json end it do @@ -33,7 +33,7 @@ describe RepositoryDateTimeRangeValue, type: :model do { start_time: Time.utc(2000, 10, 10).to_s, end_time: Time.utc(2000, 10, 11).to_s - } + }.to_json end it do @@ -57,7 +57,7 @@ describe RepositoryDateTimeRangeValue, type: :model do { start_time: Time.now.utc.to_s, end_time: (Time.now.utc + 1.day).to_s - } + }.to_json end it do diff --git a/spec/models/repository_time_range_value_spec.rb b/spec/models/repository_time_range_value_spec.rb index 83ad8736c..6007fd85e 100644 --- a/spec/models/repository_time_range_value_spec.rb +++ b/spec/models/repository_time_range_value_spec.rb @@ -20,7 +20,7 @@ describe RepositoryTimeRangeValue, type: :model do { start_time: Time.utc(2000, 10, 10, 12, 13).to_s, end_time: Time.utc(2000, 10, 12, 4, 11).to_s - } + }.to_json end it do @@ -33,7 +33,7 @@ describe RepositoryTimeRangeValue, type: :model do { start_time: Time.utc(2000, 10, 10).to_s, end_time: Time.utc(2012, 10, 14, 4, 11).to_s - } + }.to_json end it do @@ -57,7 +57,7 @@ describe RepositoryTimeRangeValue, type: :model do { start_time: Time.now.utc.to_s, end_time: (Time.now.utc + 1.day).to_s - } + }.to_json end it do