Skip to content

Commit 09ee839

Browse files
authored
Merge pull request #101 from launchdarkly/hr/azure2
add pipeline and clean up with with rm_rf instead of rm
2 parents d4081a9 + 9b4d75b commit 09ee839

File tree

2 files changed

+19
-5
lines changed

2 files changed

+19
-5
lines changed

azure-pipelines.yml

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
jobs:
2+
- job: build
3+
pool:
4+
vmImage: 'vs2017-win2016'
5+
steps:
6+
- task: PowerShell@2
7+
inputs:
8+
targetType: inline
9+
script: |
10+
ruby -v
11+
gem install bundler -v 1.17.3
12+
bundle install
13+
mkdir rspec
14+
bundle exec rspec --exclude-pattern "spec/integrations/*,spec/redis_*" --format progress --format RspecJunitFormatter -o ./rspec/rspec.xml spec

spec/file_data_source_spec.rb

+5-5
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
segments:
7575
seg1:
7676
key: seg1
77-
include: ["user1"]
77+
include: ["user1"]
7878
EOF
7979
}
8080

@@ -87,7 +87,7 @@
8787
end
8888

8989
after do
90-
FileUtils.remove_dir(@tmp_dir)
90+
FileUtils.rm_rf(@tmp_dir)
9191
end
9292

9393
def make_temp_file(content)
@@ -198,10 +198,10 @@ def test_auto_reload(options)
198198
event = ds.start
199199
expect(event.set?).to eq(true)
200200
expect(@store.all(LaunchDarkly::SEGMENTS).keys).to eq([])
201-
201+
202202
sleep(1)
203203
IO.write(file, all_properties_json)
204-
204+
205205
max_time = 10
206206
ok = wait_for_condition(10) { @store.all(LaunchDarkly::SEGMENTS).keys == all_segment_keys }
207207
expect(ok).to eq(true), "Waited #{max_time}s after modifying file and it did not reload"
@@ -243,7 +243,7 @@ def test_auto_reload(options)
243243
client.close
244244
end
245245
end
246-
246+
247247
def wait_for_condition(max_time)
248248
deadline = Time.now + max_time
249249
while Time.now < deadline

0 commit comments

Comments
 (0)