source stringclasses 1
value | repo stringlengths 5 63 | repo_url stringlengths 24 82 | path stringlengths 5 167 | language stringclasses 1
value | license stringclasses 5
values | stars int64 10 51.4k | ref stringclasses 23
values | size_bytes int64 200 258k | text stringlengths 137 258k |
|---|---|---|---|---|---|---|---|---|---|
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/add_to_list/inspec/controls/add_to_list_2d.rb | Ruby | apache-2.0 | 97 | main | 391 | #
# Test for lists with 2 delimitors ||, ||
#
control 'add_to_list_2d' do
describe file('/tmp/2d') do
it { should exist }
its('content') { should match /^wo2d_empty="single"$/ }
its('content') { should match /^wo2d_list="first2","second2","third2"$/ }
end
describe file_ext('/tmp/2d') do
it { shou... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/add_to_list/inspec/controls/add_to_list_1d_terminal.rb | Ruby | apache-2.0 | 97 | main | 435 | #
# Test for lists with 1 delimitor and a terminal " , "
#
control 'add_to_list_1d_terminal' do
describe file('/tmp/1d_term') do
it { should exist }
its('content') { should match /^DEFAULT_APPEND_EMPTY="first"$/ }
its('content') { should match /^DEFAULT_APPEND="resume.*showopts newopt"$/ }
end
descri... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/add_to_list/inspec/controls/add_to_list_3d_terminal.rb | Ruby | apache-2.0 | 97 | main | 439 | #
# Test for lists with 3 delimitors and a terminal ([], [])
#
control 'add_to_list_3d_terminal' do
describe file('/tmp/3d_term') do
it { should exist }
its('content') { should match /^multi = \(\[310\], \[323\], \[789\]\)$/ }
its('content') { should match /^empty_3delim=\(\[3_with_end\]\)$/ }
end
de... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/add_to_list/inspec/controls/add_to_list_3d.rb | Ruby | apache-2.0 | 97 | main | 399 | #
# Test for lists with 3 delimitors [], []
#
control 'add_to_list_3d' do
describe file('/tmp/3d') do
it { should exist }
its('content') { should match /^wo3d_empty=\[single\]$/ }
its('content') { should match /^wo3d_list=\[first3\],\[second3\],\[third3\]$/ }
end
describe file_ext('/tmp/3d') do
i... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/add_to_list/inspec/controls/add_to_list_2d_terminal.rb | Ruby | apache-2.0 | 97 | main | 452 | #
# Test for lists with 2 delimitors and a terminal (||, ||)
#
control 'add_to_list_2d_terminal' do
describe file('/tmp/2d_term') do
it { should exist }
its('content') { should match /^empty_delimited_list=\(\|empty\|\)$/ }
its('content') { should match /^last_delimited_list= \(\|single\|, \|double\|\)$/... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/replace_or_add/controls/replace_or_add_change_line_eof.rb | Ruby | apache-2.0 | 97 | main | 375 | #
# Change last line
#
control 'replace_or_add_change_line' do
describe file('/tmp/change_line_eof') do
it { should exist }
end
describe matches('/tmp/change_line_eof', /^Last line changed$/) do
its('count') { should eq 1 }
end
describe file_ext('/tmp/change_line_eof') do
it { should have_correct... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/replace_or_add/controls/replace_or_add_replace_only.rb | Ruby | apache-2.0 | 97 | main | 683 | #
# Replace only
control 'replace_or_add_replace_only' do
file('/tmp/replace_only') do
it { should exist }
its('content') { should_not match /^Penultimate$/ }
end
describe matches('/tmp/replace_only', /^Penultimate Replacement$/) do
its('count') { should eq 1 }
end
describe file_ext('/tmp/replace... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/replace_or_add/controls/replace_or_add_add_a_line_matching_pattern.rb | Ruby | apache-2.0 | 97 | main | 437 | #
# Add a line matching pattern
#
control 'replace_or_add_add_a_line_matching_pattern' do
describe file('/tmp/add_a_line_matching_pattern') do
it { should exist }
end
describe matches('/tmp/add_a_line_matching_pattern', /^Add another line$/) do
its('count') { should eq 1 }
end
describe file_ext('/tmp... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/replace_or_add/controls/replace_or_add_missing_file.rb | Ruby | apache-2.0 | 97 | main | 1,344 | #
# Replace or add with missing file
#
control 'replace_or_add_missing_file' do
describe file('/tmp/missingfile') do
it { should_not exist }
end
describe file('/tmp/missingfile_replace_only') do
it { should_not exist }
end
describe file('/tmp/missingfile_no_match') do
it { should exist }
end
... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/replace_or_add/controls/replace_or_add_manage_symlink_source.rb | Ruby | apache-2.0 | 97 | main | 627 | control 'replace_or_add_manage_symlink_source' do
describe command('test -L /tmp/replace_or_add_symlink') do
its('exit_status') { should eq 0 }
end
describe file('/tmp/replace_or_add_symlink') do
it { should exist }
its('content') { should match(/^updated through target$/) }
end
describe file('/... |
github | sous-chefs/line | https://github.com/sous-chefs/line | test/integration/replace_or_add/controls/replace_or_add_duplicate.rb | Ruby | apache-2.0 | 97 | main | 1,750 | #
# Replace with duplicate line
#
control 'replace_or_add_duplicate' do
describe file('/tmp/duplicate') do
it { should exist }
its('content') { should_not match /^Identical line$/ }
end
describe matches('/tmp/duplicate', /^Replace duplicate lines$/) do
its('count') { should eq 2 }
end
describe fi... |
github | sous-chefs/line | https://github.com/sous-chefs/line | resources/add_to_list.rb | Ruby | apache-2.0 | 97 | main | 1,014 | property :backup, [true, false, Integer], default: false
property :delim, Array
property :ends_with, String
property :entry, String
property :eol, String
property :ignore_missing, [true, false], default: true
property :manage_symlink_source, [true, false]
property :path, String
property :pattern, [String, Regexp]
reso... |
github | sous-chefs/line | https://github.com/sous-chefs/line | resources/delete_from_list.rb | Ruby | apache-2.0 | 97 | main | 1,053 | property :backup, [true, false, Integer], default: false
property :delim, Array
property :entry, String
property :ends_with, String
property :eol, String
property :ignore_missing, [true, false], default: true
property :manage_symlink_source, [true, false]
property :path, String
property :pattern, [String, Regexp]
reso... |
github | sous-chefs/line | https://github.com/sous-chefs/line | resources/replace_or_add.rb | Ruby | apache-2.0 | 97 | main | 1,620 | property :backup, [true, false, Integer], default: false
property :eol, String
property :group, String
property :ignore_missing, [true, false], default: true
property :line, String
property :manage_symlink_source, [true, false]
property :mode, [String, Integer]
property :owner, String
property :path, String
property :p... |
github | sous-chefs/line | https://github.com/sous-chefs/line | resources/filter_lines.rb | Ruby | apache-2.0 | 97 | main | 2,686 | #
# Copyright:: 2019 Sous Chefs
#
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing... |
github | sous-chefs/line | https://github.com/sous-chefs/line | resources/append_if_no_line.rb | Ruby | apache-2.0 | 97 | main | 1,153 | property :backup, [true, false, Integer], default: false
property :eol, String
property :group, String
property :ignore_missing, [true, false], default: true
property :line, String
property :manage_symlink_source, [true, false]
property :mode, [String, Integer]
property :owner, String
property :path, String
resource_n... |
github | sous-chefs/line | https://github.com/sous-chefs/line | resources/delete_lines.rb | Ruby | apache-2.0 | 97 | main | 1,090 | property :backup, [true, false, Integer], default: false
property :eol, String
property :ignore_missing, [true, false], default: true
property :manage_symlink_source, [true, false]
property :path, String
property :pattern, [String, Regexp]
resource_name :delete_lines
provides :delete_lines
unified_mode true
action :e... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | rubocop-thread_safety.gemspec | Ruby | mit | 96 | master | 1,333 | # frozen_string_literal: true
lib = File.expand_path('lib', __dir__)
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
require 'rubocop/thread_safety/version'
Gem::Specification.new do |spec|
spec.name = 'rubocop-thread_safety'
spec.version = RuboCop::ThreadSafety::VERSION
spec.authors ... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | Appraisals | Ruby | mit | 96 | master | 498 | # frozen_string_literal: true
appraise 'rubocop-0.53' do
gem 'rubocop', '~> 0.53.0'
end
appraise 'rubocop-0.81' do
gem 'rubocop', '~> 0.81.0'
end
if Gem::Requirement.new('>= 2.4.0')
.satisfied_by?(Gem::Version.new(RUBY_VERSION))
appraise 'rubocop-0.86' do
gem 'rubocop', '~> 0.86.0'
end... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | spec/license_spec.rb | Ruby | mit | 96 | master | 508 | # frozen_string_literal: true
require 'spec_helper'
RSpec.describe 'the LICENSE' do
let(:license) { Pathname('LICENSE.txt') }
it 'exists' do
expect(license).to exist
end
it 'contains a copyright statement for the current year' do
expect(license.read).to match(/Copyright 2016-#{Date.today.year}/)
e... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | spec/spec_helper.rb | Ruby | mit | 96 | master | 841 | # frozen_string_literal: true
begin
require 'pry'
rescue LoadError
# Pry isn't installed in CI.
end
$LOAD_PATH.unshift File.expand_path('../lib', __dir__)
require 'rubocop-thread_safety'
require 'rubocop/rspec/support'
RSpec.configure do |config|
config.include RuboCop::RSpec::ExpectOffense
config.expect_w... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | spec/rubocop/cop/thread_safety/instance_variable_in_class_method_spec.rb | Ruby | mit | 96 | master | 7,602 | # frozen_string_literal: true
RSpec.describe RuboCop::Cop::ThreadSafety::InstanceVariableInClassMethod do
subject(:cop) { described_class.new }
it 'registers an offense for assigning to an ivar in a class method' do
expect_offense(<<~RUBY)
class Test
def self.some_method(params)
@param... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | spec/rubocop/cop/thread_safety/new_thread_spec.rb | Ruby | mit | 96 | master | 636 | # frozen_string_literal: true
RSpec.describe RuboCop::Cop::ThreadSafety::NewThread do
subject(:cop) { described_class.new }
it 'registers an offense for starting a new thread' do
expect_offense(<<~RUBY)
Thread.new { do_work }
^^^^^^^^^^ Avoid starting new threads.
RUBY
end
it 'registers a... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | spec/rubocop/cop/thread_safety/mutable_class_instance_variable_spec.rb | Ruby | mit | 96 | master | 24,023 | # frozen_string_literal: true
RSpec.describe RuboCop::Cop::ThreadSafety::MutableClassInstanceVariable,
:config do
subject(:cop) { described_class.new(config) }
let(:msg) { 'Freeze mutable objects assigned to class instance variables.' }
if Gem::Requirement.new('< 0.69')
.satis... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | spec/rubocop/cop/thread_safety/class_and_module_attributes_spec.rb | Ruby | mit | 96 | master | 3,647 | # frozen_string_literal: true
RSpec.describe RuboCop::Cop::ThreadSafety::ClassAndModuleAttributes do
subject(:cop) { described_class.new }
let(:msg) { 'Avoid mutating class and module attributes.' }
context 'when in the singleton class' do
it 'registers an offense for `attr`' do
expect_offense(<<~RUBY... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | lib/rubocop-thread_safety.rb | Ruby | mit | 96 | master | 452 | # frozen_string_literal: true
require 'rubocop'
require 'rubocop/thread_safety'
require 'rubocop/thread_safety/version'
require 'rubocop/thread_safety/inject'
RuboCop::ThreadSafety::Inject.defaults!
require 'rubocop/cop/thread_safety/instance_variable_in_class_method'
require 'rubocop/cop/thread_safety/class_and_mo... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | lib/rubocop/thread_safety.rb | Ruby | mit | 96 | master | 399 | # frozen_string_literal: true
module RuboCop
# RuboCop::ThreadSafety detects some potential thread safety issues.
module ThreadSafety
PROJECT_ROOT = Pathname.new(File.expand_path('../../', __dir__))
CONFIG_DEFAULT = PROJECT_ROOT.join('config', 'default.yml').freeze
CONFIG = YAML.safe_load(CONFIG_DEFAUL... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | lib/rubocop/cop/thread_safety/mutable_class_instance_variable.rb | Ruby | mit | 96 | master | 8,474 | # frozen_string_literal: true
module RuboCop
module Cop
module ThreadSafety
# This cop checks whether some class instance variable isn't a
# mutable literal (e.g. array or hash).
#
# It is based on Style/MutableConstant from RuboCop.
# See https://github.com/rubocop-hq/rubocop/blob/... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | lib/rubocop/cop/thread_safety/new_thread.rb | Ruby | mit | 96 | master | 600 | # frozen_string_literal: true
module RuboCop
module Cop
module ThreadSafety
# Avoid starting new threads.
#
# Let a framework like Sidekiq handle the threads.
#
# @example
# # bad
# Thread.new { do_work }
class NewThread < Cop
MSG = 'Avoid starting new ... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | lib/rubocop/cop/thread_safety/instance_variable_in_class_method.rb | Ruby | mit | 96 | master | 5,002 | # frozen_string_literal: true
module RuboCop
module Cop
module ThreadSafety
# Avoid instance variables in class methods.
#
# @example
# # bad
# class User
# def self.notify(info)
# @info = validate(info)
# Notifier.new(@info).deliver
# ... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | lib/rubocop/cop/thread_safety/class_and_module_attributes.rb | Ruby | mit | 96 | master | 1,740 | # frozen_string_literal: true
module RuboCop
module Cop
module ThreadSafety
# Avoid mutating class and module attributes.
#
# They are implemented by class variables, which are not thread-safe.
#
# @example
# # bad
# class User
# cattr_accessor :current_use... |
github | covermymeds/rubocop-thread_safety | https://github.com/covermymeds/rubocop-thread_safety | lib/rubocop/thread_safety/inject.rb | Ruby | mit | 96 | master | 819 | # frozen_string_literal: true
# The original code is from https://github.com/rubocop-hq/rubocop-rspec/blob/master/lib/rubocop/rspec/inject.rb
# See https://github.com/rubocop-hq/rubocop-rspec/blob/master/MIT_LICENSE.md
module RuboCop
module ThreadSafety
# Because RuboCop doesn't yet support plugins, we have to m... |
github | copyhacker/backup_fu | https://github.com/copyhacker/backup_fu | lib/backup_fu.rb | Ruby | mit | 96 | master | 11,624 | require 'yaml'
require 'active_support'
require 'mime/types'
require 'right_aws'
require 'erb'
class BackupFuConfigError < StandardError; end
class S3ConnectError < StandardError; end
class BackupFu
def initialize
db_conf = YAML.load_file(File.join(RAILS_ROOT, 'config', 'database.yml'))
@db_conf = db_co... |
github | copyhacker/backup_fu | https://github.com/copyhacker/backup_fu | tasks/backup_fu_tasks.rake | Ruby | mit | 96 | master | 2,337 | require 'fileutils'
$:.unshift(File.dirname(__FILE__) + '/../lib')
require 'backup_fu'
$backup_fu_path = File.join(File.dirname(__FILE__), '..')
desc "Dumps the database and backs it up remotely to Amazon S3. (task added by: backup_fu)"
task :backup do
b = BackupFu.new
b.backup
end
namespace :backup_fu do
d... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | ruby-hl7.gemspec | Ruby | mit | 96 | master | 2,400 | # Generated by jeweler
# DO NOT EDIT THIS FILE
# Instead, edit Jeweler::Tasks in Rakefile, and run `rake gemspec`
# -*- encoding: utf-8 -*-
Gem::Specification.new do |s|
s.name = %q{ruby-hl7}
s.version = "0.4.0"
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_versi... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | Rakefile | Ruby | mit | 96 | master | 5,167 | # $Id$
require 'rubygems'
require 'rake'
require 'rake/testtask'
require 'rdoc/task'
require 'rake/packagetask'
require 'rubygems/package_task'
require 'rake/contrib/sshpublisher'
require 'rbconfig'
require 'rubyforge'
$: << './lib'
require 'ruby-hl7'
full_name = "Ruby-HL7"
short_name = full_name.downcase
... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_pid_segment.rb | Ruby | mit | 96 | master | 618 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class PidSegment < Test::Unit::TestCase
def setup
@base = "PID|||333||LastName^FirstName^MiddleInitial^SR^NickName||19760228|F||||||||||555. 55|012345678"
end
def test_admin_sex_limits
pid = HL7::Message::Segment::PID.new
assert... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_obx_segment.rb | Ruby | mit | 96 | master | 791 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class ObxSegment < Test::Unit::TestCase
def setup
@base = "OBX||TX|FIND^FINDINGS^L|1|This is a test on 05/02/94."
end
def test_initial_read
obx = HL7::Message::Segment::OBX.new @base
assert_equal( "", obx.set_id )
assert_eq... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_orc_segment.rb | Ruby | mit | 96 | master | 1,215 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class OrcSegment < Test::Unit::TestCase
def setup
@base = "ORC|RE|HOSP333444|ZZ13-886644|CM||||20130620090252|20130620091418000|||1639330756^Haston^W^^^^^^^^^^NPI|10114A1|||||||||||"
end
def test_read
orc = HL7::Message::Segment::OR... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_dynamic_segment_def.rb | Ruby | mit | 96 | master | 793 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class DynamicSegmentDefinition < Test::Unit::TestCase
def setup
end
def test_block_definition
seg = HL7::Message::Segment.new do |s|
s.e0 = "MSK"
s.e1 = "1234"
s.e2 = "5678"
end
assert_equal( "MSK|1234|5678", ... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_speed_parsing.rb | Ruby | mit | 96 | master | 427 | # encoding: UTF-8
$: << '../lib'
require 'time'
require 'test/unit'
require 'ruby-hl7'
class SpeedParsing < Test::Unit::TestCase
def setup
@msg = open( "./test_data/lotsunknowns.hl7" ).readlines
end
def test_large_unknown_segments
start = Time.now
doc = HL7::Message.new @msg
assert_not_nil doc
... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_msa_segment.rb | Ruby | mit | 96 | master | 578 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class MsaSegment < Test::Unit::TestCase
def setup
@base_msa = "MSA|AR|ZZ9380 ERR"
end
def test_create_msa
assert_nothing_raised do
msa = HL7::Message::Segment::MSA.new( @base_msa )
assert_not_nil( msa )
assert_equa... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_child_segment.rb | Ruby | mit | 96 | master | 1,342 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class ChildSegment < Test::Unit::TestCase
def setup
@base = open( './test_data/obxobr.hl7' ).readlines
end
def test_access_children
msg = HL7::Message.new @base
assert_not_nil msg
assert_not_nil msg[:OBR]
assert_equal( 3... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_basic_parsing.rb | Ruby | mit | 96 | master | 8,699 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class BasicParsing < Test::Unit::TestCase
def setup
@simple_msh_txt = open( './test_data/test.hl7' ).readlines.first
@empty_txt = open( './test_data/empty.hl7' ).readlines.first
@empty_segments_txt = open( './test_data/empty_segments... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_default_segment.rb | Ruby | mit | 96 | master | 709 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class MsaSegment < Test::Unit::TestCase
def setup
@base_msa = "MSA|AR|ZZ9380 ERR"
end
def test_storing_existing_segment
seg = HL7::Message::Segment::Default.new( @base_msa )
assert_equal( @base_msa, seg.to_s )
end
def test_... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | test/test_obr_segment.rb | Ruby | mit | 96 | master | 872 | # encoding: UTF-8
$: << '../lib'
require 'test/unit'
require 'ruby-hl7'
class ObrSegment < Test::Unit::TestCase
def setup
@base = "OBR|2|^USSSA|0000000567^USSSA|37956^CT ABDOMEN^LN|||199405021550|||||||||||||0000763|||||P||||||R/O TUMOR|202300&BAKER&MARK&E|||01&LOCHLEAR&JUDY"
end
def test_read
obr = HL7... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | examples/proxy_server.rb | Ruby | mit | 96 | master | 586 | # $Id$
# Ruby-HL7 Proxy Server Example
require 'rubygems'
require 'ruby-hl7'
require 'thread'
require 'socket'
PORT = 2402
target_ip = "127.0.0.1"
target_port = 5900
srv = TCPServer.new(PORT)
puts "proxy_server listening on port: %i" % PORT
puts "proxying for: %s:%i" % [ target_ip, target_port ]
while true
sok = sr... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/ruby-hl7.rb | Ruby | mit | 96 | master | 17,533 | # encoding: UTF-8
#= ruby-hl7.rb
# Ruby HL7 is designed to provide a simple, easy to use library for
# parsing and generating HL7 (2.x) messages.
#
#
# Author: Mark Guzman (mailto:segfault@hasno.info)
#
# Copyright: (c) 2006-2009 Mark Guzman
#
# License: BSD
#
# $Id$
#
# == License
# see the LICENSE file ... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/msh.rb | Ruby | mit | 96 | master | 735 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::MSH < HL7::Message::Segment
weight( -1 ) # the msh should always start a message
add_field :enc_chars, :idx=>1
add_field :sending_app, :idx=>2
add_field :sending_facility, :idx=>3
add_field :recv_app, :idx=>4
add_field :recv_facility, :idx=>5... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/nte.rb | Ruby | mit | 96 | master | 232 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::NTE < HL7::Message::Segment
weight 4
add_field :set_id, :idx=>1
add_field :source, :idx=>2
add_field :comment, :idx=>3
add_field :comment_type, :idx=>4
end |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/orc.rb | Ruby | mit | 96 | master | 424 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::ORC < HL7::Message::Segment
weight 4
add_field :order_control, :idx=>1
add_field :placer_order_number, :idx=>2
add_field :filler_order_number, :idx=>3
add_field :order_status, :idx=>5
add_field :transaction_timestamp, :idx=>9
add_field :ord... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/obx.rb | Ruby | mit | 96 | master | 716 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::OBX < HL7::Message::Segment
weight 90
has_children [:NTE]
add_field :set_id
add_field :value_type
add_field :observation_id
add_field :observation_sub_id
add_field :observation_value
add_field :units
add_field :references_range
add_fi... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/pv2.rb | Ruby | mit | 96 | master | 1,845 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::PV2 < HL7::Message::Segment
weight 3
add_field :prior_pending_location
add_field :accommodation_code
add_field :admit_reason
add_field :transfer_reason
add_field :patient_valuables
add_field :patient_valuables_location
add_field :visit_us... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/qrf.rb | Ruby | mit | 96 | master | 460 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::QRF < HL7::Message::Segment
weight 85
add_field :where_subject_filter
add_field :when_start_date
add_field :when_end_date
add_field :what_user_qualifier
add_field :other_qry_subject_filter
add_field :which_date_qualifier
add_field :which_... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/pv1.rb | Ruby | mit | 96 | master | 1,695 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::PV1 < HL7::Message::Segment
weight 2
add_field :set_id
add_field :patient_class
add_field :assigned_location
add_field :admission_type
add_field :preadmit_number
add_field :prior_location
add_field :attending_doctor
add_field :referring... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/obr.rb | Ruby | mit | 96 | master | 1,736 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::OBR < HL7::Message::Segment
weight 89 # obr.weight-1
has_children [:OBX]
add_field :set_id
add_field :placer_order_number
add_field :filler_order_number
add_field :universal_service_id
add_field :priority
add_field :requested_date
add_f... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/qrd.rb | Ruby | mit | 96 | master | 485 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::QRD < HL7::Message::Segment
weight 84
add_field :query_date
add_field :query_format_code
add_field :query_priority
add_field :query_id
add_field :deferred_response_type
add_field :deferred_response_date
add_field :quantity_limited_request... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/evn.rb | Ruby | mit | 96 | master | 392 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::EVN < HL7::Message::Segment
weight 0 # should occur after the MSH segment
add_field :type_code, :idx=>1
add_field :recorded_date, :idx=>2
add_field :planned_date, :idx=>3
add_field :reason_code, :idx=>4
add_field :operator_id, :idx=>5
add_... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/pid.rb | Ruby | mit | 96 | master | 1,327 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::PID < HL7::Message::Segment
weight 1
add_field :set_id
add_field :patient_id
add_field :patient_id_list
add_field :alt_patient_id
add_field :patient_name
add_field :mother_maiden_name
add_field :patient_dob
add_field :admin_sex do |sex|... |
github | segfault/ruby-hl7 | https://github.com/segfault/ruby-hl7 | lib/segments/msa.rb | Ruby | mit | 96 | master | 291 | # encoding: UTF-8
require 'ruby-hl7'
class HL7::Message::Segment::MSA < HL7::Message::Segment
weight 0 # should occur after the msh segment
add_field :ack_code
add_field :control_id
add_field :text
add_field :expected_seq
add_field :delayed_ack_type
add_field :error_cond
end |
github | IcaliaLabs/pager-api | https://github.com/IcaliaLabs/pager-api | pager_api.gemspec | Ruby | mit | 96 | master | 990 | # coding: utf-8
lib = File.expand_path('../lib', __FILE__)
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
require 'pager_api/version'
Gem::Specification.new do |spec|
spec.name = "pager_api"
spec.version = PagerApi::VERSION
spec.authors = ["Abraham Kuri"]
spec.email = ["ku... |
github | IcaliaLabs/pager-api | https://github.com/IcaliaLabs/pager-api | lib/pager_api.rb | Ruby | mit | 96 | master | 868 | module PagerApi
# pagination handler
mattr_accessor :pagination_handler
@@pagination_handler = :pagy
# Meta tag information for pagination
mattr_accessor :include_pagination_on_meta
@@include_pagination_on_meta = true
# Links headeras with pagination information
mattr_accessor :include_pagination_hea... |
github | IcaliaLabs/pager-api | https://github.com/IcaliaLabs/pager-api | lib/pager_api/hooks.rb | Ruby | mit | 96 | master | 793 | pagination_handler_name = PagerApi.pagination_handler.to_s
begin
require pagination_handler_name
rescue LoadError
Kernel.warn <<-WARNING.gsub(/^\s{4}/, "")
Warning: pager-api needs #{pagination_handler_name} as a dependency.
You need to add it to your Gemfile
gem '#{pagination_handler_name}'
Also... |
github | IcaliaLabs/pager-api | https://github.com/IcaliaLabs/pager-api | lib/pager_api/pagination/pagy.rb | Ruby | mit | 96 | master | 2,532 | module PagerApi
module Pagination
module Pagy
include ::Pagy::Backend
def paginate(*args)
options = args.extract_options!
collection = args.first
pagy, paginated_collection = paginate_collection(collection, options)
options[:json] = paginated_collection
opti... |
github | IcaliaLabs/pager-api | https://github.com/IcaliaLabs/pager-api | lib/pager_api/pagination/will_paginate.rb | Ruby | mit | 96 | master | 2,841 | module PagerApi
module Pagination
module WillPaginate
def paginate(*args)
options = args.extract_options!
collection = args.first
paginated_collection = paginate_collection(collection, options)
options[:json] = paginated_collection
options[:meta] = meta(paginated_... |
github | IcaliaLabs/pager-api | https://github.com/IcaliaLabs/pager-api | lib/pager_api/pagination/kaminari.rb | Ruby | mit | 96 | master | 2,938 | module PagerApi
module Pagination
module Kaminari
def paginate(*args)
options = args.extract_options!
collection = args.first
paginated_collection = paginate_collection(collection, options)
options[:json] = paginated_collection
options[:meta] = meta(paginated_coll... |
github | IcaliaLabs/pager-api | https://github.com/IcaliaLabs/pager-api | lib/generators/pager_api/install_generator.rb | Ruby | mit | 96 | master | 341 | module PagerApi
module Generators
class InstallGenerator < Rails::Generators::Base
source_root File.expand_path("../templates", __FILE__)
desc "Creates a PagerApi initializer in your application"
def copy_initializer
template "pager_api.rb", "config/initializers/pager_api.rb"
e... |
github | IcaliaLabs/pager-api | https://github.com/IcaliaLabs/pager-api | lib/generators/pager_api/templates/pager_api.rb | Ruby | mit | 96 | master | 651 | # Use this module to configure pager the available options
#
# Made with love by @icalialabs
PagerApi.setup do |config|
# Pagination Handler
# User this option to meet your pagination handler, whether is :kaminari or :will_paginate
# config.pagination_handler = :kaminari
# Includes Pagination information on ... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | sprockets-helpers.gemspec | Ruby | mit | 96 | master | 1,153 | # -*- encoding: utf-8 -*-
$:.push File.expand_path('../lib', __FILE__)
require 'sprockets/helpers/version'
Gem::Specification.new do |s|
s.name = 'sprockets-helpers'
s.version = Sprockets::Helpers::VERSION
s.licenses = ['MIT']
s.authors = ['Pete Browne']
s.email = ['me@petebrowne.com'... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | Appraisals | Ruby | mit | 96 | master | 755 | appraise 'sprockets-2.2' do
gem 'sprockets', '~> 2.2.0'
end
appraise 'sprockets-2.3' do
gem 'sprockets', '~> 2.3.0'
end
appraise 'sprockets-2.4' do
gem 'sprockets', '~> 2.4.0'
end
appraise 'sprockets-2.5' do
gem 'sprockets', '~> 2.5.0'
end
appraise 'sprockets-2.6' do
gem 'sprockets', '~> 2.6.0'
end
appra... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | spec/spec_helper.rb | Ruby | mit | 96 | master | 1,729 | require 'sprockets'
require 'sprockets-helpers'
require 'sinatra/base'
require 'sinatra/sprockets/helpers'
require 'test_construct'
require 'pathname'
# Requires supporting files with custom matchers and macros, etc,
# in ./support/ and its subdirectories.
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| re... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | spec/sprockets-helpers_spec.rb | Ruby | mit | 96 | master | 25,565 | require 'spec_helper'
describe Sprockets::Helpers do
describe '.configure' do
it 'sets global configuration' do
within_construct do |c|
c.file 'assets/main.css'
expect(context.asset_path('main.css')).to eq('/assets/main.css')
Sprockets::Helpers.configure do |config|
conf... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | lib/sprockets/helpers.rb | Ruby | mit | 96 | master | 14,507 | require 'sprockets'
require 'sprockets/helpers/version'
require 'sprockets/helpers/base_path'
require 'sprockets/helpers/asset_path'
require 'sprockets/helpers/file_path'
require 'sprockets/helpers/manifest_path'
require 'sprockets/helpers/settings'
require 'uri'
require 'forwardable'
module Sprockets
module Helpers... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | lib/sprockets/helpers/base_path.rb | Ruby | mit | 96 | master | 2,958 | require 'uri'
require 'zlib'
module Sprockets
module Helpers
#
class BasePath
# The parsed URI from which to generate the full path to the asset.
attr_reader :uri
# The various options used when generating the path.
attr_reader :options
#
def initialize(uri, options = {}... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | lib/sprockets/helpers/asset_path.rb | Ruby | mit | 96 | master | 1,662 | module Sprockets
module Helpers
# `AssetPath` generates a full path for an asset
# that exists in Sprockets environment.
class AssetPath < BasePath
def initialize(uri, asset, environment, options = {})
@uri = uri
@asset = asset
@environment = environment
@options = op... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | lib/sprockets/helpers/file_path.rb | Ruby | mit | 96 | master | 1,087 | module Sprockets
module Helpers
# `FilePath` generates a full path for a regular file
# in the output path. It's used by #asset_path to generate
# paths when using asset tags like #javascript_include_tag,
# #stylesheet_link_tag, and #image_tag
class FilePath < BasePath
protected
... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | lib/sprockets/helpers/settings.rb | Ruby | mit | 96 | master | 2,054 | module Sprockets
module Helpers
class Settings
# Link to assets from a dedicated server.
attr_accessor :asset_host
# When true, the asset paths will return digest paths.
attr_accessor :digest
# When true, expand assets.
attr_accessor :expand
# When true, force debug mo... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | lib/sprockets/helpers/manifest_path.rb | Ruby | mit | 96 | master | 419 | module Sprockets
module Helpers
# `ManifestPath` uses the digest path and
# prepends the prefix.
class ManifestPath < AssetPath
def initialize(uri, path, options = {})
@uri = uri
@options = options
@options = {
:body => false,
:prefix => sprockets_helpers_... |
github | petebrowne/sprockets-helpers | https://github.com/petebrowne/sprockets-helpers | lib/sinatra/sprockets/helpers.rb | Ruby | mit | 96 | master | 963 | require 'sinatra/base'
require 'sprockets/helpers'
module Sinatra
module Sprockets
module Helpers
def self.registered(app)
app.helpers ::Sprockets::Helpers
app.configure_sprockets_helpers
end
def configure_sprockets_helpers(&block)
::Sprockets::Helpers.configure do |hel... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | commitgpt.gemspec | Ruby | mit | 96 | main | 1,550 | # frozen_string_literal: true
require_relative 'lib/commitgpt/version'
Gem::Specification.new do |spec|
spec.name = 'commitgpt'
spec.version = CommitGpt::VERSION
spec.authors = ['Peng Zhang']
spec.email = ['zpregister@gmail.com']
spec.summary = 'A CLI AI that writes git commit messages for you.'
spec.des... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | Gemfile | Ruby | mit | 96 | main | 313 | # frozen_string_literal: true
source 'https://rubygems.org'
# Specify your gem's dependencies in commitgpt.gemspec
gemspec
gem 'base64'
gem 'bigdecimal'
gem 'csv'
gem 'httparty'
group :development, :test do
gem 'rake', '~> 13.0'
gem 'rspec', '~> 3.0'
gem 'bundler-audit'
gem 'rubocop'
end
gem 'thor' |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | spec/commitgpt_spec.rb | Ruby | mit | 96 | main | 3,754 | # frozen_string_literal: true
require 'spec_helper'
require 'commitgpt/commit_ai'
RSpec.describe CommitGpt do
let(:commit_ai) { CommitGpt::CommitAi.new }
it 'has a version number' do
expect(CommitGpt::VERSION).not_to be nil
end
describe '#generate_commit' do
let(:http) { instance_double(Net::HTTP) }... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | spec/spec_helper.rb | Ruby | mit | 96 | main | 372 | # frozen_string_literal: true
require 'commitgpt'
RSpec.configure do |config|
# Enable flags like --only-failures and --next-failure
config.example_status_persistence_file_path = '.rspec_status'
# Disable RSpec exposing methods globally on `Module` and `main`
config.disable_monkey_patching!
config.expect_... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | lib/commitgpt/cli.rb | Ruby | mit | 96 | main | 2,741 | # frozen_string_literal: true
require 'thor'
require 'commitgpt/commit_ai'
require 'commitgpt/setup_wizard'
module CommitGpt
# CommitGpt CLI
class CLI < Thor
default_task :generate
desc 'generate', 'AI commits for you!'
method_option :models, aliases: '-m', type: :boolean, desc: 'List/Select availabl... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | lib/commitgpt/commit_ai.rb | Ruby | mit | 96 | main | 24,186 | # frozen_string_literal: true
require 'httparty'
require 'net/http'
require 'uri'
require 'json'
require 'io/console'
require 'tty-prompt'
require_relative 'string'
require_relative 'config_manager'
require_relative 'diff_helpers'
# CommitGpt based on GPT-3
module CommitGpt
# Commit AI roboter based on GPT-3
clas... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | lib/commitgpt/setup_wizard.rb | Ruby | mit | 96 | main | 10,899 | # frozen_string_literal: true
require 'tty-prompt'
require 'httparty'
require 'timeout'
require_relative 'config_manager'
require_relative 'provider_presets'
require_relative 'string'
module CommitGpt
# Interactive setup wizard for configuring AI providers
class SetupWizard
def initialize
@prompt = TTY:... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | lib/commitgpt/provider_presets.rb | Ruby | mit | 96 | main | 1,285 | # frozen_string_literal: true
module CommitGpt
# Provider presets for common AI providers
PROVIDER_PRESETS = [
{ label: 'Anthropic Claude', value: 'anthropic', base_url: 'https://api.anthropic.com/v1' },
{ label: 'Cerebras', value: 'cerebras', base_url: 'https://api.cerebras.ai/v1' },
{ label: 'DeepSee... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | lib/commitgpt/string.rb | Ruby | mit | 96 | main | 807 | # frozen_string_literal: true
require 'tty-prompt'
# Monkey patch TTY::Prompt::List to add padding at the bottom of menus
module TTY
class Prompt
# Monkey patch to add padding
class List
alias original_render_menu render_menu
# Override render_menu to add empty lines at the bottom
def ren... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | lib/commitgpt/config_manager.rb | Ruby | mit | 96 | main | 5,454 | # frozen_string_literal: true
require 'yaml'
require 'fileutils'
require_relative 'provider_presets'
require_relative 'string'
module CommitGpt
# Manages configuration files for CommitGPT
class ConfigManager
class << self
# Get the config directory path
def config_dir
File.expand_path('~/.... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | lib/commitgpt/diff_helpers.rb | Ruby | mit | 96 | main | 5,888 | # frozen_string_literal: true
module CommitGpt
# Helper methods for handling git diffs
# rubocop:disable Metrics/ModuleLength
module DiffHelpers
# Lock files to exclude from diff but detect changes
LOCK_FILES = %w[Gemfile.lock package-lock.json yarn.lock pnpm-lock.yaml].freeze
def git_diff
exc... |
github | ZPVIP/commitgpt | https://github.com/ZPVIP/commitgpt | Formula/commitgpt.rb | Ruby | mit | 96 | main | 681 | # frozen_string_literal: true
class Commitgpt < Formula
desc 'A CLI AI that writes git commit messages for you'
homepage 'https://github.com/ZPVIP/commitgpt'
url 'https://github.com/ZPVIP/commitgpt/archive/refs/tags/v0.3.6.tar.gz'
sha256 '02354cdb1a9abaa4c72e223553cde97af3de6b041b7fc9e08cb1a5d198a023ab'
lice... |
github | miksturait/cucumber_fm-plugin | https://github.com/miksturait/cucumber_fm-plugin | config/routes.rb | Ruby | mit | 96 | master | 675 | Rails.application.routes.draw do
post 'documentation/features/:id', :controller => 'documentation/features', :action => :update, :constraints => {:id => /.*[^(\/edit)]/},
:as => :feature_update
namespace :documentation do
get 'features/:id', :action => 'features#show', :constraints => {:id => /.*[^(\/(ed... |
github | miksturait/cucumber_fm-plugin | https://github.com/miksturait/cucumber_fm-plugin | app/helpers/documentation/features_helper.rb | Ruby | mit | 96 | master | 7,873 | module Documentation
module FeaturesHelper
def draw_report_rows(cfm)
if cfm.aggregate
draw_aggregate(cfm.aggregate)
else
draw_features(cfm.features)
end
end
def draw_features(features)
features.collect { |feature| draw_feature(feature, feature.scenarios) }.join
... |
github | miksturait/cucumber_fm-plugin | https://github.com/miksturait/cucumber_fm-plugin | app/controllers/documentation/assets_controller.rb | Ruby | mit | 96 | master | 779 | class Documentation::AssetsController < Documentation::ApplicationController
def get
if File.exist?(full_path)
send_file(full_path, {:type => file_content_type})
else
render :text => "file not found", :status => 404
end
end
private
def full_path
Rails.root.join('vendor', 'plugins'... |
github | miksturait/cucumber_fm-plugin | https://github.com/miksturait/cucumber_fm-plugin | app/controllers/documentation/application_controller.rb | Ruby | mit | 96 | master | 972 | class Documentation::ApplicationController < ActionController::Base
layout '/documentation/layouts/cucumber_fm'
helper :all
before_filter :save_config
helper_method :list_of_dirs
private
def feature_dir_path
git_dir_path.join('features')
end
def git_dir_path
Rails.root
end
def dir_that... |
github | miksturait/cucumber_fm-plugin | https://github.com/miksturait/cucumber_fm-plugin | app/controllers/documentation/features_controller.rb | Ruby | mit | 96 | master | 3,126 | class Documentation::FeaturesController < Documentation::ApplicationController
before_filter :fetch_feature, :only => [:show, :edit, :update, :delete, :rename, :move]
before_filter :cleanup_raw, :only => [:update]
def index
@highlight = 'business_overview'
cfm
end
def show
end
def statistic
... |
github | ku-progsys/rbsyn | https://github.com/ku-progsys/rbsyn | Gemfile | Ruby | bsd-3-clause | 96 | master | 285 | source "https://rubygems.org"
# Specify your gem's dependencies in rbsyn.gemspec
gemspec
gem "minisat", :git => "https://github.com/ngsankha/ruby-minisat"
gem "rdl", :git => "https://github.com/ngsankha/rdl", :branch => "rbsyn"
# gem "rdl", :path => "../rdl"
gem "warning", "~> 1.4" |
github | ku-progsys/rbsyn | https://github.com/ku-progsys/rbsyn | Rakefile | Ruby | bsd-3-clause | 96 | master | 1,057 | require "bundler/gem_tasks"
require "rake/testtask"
Rake::TestTask.new(:test) do |t|
t.libs << "test"
t.libs << "lib"
t.libs << "models"
t.test_files = FileList["test/unit/*_test.rb"]
end
Rake::TestTask.new(:bench) do |t|
t.libs << "test"
t.libs << "lib"
t.libs << "models"
t.test_files = FileList["tes... |
github | ku-progsys/rbsyn | https://github.com/ku-progsys/rbsyn | rbsyn.gemspec | Ruby | bsd-3-clause | 96 | master | 1,386 | lib = File.expand_path("lib", __dir__)
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
require "rbsyn/version"
Gem::Specification.new do |spec|
spec.name = "rbsyn"
spec.version = Rbsyn::VERSION
spec.authors = ["Sankha Narayan Guria"]
spec.email = ["sankha93@gmail.com"]
s... |
github | ku-progsys/rbsyn | https://github.com/ku-progsys/rbsyn | components/component_helper.rb | Ruby | bsd-3-clause | 96 | master | 3,571 | require_relative "active_record"
require_relative "stdlib"
class JoinTable
end
class ActiveRecord_Relation
end
def load_typedefs(*categories)
RDL.reset
Rbsyn::ActiveRecord::Utils.load_schema
categories.each { |category|
case category
when :stdlib
RDL.nowrap :BasicObject
RDL.type :BasicObje... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.