repo
stringlengths
5
92
file_url
stringlengths
80
287
file_path
stringlengths
5
197
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:37:27
2026-01-04 17:58:21
truncated
bool
2 classes
piotrmurach/strings
https://github.com/piotrmurach/strings/blob/30854c1544d0ae020e2c00ef3b33f0240f47a921/lib/strings/version.rb
lib/strings/version.rb
# frozen_string_literal: true module Strings VERSION = "0.2.1" end # Strings
ruby
MIT
30854c1544d0ae020e2c00ef3b33f0240f47a921
2026-01-04T17:48:15.474368Z
false
piotrmurach/strings
https://github.com/piotrmurach/strings/blob/30854c1544d0ae020e2c00ef3b33f0240f47a921/lib/strings/extensions.rb
lib/strings/extensions.rb
# frozen_string_literal: true require_relative "../strings" module Strings module Extensions refine String do def align(*args, **kws) Align.align(self, *args, **kws) end def align_left(*args, **kws) Align.align_left(self, *args, **kws) end def align_center(*args, ...
ruby
MIT
30854c1544d0ae020e2c00ef3b33f0240f47a921
2026-01-04T17:48:15.474368Z
false
piotrmurach/strings
https://github.com/piotrmurach/strings/blob/30854c1544d0ae020e2c00ef3b33f0240f47a921/lib/strings/truncate.rb
lib/strings/truncate.rb
# frozen_string_literal: true require "strings-ansi" require "unicode/display_width" require "unicode_utils/each_grapheme" module Strings # A module responsible for text truncation module Truncate DEFAULT_TRAILING = "…".freeze DEFAULT_LENGTH = 30 # Truncate a text at a given length (defualts to 30) ...
ruby
MIT
30854c1544d0ae020e2c00ef3b33f0240f47a921
2026-01-04T17:48:15.474368Z
false
piotrmurach/strings
https://github.com/piotrmurach/strings/blob/30854c1544d0ae020e2c00ef3b33f0240f47a921/lib/strings/fold.rb
lib/strings/fold.rb
# frozen_string_literal: true module Strings module Fold LINE_BREAK = "(\r\n+|\r+|\n+|\t+)".freeze # Fold a multiline text into a single line string # # @example # fold("\tfoo \r\n\n bar") # => " foo bar" # # @param [String] text # # @param [String] separator # the separ...
ruby
MIT
30854c1544d0ae020e2c00ef3b33f0240f47a921
2026-01-04T17:48:15.474368Z
false
piotrmurach/strings
https://github.com/piotrmurach/strings/blob/30854c1544d0ae020e2c00ef3b33f0240f47a921/lib/strings/wrap.rb
lib/strings/wrap.rb
# frozen_string_literal: true require "strings-ansi" require "unicode/display_width" require "unicode_utils/each_grapheme" module Strings module Wrap DEFAULT_WIDTH = 80 NEWLINE = "\n" SPACE = " " LINE_BREAK = %r{\r\n|\r|\n}.freeze LINE_BREAKS = "\r\n+|\r+|\n+" # Wrap a text into lines no lo...
ruby
MIT
30854c1544d0ae020e2c00ef3b33f0240f47a921
2026-01-04T17:48:15.474368Z
false
piotrmurach/strings
https://github.com/piotrmurach/strings/blob/30854c1544d0ae020e2c00ef3b33f0240f47a921/lib/strings/padder.rb
lib/strings/padder.rb
# frozen_string_literal: true module Strings # A class responsible for parsing padding value # # Used internally by {Strings::Pad} # # @api private class Padder ParseError = Class.new(ArgumentError) # Parse padding options # # Turn possible values into 4 element array # # @example ...
ruby
MIT
30854c1544d0ae020e2c00ef3b33f0240f47a921
2026-01-04T17:48:15.474368Z
false
piotrmurach/strings
https://github.com/piotrmurach/strings/blob/30854c1544d0ae020e2c00ef3b33f0240f47a921/lib/strings/pad.rb
lib/strings/pad.rb
# frozen_string_literal: true require "strings-ansi" require "unicode/display_width" require_relative "padder" module Strings # Responsible for text padding module Pad NEWLINE = "\n" SPACE = " " LINE_BREAK = %r{\r\n|\r|\n}.freeze # Apply padding to multiline text with ANSI codes # # @par...
ruby
MIT
30854c1544d0ae020e2c00ef3b33f0240f47a921
2026-01-04T17:48:15.474368Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/mvm.rb
tools/jruby-1.5.1/samples/mvm.rb
require 'jruby/vm' # create the VMs vm1 = JRuby::VM.spawn(['-e' "load 'samples/mvm_subvm.rb'"]) vm2 = JRuby::VM.spawn(['-e' "load 'samples/mvm_subvm.rb'"]) # connect them to parent vm1 << JRuby::VM_ID vm2 << JRuby::VM_ID # connect them together vm1 << vm2.id vm2 << vm1.id # start them running vm1 << 1 # let them r...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/thread.rb
tools/jruby-1.5.1/samples/thread.rb
x = Thread.new { sleep 0.1; print "x"; print "y"; print "z" } a = Thread.new { print "a"; print "b"; sleep 0.2; print "c" } x.join # Let the threads finish before a.join # main thread exits... puts # newline
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/xslt.rb
tools/jruby-1.5.1/samples/xslt.rb
include Java require 'optparse' require 'ostruct' import java.io.FileOutputStream import javax.xml.transform.stream.StreamSource import javax.xml.transform.TransformerFactory class XSLTOptions def self.parse(args) options = OpenStruct.new options.parameters = {} opts = OptionParser.new do |opts|...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/java2.rb
tools/jruby-1.5.1/samples/java2.rb
require "java" filename = __FILE__ fr = java.io.FileReader.new filename br = java.io.BufferedReader.new fr s = br.readLine print "------ ", filename, "------\n" while s puts s.to_s s = br.readLine end print "------ ", filename, " end ------\n"; br.close
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/swing2.rb
tools/jruby-1.5.1/samples/swing2.rb
# Import Java packages include Java import javax.swing.JFrame frame = JFrame.new("Hello Swing") button = javax.swing.JButton.new("Klick Me!") button.add_action_listener do |evt| javax.swing.JOptionPane.showMessageDialog(nil, <<EOS) <html>Hello from <b><u>JRuby</u></b>.<br> Button '#{evt.getActionCommand()}' clicked...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/mvm_subvm.rb
tools/jruby-1.5.1/samples/mvm_subvm.rb
require 'jruby/vm' VM = JRuby::VM ID = JRuby::VM_ID # get the VM id of the parent parent = VM.get_message # get the VM id we're sending to other = VM.get_message VM.send_message(parent, "VM #{ID} starting up, sibling is: #{other}, parent is: #{parent}") # loop until we receive nil, adding one and sending on whil...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/error.rb
tools/jruby-1.5.1/samples/error.rb
require 'java' Java::define_exception_handler "java.lang.NumberFormatException" do |e| puts e.java_type p e.methods puts e.java_class.java_method(:getMessage).invoke(e) end java.lang.Long.parseLong("23aa")
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/jrubyc_java/simple_class.rb
tools/jruby-1.5.1/samples/jrubyc_java/simple_class.rb
require 'java' class SimpleRubyClass java_signature "void simple_method()" def simple_method puts "here!" end end =begin ~/projects/jruby/jrubyc_stuff ➔ jrubyc --java simple_class.rb Compiling simple_class.rb to class simple_class Generating Java class SimpleRubyClass to SimpleRubyClass.java javac -cp /Use...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/jrubyc_java/overloads.rb
tools/jruby-1.5.1/samples/jrubyc_java/overloads.rb
require 'java' class OverloadedClass java_signature "void run(String)" def run1(a); end java_signature "void run(int)" def run2(a); end end =begin ~/projects/jruby/samples/jrubyc_java ➔ jrubyc --java overloads.rb Compiling overloads.rb to class overloads Generating Java class OverloadedClass to Overloaded...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/jrubyc_java/my_runnable.rb
tools/jruby-1.5.1/samples/jrubyc_java/my_runnable.rb
require 'java' class MyRunnable java_implements "java.lang.Runnable" java_signature "void run()" def run puts 'here' end java_signature "void main(String[])" def self.main(args) t = java.lang.Thread.new(MyRunnable.new) t.start end end =begin ~/projects/jruby/jrubyc_stuff ➔ jrubyc --java my...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/jrubyc_java/simple_class2.rb
tools/jruby-1.5.1/samples/jrubyc_java/simple_class2.rb
require 'java' class MyRubyClass java_signature 'void helloWorld()' def helloWorld puts "Hello from Ruby" end java_signature 'void goodbyeWorld(String)' def goodbyeWorld(a) puts a end end
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/jrubyc_java/simple_junit.rb
tools/jruby-1.5.1/samples/jrubyc_java/simple_junit.rb
require 'java' class TestSomething java_annotation "org.junit.Test" def test_jruby_rocks fail unless "JRuby rocks" == "JRuby" + " " + "rocks" end java_annotation "org.junit.Test" def test_jruby_will_never_support_annotations fail("JRuby does support annotations!") if "JRuby supports annotations" e...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/jrubyc_java/annotated.rb
tools/jruby-1.5.1/samples/jrubyc_java/annotated.rb
require 'java' java_import "java.lang.Deprecated" java_annotation :Deprecated class DeprecatedClass end =begin import org.jruby.Ruby; import org.jruby.RubyObject; import org.jruby.javasupport.util.RuntimeHelpers; import org.jruby.runtime.builtin.IRubyObject; import org.jruby.javasupport.JavaUtil; import org.jruby.Ru...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/ext/extconf.rb
tools/jruby-1.5.1/samples/ext/extconf.rb
# Loads mkmf which is used to make makefiles for Ruby extensions require 'mkmf' # Give it a name extension_name = 'mytest' # The destination dir_config(extension_name) # Do the work create_makefile(extension_name)
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/ffi/qsort.rb
tools/jruby-1.5.1/samples/ffi/qsort.rb
require 'ffi' module LibC extend FFI::Library ffi_lib FFI::Library::LIBC callback :qsort_cmp, [ :pointer, :pointer ], :int attach_function :qsort, [ :pointer, :int, :int, :qsort_cmp ], :int end p = FFI::MemoryPointer.new(:int, 2) p.put_array_of_int32(0, [ 2, 1 ]) puts "Before qsort #{p.get_array_of_int32(0, 2...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/ffi/ffi.rb
tools/jruby-1.5.1/samples/ffi/ffi.rb
require 'ffi' module POSIX extend FFI::Library # this line isn't really necessary since libc is always linked into JVM ffi_lib 'c' attach_function :getuid, :getuid, [], :uint attach_function :getpid, :getpid, [], :uint end puts "Process #{POSIX.getpid} running as user #{POSIX.getuid}"
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/ffi/pty.rb
tools/jruby-1.5.1/samples/ffi/pty.rb
require 'ffi' module PTY private module LibC extend FFI::Library # forkpty(3) is in libutil on linux, libc on MacOS/BSD if FFI::Platform.linux? ffi_lib 'libutil' else ffi_lib FFI::Library::LIBC end attach_function :forkpty, [ :buffer_out, :buffer_out, :buffer_in, :buffer_in ], ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/ffi/win32api.rb
tools/jruby-1.5.1/samples/ffi/win32api.rb
require 'ffi' module Win32 class API < Module CONVENTION = FFI::Platform.windows? ? :stdcall : :default SUFFIXES = $KCODE == 'UTF8' ? [ '', 'W', 'A' ] : [ '', 'A', 'W' ] TypeDefs = { 'V' => :void, 'S' => :string, 'P' => :pointer, 'I' => :int, 'L' => :long, } def se...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/samples/ffi/gettimeofday.rb
tools/jruby-1.5.1/samples/ffi/gettimeofday.rb
require 'rubygems' require 'ffi' class Timeval < FFI::Struct rb_maj, rb_min, rb_micro = RUBY_VERSION.split('.') if rb_maj.to_i >= 1 && rb_min.to_i >= 9 || RUBY_PLATFORM =~ /java/ layout :tv_sec => :ulong, :tv_usec => :ulong else layout :tv_sec, :ulong, 0, :tv_usec, :ulong, 4 end end module LibC exte...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/bin/prettify_json.rb
tools/jruby-1.5.1/bin/prettify_json.rb
#!/usr/bin/env jruby # # This file was generated by RubyGems. # # The application 'json_pure' is installed as part of a gem, and # this file is here to facilitate running it. # require 'rubygems' version = ">= 0" if ARGV.first =~ /^_(.*)_$/ and Gem::Version.correct? $1 then version = $1 ARGV.shift end gem 'json...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/bin/generate_yaml_index.rb
tools/jruby-1.5.1/bin/generate_yaml_index.rb
#!/usr/bin/env jruby # Generate the yaml/yaml.Z index files for a gem server directory. # # Usage: generate_yaml_index.rb --dir DIR [--verbose] $:.unshift '~/rubygems' if File.exist? "~/rubygems" require 'optparse' require 'rubygems' require 'zlib' Gem.manage_gems class Indexer def initialize(options) @opt...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/bin/edit_json.rb
tools/jruby-1.5.1/bin/edit_json.rb
#!/usr/bin/env jruby # # This file was generated by RubyGems. # # The application 'json_pure' is installed as part of a gem, and # this file is here to facilitate running it. # require 'rubygems' version = ">= 0" if ARGV.first =~ /^_(.*)_$/ and Gem::Version.correct? $1 then version = $1 ARGV.shift end gem 'json...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/setup.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/setup.rb
# # setup.rb # # Copyright (c) 2000-2005 Minero Aoki # # This program is free software. # You can distribute/modify this program under the terms of # the GNU LGPL, Lesser General Public License version 2.1. # unless Enumerable.method_defined?(:map) # Ruby 1.4.6 module Enumerable alias map collect end end un...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
true
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/functional_test.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/functional_test.rb
require File.dirname(__FILE__) + '/test_helper' =begin Updating functional testdata automatically is DANGEROUS, so I do manually. == update functional test cd ~/src/rcov/test rcov="ruby ../bin/rcov -I../lib:../ext/rcovrt -o expected_coverage" $rcov -a sample_04.rb $rcov sample_04.rb $rcov --gcc --include-file=sample...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/file_statistics_test.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/file_statistics_test.rb
require File.dirname(__FILE__) + '/test_helper' class TestFileStatistics < Test::Unit::TestCase def test_trailing_end_is_inferred verify_everything_marked "trailing end", <<-EOF 1 class X 1 def foo 2 "foo" 0 end 0 end EOF verify_everything_marked "trailing end with c...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/call_site_analyzer_test.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/call_site_analyzer_test.rb
require File.dirname(__FILE__) + '/test_helper' class TestCallSiteAnalyzer < Test::Unit::TestCase sample_file = File.join(File.dirname(__FILE__), "assets/sample_03.rb") load sample_file def setup @a = Rcov::CallSiteAnalyzer.new @o = Rcov::Test::Temporary::Sample03.new end def verify_callsites_equa...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/code_coverage_analyzer_test.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/code_coverage_analyzer_test.rb
require File.dirname(__FILE__) + '/test_helper' class TestCodeCoverageAnalyzer < Test::Unit::TestCase LINES = <<-EOF.split "\n" puts 1 if foo bar baz end 5.times do foo bar if baz end EOF def setup if defined? Rcov::Test::Temporary Rcov::Test::Temporary.constants.each do |name| Rcov::Tes...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/test_helper.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/test_helper.rb
require 'test/unit' require 'rcov' require 'pathname' require 'fileutils'
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/turn_off_rcovrt.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/turn_off_rcovrt.rb
# When loaded, this file forces rcov to run in pure-Ruby mode even if # rcovrt.so exists and can be loaded. $rcov_do_not_use_rcovrt = true
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/expected_coverage/sample_03_rb.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/expected_coverage/sample_03_rb.rb
#o module Rcov; module Test; module Temporary; class Sample03 #o def f1 # MUST NOT CHANGE the position or the tests will break # << [[sample_03_rb.rb:10 in Rcov::Test::Temporary::Sample03#f3]], [[sample_04_rb.r...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/expected_coverage/sample_04_rb.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/expected_coverage/sample_04_rb.rb
$: << File.dirname(__FILE__) #o require 'sample_03' #o #o klass = Rcov::Test::Temporary::Sample03 #o obj ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_03.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_03.rb
module Rcov; module Test; module Temporary; class Sample03 def f1 # MUST NOT CHANGE the position or the tests will break 10.times { f2 } end def f2; 1 end def f3 10.times{ f1 } 100.times{ f2 } end def self.g1 10.times{ g2 } end def self.g2; 1 end ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_01.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_01.rb
a = 1 if a == 2 b = 1 else b = 2 end 10.times{ b += 1 }
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_04.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_04.rb
$: << File.dirname(__FILE__) require 'sample_03' klass = Rcov::Test::Temporary::Sample03 obj = klass.new obj.f1 obj.f2 obj.f3 #klass.g1 uncovered klass.g2
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_05-new.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_05-new.rb
def d(x) 4*x end def a b 10 end def b(x) x*10 end def c(x) 3*x end a()
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_05-old.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_05-old.rb
def a b 10 end def b(x) x*10 end def c(x) 3*x end a()
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_05.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_05.rb
def d(x) 4*x end def a b 10 end def b(x) x*10 end def c(x) 3*x end a()
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_06.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_06.rb
x = 2 if x.nil? x = 4 elsif x == 2 x = x*x else x = x+4 end
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_02.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/test/assets/sample_02.rb
module Rcov; module Test; module Temporary; module Sample02 def self.foo(a,b) a + b end end end end end
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov.rb
# rcov Copyright (c) 2004-2006 Mauricio Fernandez <mfp@acm.org> # # See LICENSE for licensing information. # NOTE: if you're reading this in the XHTML code coverage report generated by # rcov, you'll notice that only code inside methods is reported as covered, # very much like what happens when you run it with --test-...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/file_statistics.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/file_statistics.rb
module Rcov # A FileStatistics object associates a filename to: # 1. its source code # 2. the per-line coverage information after correction using rcov's heuristics # 3. the per-line execution counts # # A FileStatistics object can be therefore be built given the filename, the # associated source code, an...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/rcovtask.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/rcovtask.rb
#!/usr/bin/env ruby # Define a task library for performing code coverage analysis of unit tests # using rcov. require 'rake' require 'rake/tasklib' module Rcov # Create a task that runs a set of tests through rcov, generating code # coverage reports. # # Example: # # require 'rcov/rcovtask' # # ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/version.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/version.rb
# rcov Copyright (c) 2004-2006 Mauricio Fernandez <mfp@acm.org> # # See LICENSE for licensing information. module Rcov VERSION = "0.9.8" RELEASE_DATE = "2010-02-28" RCOVRT_ABI = [2,0,0] UPSTREAM_URL = "http://github.com/relevance/rcov" end
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/call_site_analyzer.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/call_site_analyzer.rb
module Rcov # A CallSiteAnalyzer can be used to obtain information about: # * where a method is defined ("+defsite+") # * where a method was called from ("+callsite+") # # == Example # <tt>example.rb</tt>: # class X # def f1; f2 end # def f2; 1 + 1 end # def f3; f1 end # end # # an...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters.rb
require 'rcov/formatters/html_erb_template' require 'rcov/formatters/base_formatter' require 'rcov/formatters/text_summary' require 'rcov/formatters/text_report' require 'rcov/formatters/text_coverage_diff' require 'rcov/formatters/full_text_report' require 'rcov/formatters/html_coverage' require 'rcov/formatters/failu...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/differential_analyzer.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/differential_analyzer.rb
module Rcov class DifferentialAnalyzer require 'thread' @@mutex = Mutex.new def initialize(install_hook_meth, remove_hook_meth, reset_meth) @cache_state = :wait @start_raw_data = data_default @end_raw_data = data_default @aggregated_data = data_default @install_hook_meth = i...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/lowlevel.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/lowlevel.rb
# rcov Copyright (c) 2004-2006 Mauricio Fernandez <mfp@acm.org> # # See LEGAL and LICENSE for licensing information. require 'rcov/version' module Rcov # RCOV__ performs the low-level tracing of the execution, gathering code # coverage information in the process. The C core made available through the # rcovrt extens...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/code_coverage_analyzer.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/code_coverage_analyzer.rb
module Rcov # A CodeCoverageAnalyzer is responsible for tracing code execution and # returning code coverage and execution count information. # # Note that you must <tt>require 'rcov'</tt> before the code you want to # analyze is parsed (i.e. before it gets loaded or required). You can do that # by either i...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/coverage_info.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/coverage_info.rb
# Rcov::CoverageInfo is but a wrapper for an array, with some additional # checks. It is returned by FileStatistics#coverage. class CoverageInfo def initialize(coverage_array) @cover = coverage_array.clone end # Return the coverage status for the requested line. There are four possible # return values: #...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/text_summary.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/text_summary.rb
module Rcov class TextSummary < BaseFormatter # :nodoc: def execute puts summary end def summary "%.1f%% %d file(s) %d Lines %d LOC" % [code_coverage * 100, @files.size, num_lines, num_code_lines] end end end
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/html_coverage.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/html_coverage.rb
module Rcov class HTMLCoverage < BaseFormatter # :nodoc: require 'fileutils' DEFAULT_OPTS = {:color => false, :fsr => 30, :destdir => "coverage", :callsites => false, :cross_references => false, :charset => nil } def initialize(opts = {}) options = DEFAULT_O...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/failure_report.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/failure_report.rb
module Rcov class FailureReport < TextSummary # :nodoc: def execute puts summary coverage = code_coverage * 100 if coverage < @failure_threshold puts "You failed to satisfy the coverage theshold of #{@failure_threshold}%" exit(1) end if (coverage - @failure_threshold)...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/base_formatter.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/base_formatter.rb
module Rcov class BaseFormatter # :nodoc: require 'pathname' require 'rbconfig' RCOV_IGNORE_REGEXPS = [ /\A#{Regexp.escape(Pathname.new(::RbConfig::CONFIG['libdir']).cleanpath.to_s)}/, /\btc_[^.]*.rb/, /_test\.rb\z/, /\...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/text_report.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/text_report.rb
module Rcov class TextReport < TextSummary # :nodoc: def execute print_lines print_header print_lines each_file_pair_sorted do |fname, finfo| name = fname.size < 52 ? fname : "..." + fname[-48..-1] print_info(name, finfo.num_lines, finfo.num_code_lines, finfo.code_...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/text_coverage_diff.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/text_coverage_diff.rb
module Rcov class TextCoverageDiff < BaseFormatter # :nodoc: FORMAT_VERSION = [0, 1, 0] DEFAULT_OPTS = { :textmode => :coverage_diff, :coverage_diff_mode => :record, :coverage_diff_file => "coverage.info", :diff_cmd => "diff", :comments_run_by_default => true } H...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/full_text_report.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/full_text_report.rb
module Rcov class FullTextReport < BaseFormatter # :nodoc: DEFAULT_OPTS = {:textmode => :coverage} def initialize(opts = {}) options = DEFAULT_OPTS.clone.update(opts) @textmode = options[:textmode] @color = options[:color] super(options) end def execute each_file_pair_s...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/html_erb_template.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/rcov-0.9.8-java/lib/rcov/formatters/html_erb_template.rb
module Rcov module Formatters class HtmlErbTemplate attr_accessor :local_variables def initialize(template_file, locals={}) require "erb" template_path = File.expand_path("#{File.dirname(__FILE__)}/../templates/#{template_file}") @template = ERB.new(File.read(template_path)) ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_merb_spec.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_merb_spec.rb
require File.dirname(__FILE__) + '/spec_helper.rb' describe "binary executable with no command line arguments" do it "should set adapter to merb" do runner = mock("runner", :null_object => true) current_dir = Dir.pwd JettyRails::Runner.should_receive(:new) do |config| config.should have_key(:ada...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_rails_spec.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_rails_spec.rb
require File.dirname(__FILE__) + '/spec_helper.rb' describe "binary executable with no command line arguments" do it "should set adapter to rails" do runner = mock("runner", :null_object => true) current_dir = Dir.pwd JettyRails::Runner.should_receive(:new) do |config| config.should have_key(:ad...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/spec_helper.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/spec_helper.rb
begin require 'spec' rescue LoadError require 'rubygems' unless ENV['NO_RUBYGEMS'] gem 'rspec' require 'spec' end $:.unshift(File.dirname(__FILE__) + '/../lib') $:.unshift(File.dirname(__FILE__) + '/../jetty-libs') require 'jetty_rails' require 'yaml'
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_rails/config_file_spec.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_rails/config_file_spec.rb
require File.dirname(__FILE__) + '/../spec_helper' describe JettyRails::Runner, "with config file containing several servers and apps" do before do @yaml_config = YAML.load_file(File.join(File.dirname(__FILE__), '..', 'config.yml')) end it "should instantiate runner with config.yml and setup servers" do ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_rails/runner_spec.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_rails/runner_spec.rb
require File.dirname(__FILE__) + '/../spec_helper' describe JettyRails::Runner, "with no extra configuration (rails adapter)" do it "should require basedir to be run" do lambda { JettyRails::Runner.new }.should raise_error end it "should receive basedir configuration" do runner = JettyRails::Runner.n...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_rails/handler/delegate_on_errors_handler_spec.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/spec/jetty_rails/handler/delegate_on_errors_handler_spec.rb
require File.dirname(__FILE__) + '/../../spec_helper' describe JettyRails::Handler::DelegateOnErrorsHandler do it "should decorate the original HttpServletResponse" do original = mock("original handler", :null_object => true) original.should_receive(:handle).once do |target, request, response, dispatch| ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails.rb
jetty_libs_dir = "#{File.dirname(__FILE__)}/../jetty-libs" $:.unshift(File.expand_path(jetty_libs_dir)) unless $:.include?(jetty_libs_dir) || $:.include?(File.expand_path(jetty_libs_dir)) $:.unshift(File.dirname(__FILE__)) unless $:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FI...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/warbler_reader.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/warbler_reader.rb
class WarblerReader def initialize(config) # TODO ignore jruby and jruby-rack warbler_config = load("#{config[:base]}/config/warble.rb") warbler_config.java_libs.each do |jar| require jar end # TODO require custom classes end end
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/jars.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/jars.rb
module JettyRails require "servlet-api-2.5-6.1.14" require "jetty-6.1.14" require "jetty-util-6.1.14" require "jetty-plus-6.1.14" require "core-3.1.1" require "jsp-api-2.1" require "jsp-2.1" module Jetty include_package "org.mortbay.jetty" include_package "org.mortbay.jetty.servlet" inclu...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/runner.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/runner.rb
require "jruby" module JettyRails class Runner attr_reader :servers def initialize(config = {}) @servers = {} config.symbolize_keys! if config[:servers].nil? add_server(config) else config[:servers].each do |server_config| server_config.symbolize_key...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/server.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/server.rb
module JettyRails class Server attr_reader :config attr_reader :app_contexts attr_reader :server @@defaults = { :adapter => :rails, :environment => 'development', :context_path => '/', :lib_dir => 'lib', :classes_dir => 'classes', :web_xml => 'config/web.xml', ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/adapters/rails_adapter.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/adapters/rails_adapter.rb
module JettyRails module Adapters class RailsAdapter < AbstractAdapter def init_params # please refer to goldspike and jruby-rack documentation # in: PoolingRackApplicationFactory @rails_params ||= { 'rails.root' => '/', 'rails.env' => config[:e...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/adapters/merb_adapter.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/adapters/merb_adapter.rb
module JettyRails module Adapters class MerbAdapter < AbstractAdapter def init_params # please refer to goldspike and jruby-rack documentation @merb_params ||= { 'merb.root' => '/', 'merb.environment' => config[:environment] }.merge(base_init_params) ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/adapters/abstract_adapter.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/adapters/abstract_adapter.rb
module JettyRails module Adapters class AbstractAdapter attr_reader :config def initialize(config) @config = config end def base_init_params() @base_init_params ||= { 'public.root' => '/public', 'gem.path' => config[:gem_path] || ENV['GEM_...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/config/rdoc_fix.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/config/rdoc_fix.rb
require 'rdoc/usage' # fix to work with rubygems (use current file instead of main) def RDoc.usage_no_exit(*args) comment = File.open(File.join(File.dirname(__FILE__), %w(.. .. .. bin), File.basename($0))) do |file| find_comment(file) end comment = comment.gsub(/^\s*#/, '') markup = SM::SimpleMarkup.new ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/config/command_line_reader.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/config/command_line_reader.rb
require 'getoptlong' require 'jetty_rails/config/rdoc_fix' class CommandLineReader def default_config() @@config ||= { :rails => { :base => Dir.pwd, :port => 3000, :ssl_port => 3443, :config_file => "#{File.join(Dir.pwd, 'config', 'jetty_rails.yml')}", :adapter =>...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/handler/web_app_handler.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/handler/web_app_handler.rb
module JettyRails module Handler class WebAppHandler < Jetty::Handler::WebAppContext attr_reader :config, :adapter def initialize(config) super("/", config[:context_path]) @config = config self.class_loader = each_context_has_its_own_classloader self.resource_ba...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/handler/delegate_on_errors_handler.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/handler/delegate_on_errors_handler.rb
module JettyRails module Handler class DelegateOnErrorsResponse include Java::JavaxServletHttp::HttpServletResponse def initialize(original, request) @original = original @request = request end def sendError(status_code) @request.handled = false ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/handler/public_directory_handler.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/jetty-rails-0.8.1/lib/jetty_rails/handler/public_directory_handler.rb
module JettyRails module Handler class PublicDirectoryHandler < JettyRails::Handler::DelegateOnErrorsHandler def initialize(config) super() @config = config @resources = Jetty::Handler::ResourceHandler.new @resources.resource_base = @config[:base] + '/public' cont...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/install.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/install.rb
#!/usr/bin/env ruby require 'rbconfig' require 'fileutils' include FileUtils::Verbose include Config bindir = CONFIG["bindir"] cd 'bin' do filename = 'edit_json.rb' #install(filename, bindir) end sitelibdir = CONFIG["sitelibdir"] cd 'lib' do install('json.rb', sitelibdir) mkdir_p File.join(sitelibdir, 'json'...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/benchmarks/parser2_benchmark.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/benchmarks/parser2_benchmark.rb
#!/usr/bin/env ruby # CODING: UTF-8 require 'rbconfig' RUBY_PATH=File.join(Config::CONFIG['bindir'], Config::CONFIG['ruby_install_name']) RAKE_PATH=File.join(Config::CONFIG['bindir'], 'rake') require 'bullshit' case ARGV.first when 'ext' require 'json/ext' when 'pure' require 'json/pure' when 'yaml' require 'yam...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/benchmarks/parser_benchmark.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/benchmarks/parser_benchmark.rb
#!/usr/bin/env ruby # CODING: UTF-8 require 'rbconfig' RUBY_PATH=File.join(Config::CONFIG['bindir'], Config::CONFIG['ruby_install_name']) RAKE_PATH=File.join(Config::CONFIG['bindir'], 'rake') require 'bullshit' case ARGV.first when 'ext' require 'json/ext' when 'pure' require 'json/pure' when 'yaml' require 'yam...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/benchmarks/generator2_benchmark.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/benchmarks/generator2_benchmark.rb
#!/usr/bin/env ruby # CODING: UTF-8 require 'rbconfig' RUBY_PATH=File.join(Config::CONFIG['bindir'], Config::CONFIG['ruby_install_name']) RAKE_PATH=File.join(Config::CONFIG['bindir'], 'rake') require 'bullshit' case ARGV.first when 'ext' require 'json/ext' when 'pure' require 'json/pure' when 'rails' require 'ac...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/benchmarks/generator_benchmark.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/benchmarks/generator_benchmark.rb
#!/usr/bin/env ruby # CODING: UTF-8 require 'rbconfig' RUBY_PATH=File.join(Config::CONFIG['bindir'], Config::CONFIG['ruby_install_name']) RAKE_PATH=File.join(Config::CONFIG['bindir'], 'rake') require 'bullshit' case ARGV.first when 'ext' require 'json/ext' when 'pure' require 'json/pure' when 'rails' require 'ac...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tools/fuzz.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tools/fuzz.rb
require 'json' require 'iconv' ISO_8859_1_TO_UTF8 = Iconv.new('utf-8', 'iso-8859-15') class ::String def to_utf8 ISO_8859_1_TO_UTF8.iconv self end end class Fuzzer def initialize(n, freqs = {}) sum = freqs.inject(0.0) { |s, x| s + x.last } freqs.each_key { |x| freqs[x] /= sum } s = 0.0 freqs...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tools/server.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tools/server.rb
#!/usr/bin/env ruby require 'webrick' include WEBrick $:.unshift 'ext' $:.unshift 'lib' require 'json' class JSONServlet < HTTPServlet::AbstractServlet @@count = 1 def do_GET(req, res) obj = { "TIME" => Time.now.strftime("%FT%T"), "foo" => "Bär", "bar" => "© ≠ €!", 'a' => 2, 'b'...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_generate.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_generate.rb
#!/usr/bin/env ruby # -*- coding: utf-8 -*- require 'test/unit' case ENV['JSON'] when 'pure' then require 'json/pure' when 'ext' then require 'json/ext' else require 'json' end class TC_JSONGenerate < Test::Unit::TestCase include JSON def setup @hash = { 'a' => 2, 'b' => 3.141, ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_encoding.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_encoding.rb
#!/usr/bin/env ruby # -*- coding: utf-8 -*- require 'test/unit' case ENV['JSON'] when 'pure' then require 'json/pure' when 'ext' then require 'json/ext' else require 'json' end require 'iconv' class TC_JSONEncoding < Test::Unit::TestCase include JSON def setup @utf_8 = '["© ≠ €!"]' @parsed =...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_unicode.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_unicode.rb
#!/usr/bin/env ruby # -*- coding: utf-8 -*- require 'test/unit' case ENV['JSON'] when 'pure' then require 'json/pure' when 'ext' then require 'json/ext' else require 'json' end class TC_JSONUnicode < Test::Unit::TestCase include JSON def test_unicode assert_equal '""', ''.to_json assert_equa...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_fixtures.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_fixtures.rb
#!/usr/bin/env ruby # -*- coding: utf-8 -*- require 'test/unit' case ENV['JSON'] when 'pure' then require 'json/pure' when 'ext' then require 'json/ext' else require 'json' end class TC_JSONFixtures < Test::Unit::TestCase def setup fixtures = File.join(File.dirname(__FILE__), 'fixtures/*.json') ...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_rails.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_rails.rb
#!/usr/bin/env ruby # -*- coding: utf-8 -*- require 'test/unit' case ENV['JSON'] when 'pure' then require 'json/pure' when 'ext' then require 'json/ext' else require 'json' end require 'json/add/rails' require 'date' class TC_JSONRails < Test::Unit::TestCase include JSON class A def initialize(a...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_addition.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json_addition.rb
#!/usr/bin/env ruby # -*- coding:utf-8 -*- require 'test/unit' case ENV['JSON'] when 'pure' then require 'json/pure' when 'ext' then require 'json/ext' else require 'json' end require 'json/add/core' require 'date' class TC_JSONAddition < Test::Unit::TestCase include JSON class A def initialize(...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/tests/test_json.rb
#!/usr/bin/env ruby # -*- coding: utf-8 -*- require 'test/unit' case ENV['JSON'] when 'pure' then require 'json/pure' when 'ext' then require 'json/ext' else require 'json' end require 'stringio' unless Array.method_defined?(:permutation) begin require 'enumerator' require 'permutation' cla...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/bin/prettify_json.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/bin/prettify_json.rb
#!/usr/bin/env ruby require 'json' require 'fileutils' include FileUtils # Parses the argument array _args_, according to the pattern _s_, to # retrieve the single character command line options from it. If _s_ is # 'xy:' an option '-x' without an option argument is searched, and an # option '-y foo' with an option a...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/bin/edit_json.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/bin/edit_json.rb
#!/usr/bin/env ruby require 'json/editor' filename, encoding = ARGV JSON::Editor.start(encoding) do |window| if filename window.file_open(filename) end end
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false
ThoughtWorksStudios/oauth2_provider
https://github.com/ThoughtWorksStudios/oauth2_provider/blob/d54702f194edd05389968cf8947465860abccc5d/tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/ext/json/ext/generator/extconf.rb
tools/jruby-1.5.1/lib/ruby/gems/1.8/gems/json_pure-1.4.3/ext/json/ext/generator/extconf.rb
require 'mkmf' require 'rbconfig' unless $CFLAGS.gsub!(/ -O[\dsz]?/, ' -O3') $CFLAGS << ' -O3' end if CONFIG['CC'] =~ /gcc/ $CFLAGS << ' -Wall' #unless $CFLAGS.gsub!(/ -O[\dsz]?/, ' -O0 -ggdb') # $CFLAGS << ' -O0 -ggdb' #end end have_header("ruby/re.h") || have_header("re.h") have_header("ruby/encoding.h")...
ruby
MIT
d54702f194edd05389968cf8947465860abccc5d
2026-01-04T17:46:04.645080Z
false