Skip to content

Commit

Permalink
Update dependencies.
Browse files Browse the repository at this point in the history
  • Loading branch information
ioquatix committed Jan 9, 2020
1 parent 335cc97 commit 0103455
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 36 deletions.
6 changes: 0 additions & 6 deletions .travis.yml
@@ -1,10 +1,6 @@
language: ruby
cache: bundler

before_script:
- gem update --system
- gem install bundler

addons:
apt:
packages:
Expand All @@ -19,8 +15,6 @@ matrix:
- rvm: jruby-head
env: JRUBY_OPTS="--debug -X+O"
- rvm: ruby-head
- rvm: rbx-3
allow_failures:
- rvm: ruby-head
- rvm: jruby-head
- rvm: rbx-3
4 changes: 2 additions & 2 deletions Rakefile
@@ -1,6 +1,6 @@
require "bundler/gem_tasks"
require "rspec/core/rake_task"

RSpec::Core::RakeTask.new(:test)
RSpec::Core::RakeTask.new

task :default => :test
task :default => :spec
18 changes: 8 additions & 10 deletions examples/basic-dns.rb
Expand Up @@ -2,22 +2,20 @@
require 'rubydns'

INTERFACES = [
[:udp, "0.0.0.0", 5300],
[:tcp, "0.0.0.0", 5300],
[:udp, "127.0.0.2", 53],
[:tcp, "127.0.0.2", 53],
]

IN = Resolv::DNS::Resource::IN

# Use upstream DNS for name resolution.
UPSTREAM = RubyDNS::Resolver.new([[:udp, "8.8.8.8", 53], [:tcp, "8.8.8.8", 53]])
UPSTREAM = RubyDNS::Resolver.new([
[:udp, "8.8.8.8", 53],
[:tcp, "8.8.8.8", 53]
])

# Start the RubyDNS server
RubyDNS::run_server(INTERFACES) do
match(%r{test.local}, IN::A) do |transaction|
transaction.respond!("10.0.0.80")
end

# Default DNS handler
@logger.debug!

otherwise do |transaction|
transaction.passthrough!(UPSTREAM)
end
Expand Down
3 changes: 2 additions & 1 deletion rubydns.gemspec
Expand Up @@ -22,7 +22,8 @@ Gem::Specification.new do |spec|
spec.add_dependency("async-dns", "~> 1.0")
spec.add_development_dependency("async-rspec", "~> 1.0")

spec.add_development_dependency "bundler", "~> 1.3"
spec.add_development_dependency "covered"
spec.add_development_dependency "bundler"
spec.add_development_dependency "rspec", "~> 3.4"
spec.add_development_dependency "rake"
end
18 changes: 1 addition & 17 deletions spec/spec_helper.rb
@@ -1,21 +1,5 @@

if ENV['COVERAGE'] || ENV['TRAVIS']
begin
require 'simplecov'

SimpleCov.start do
add_filter "/spec/"
end

if ENV['TRAVIS']
require 'coveralls'
Coveralls.wear!
end
rescue LoadError
warn "Could not load simplecov: #{$!}"
end
end

require 'covered/rspec'
require "bundler/setup"
require "async"
require "async/rspec"
Expand Down

0 comments on commit 0103455

Please sign in to comment.