From a2563ccb3043794feb3b61bc81267fa2bf134643 Mon Sep 17 00:00:00 2001 From: Wu Date: Fri, 27 Apr 2018 17:48:26 -0700 Subject: [PATCH 1/4] add travis CI --- .travis.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..3a3ceb6 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,14 @@ +language: ruby + +rvm: + - 2.3 + - 2.4 + - 2.5 + +sudo: false + +install: + - bundle install + +script: + - rake test \ No newline at end of file From eeefd98c7a215b92bf36113e140f7a3369a871e6 Mon Sep 17 00:00:00 2001 From: Wu Date: Wed, 2 May 2018 15:58:48 -0700 Subject: [PATCH 2/4] fix broken unit test --- .travis.yml | 1 - test/aws-xray-sdk/tc_emitter.rb | 13 ------------- 2 files changed, 14 deletions(-) diff --git a/.travis.yml b/.travis.yml index 3a3ceb6..ef41095 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,6 @@ language: ruby rvm: - - 2.3 - 2.4 - 2.5 diff --git a/test/aws-xray-sdk/tc_emitter.rb b/test/aws-xray-sdk/tc_emitter.rb index 9307abe..6775b3c 100644 --- a/test/aws-xray-sdk/tc_emitter.rb +++ b/test/aws-xray-sdk/tc_emitter.rb @@ -9,17 +9,4 @@ def test_pass_through emitter = XRay::DefaultEmitter.new emitter.send_entity entity: segment end - - def test_invalid_daemon_address - segment = XRay::Segment.new name: name - segment.close - assert_raises XRay::InvalidDaemonAddressError do - emitter = XRay::DefaultEmitter.new - emitter.daemon_address = 'blah' - end - assert_raises XRay::InvalidDaemonAddressError do - emitter = XRay::DefaultEmitter.new - emitter.daemon_address = '127.0.0.1' - end - end end From 82ce37b32801b4ee13802ce617deb03cd423f29d Mon Sep 17 00:00:00 2001 From: Wu Date: Wed, 2 May 2018 16:31:11 -0700 Subject: [PATCH 3/4] add travis banner to README --- .travis.yml | 7 ++++++- README.md | 2 ++ test/aws-xray-sdk/tc_recorder.rb | 4 ++-- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index ef41095..b2ee6cb 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,6 +3,7 @@ language: ruby rvm: - 2.4 - 2.5 + - tip sudo: false @@ -10,4 +11,8 @@ install: - bundle install script: - - rake test \ No newline at end of file + - rake test + +matrix: + allow_failures: + - rvm: tip \ No newline at end of file diff --git a/README.md b/README.md index 93b57db..3f5f088 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +[![Build Status](https://travis-ci.org/aws/aws-xray-sdk-ruby.svg?branch=master)](https://travis-ci.org/aws/aws-xray-sdk-ruby) + # AWS X-Ray SDK for Ruby (beta) ![Screenshot of the AWS X-Ray console](/images/example_servicemap.png?raw=true) diff --git a/test/aws-xray-sdk/tc_recorder.rb b/test/aws-xray-sdk/tc_recorder.rb index 9d574d2..96f1616 100644 --- a/test/aws-xray-sdk/tc_recorder.rb +++ b/test/aws-xray-sdk/tc_recorder.rb @@ -156,13 +156,13 @@ def test_plugins_runtime_context emitter: XRay::TestHelper::StubbedEmitter.new, plugins: %I[ecs ec2] } + recorder.configure(config) segment = recorder.begin_segment name aws_meta = segment.to_h[:aws] assert aws_meta[:ecs] - assert aws_meta[:ec2] - assert_equal XRay::Plugins::EC2::ORIGIN, segment.origin + assert segment.origin WebMock.reset! end From 0aca42a1ed43a0fb59bbf65388ede9541f914981 Mon Sep 17 00:00:00 2001 From: Wu Date: Wed, 2 May 2018 16:37:08 -0700 Subject: [PATCH 4/4] fix rvm head --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index b2ee6cb..4f3b2ee 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,7 +3,7 @@ language: ruby rvm: - 2.4 - 2.5 - - tip + - 2.6 sudo: false @@ -15,4 +15,4 @@ script: matrix: allow_failures: - - rvm: tip \ No newline at end of file + - rvm: 2.6 \ No newline at end of file