From a74b7d90a84758e623c2eb8cca95175377a61523 Mon Sep 17 00:00:00 2001 From: Shinya Maeda Date: Mon, 17 Apr 2017 19:59:55 +0800 Subject: Add feature test with unicode trace Squashed commit of the following: commit 43e5bba774e9e383dd55c665e82f6fcfc4ebfc4f Author: Shinya Maeda Date: Mon Apr 17 17:28:44 2017 +0900 Add fix commit 09610eebdf22ad048812bb86022504b2ad917e19 Author: Shinya Maeda Date: Mon Apr 17 17:03:49 2017 +0900 Add trace test --- spec/factories/ci/builds.rb | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'spec/factories') diff --git a/spec/factories/ci/builds.rb b/spec/factories/ci/builds.rb index 78ddd8d5584..f5e99fdf00b 100644 --- a/spec/factories/ci/builds.rb +++ b/spec/factories/ci/builds.rb @@ -128,6 +128,16 @@ FactoryGirl.define do end end + trait :unicode_trace do + after(:create) do |build, evaluator| + trace = File.binread( + File.expand_path( + Rails.root.join('spec/fixtures/trace/ansi-sequence-and-unicode'))) + + build.trace.set(trace) + end + end + trait :erased do erased_at Time.now erased_by factory: :user -- cgit v1.2.3