learn_duplicate 0.0.15 → 0.0.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/bin/learn_duplicate +38 -21
- data/lib/learn_duplicate.rb +60 -51
- metadata +3 -37
- data/lib/templates/javascript_lab_template/CONTRIBUTING.md +0 -40
- data/lib/templates/javascript_lab_template/LICENSE.md +0 -23
- data/lib/templates/javascript_lab_template/README.md +0 -16
- data/lib/templates/javascript_lab_template/index.html +0 -12
- data/lib/templates/javascript_lab_template/index.js +0 -5
- data/lib/templates/javascript_lab_template/package-lock.json +0 -1854
- data/lib/templates/javascript_lab_template/package.json +0 -21
- data/lib/templates/javascript_lab_template/test/helpers.js +0 -20
- data/lib/templates/javascript_lab_template/test/indexTest.js +0 -23
- data/lib/templates/react-lab-template/README.md +0 -16
- data/lib/templates/react-lab-template/package-lock.json +0 -12333
- data/lib/templates/react-lab-template/package.json +0 -38
- data/lib/templates/react-lab-template/public/index.html +0 -41
- data/lib/templates/react-lab-template/public/manifest.json +0 -13
- data/lib/templates/react-lab-template/src/App.css +0 -5
- data/lib/templates/react-lab-template/src/App.js +0 -18
- data/lib/templates/react-lab-template/src/components/Button.js +0 -19
- data/lib/templates/react-lab-template/src/components/ExampleComponent.js +0 -15
- data/lib/templates/react-lab-template/src/components/Greeting.js +0 -15
- data/lib/templates/react-lab-template/src/index.js +0 -8
- data/lib/templates/react-lab-template/test/index.test.js +0 -64
- data/lib/templates/react-lab-template/test/mocha.opts +0 -4
- data/lib/templates/readme_template/CONTRIBUTING.md +0 -40
- data/lib/templates/readme_template/LICENSE.md +0 -23
- data/lib/templates/readme_template/README.md +0 -16
- data/lib/templates/ruby_lab_template/CONTRIBUTING.md +0 -40
- data/lib/templates/ruby_lab_template/Gemfile +0 -4
- data/lib/templates/ruby_lab_template/Gemfile.lock +0 -32
- data/lib/templates/ruby_lab_template/LICENSE.md +0 -23
- data/lib/templates/ruby_lab_template/README.md +0 -16
- data/lib/templates/ruby_lab_template/lib/example.rb +0 -13
- data/lib/templates/ruby_lab_template/spec/example_spec.rb +0 -37
- data/lib/templates/ruby_lab_template/spec/spec_helper.rb +0 -65
@@ -1,37 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe 'These examples' do
|
4
|
-
it 'can be used to confirm if a method is present in required relative' do
|
5
|
-
expect { test_method }.not_to raise_error
|
6
|
-
end
|
7
|
-
|
8
|
-
it 'can be used to confirm if a method is not present in required relative' do
|
9
|
-
expect { second_test_method }.to raise_error(NameError)
|
10
|
-
end
|
11
|
-
|
12
|
-
it 'can be used to confirm if a method returns expected results in required relative' do
|
13
|
-
expect(test_method).to eq('bears') # equal(): strict comparison, eq(): value comparison
|
14
|
-
end
|
15
|
-
|
16
|
-
it 'can be used to confirm if a class contains a specific method' do
|
17
|
-
expect(ExampleClass).to respond_to(:class_test)
|
18
|
-
end
|
19
|
-
|
20
|
-
it 'can be used to confirm if an instance method returns the expected results' do
|
21
|
-
example = ExampleClass.new
|
22
|
-
expect(example.instance_test).to eq('seriously')
|
23
|
-
end
|
24
|
-
|
25
|
-
it 'can be used to match strings' do
|
26
|
-
expect('There are two bears in a tree').to match(/bears in a tree/)
|
27
|
-
expect("They're both on the same limb").to include('limb')
|
28
|
-
end
|
29
|
-
|
30
|
-
it 'can check types' do
|
31
|
-
example = ExampleClass.new
|
32
|
-
expect(example).to be_instance_of(ExampleClass)
|
33
|
-
|
34
|
-
example_array = [1, 2, 3]
|
35
|
-
expect(example_array).to be_kind_of(Array)
|
36
|
-
end
|
37
|
-
end
|
@@ -1,65 +0,0 @@
|
|
1
|
-
require 'bundler'
|
2
|
-
Bundler.require
|
3
|
-
require 'yaml'
|
4
|
-
CREATED_FILES = Dir.glob(File.join(File.dirname(__FILE__), '..', 'lib', '*.rb'))
|
5
|
-
CREATED_FILES.each{ |f| require f }
|
6
|
-
|
7
|
-
# This file was generated by the `rspec --init` command. Conventionally, all
|
8
|
-
# specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
|
9
|
-
# The generated `.rspec` file contains `--require spec_helper` which will cause
|
10
|
-
# this file to always be loaded, without a need to explicitly require it in any
|
11
|
-
# files.
|
12
|
-
#
|
13
|
-
# Given that it is always loaded, you are encouraged to keep this file as
|
14
|
-
# light-weight as possible. Requiring heavyweight dependencies from this file
|
15
|
-
# will add to the boot time of your test suite on EVERY test run, even for an
|
16
|
-
# individual file that may not need all of that loaded. Instead, consider making
|
17
|
-
# a separate helper file that requires the additional dependencies and performs
|
18
|
-
# the additional setup, and require it from the spec files that actually need
|
19
|
-
# it.
|
20
|
-
#
|
21
|
-
# See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
|
22
|
-
RSpec.configure do |config|
|
23
|
-
# rspec-expectations config goes here. You can use an alternate
|
24
|
-
# assertion/expectation library such as wrong or the stdlib/minitest
|
25
|
-
# assertions if you prefer.
|
26
|
-
config.expect_with :rspec do |expectations|
|
27
|
-
# This option will default to `true` in RSpec 4. It makes the `description`
|
28
|
-
# and `failure_message` of custom matchers include text for helper methods
|
29
|
-
# defined using `chain`, e.g.:
|
30
|
-
# be_bigger_than(2).and_smaller_than(4).description
|
31
|
-
# # => "be bigger than 2 and smaller than 4"
|
32
|
-
# ...rather than:
|
33
|
-
# # => "be bigger than 2"
|
34
|
-
expectations.include_chain_clauses_in_custom_matcher_descriptions = true
|
35
|
-
end
|
36
|
-
|
37
|
-
# rspec-mocks config goes here. You can use an alternate test double
|
38
|
-
# library (such as bogus or mocha) by changing the `mock_with` option here.
|
39
|
-
config.mock_with :rspec do |mocks|
|
40
|
-
# Prevents you from mocking or stubbing a method that does not exist on
|
41
|
-
# a real object. This is generally recommended, and will default to
|
42
|
-
# `true` in RSpec 4.
|
43
|
-
mocks.verify_partial_doubles = true
|
44
|
-
end
|
45
|
-
|
46
|
-
config.shared_context_metadata_behavior = :apply_to_host_groups
|
47
|
-
end
|
48
|
-
|
49
|
-
# To parse and test an HTML file, add 'nokogiri' to Gemfile and uncomment these methods
|
50
|
-
# def html_file_contents
|
51
|
-
# File.read('./index.html')
|
52
|
-
# end
|
53
|
-
#
|
54
|
-
# def parsed_html
|
55
|
-
# Nokogiri::HTML(html_file_contents) do |config|
|
56
|
-
# config.strict.dtdload.dtdvalid.noblanks
|
57
|
-
# end
|
58
|
-
# end
|
59
|
-
|
60
|
-
# To parse and test a CSS file, add 'css_parser' to Gemfile and uncomment this method
|
61
|
-
# def parsed_css
|
62
|
-
# parser = CssParser::Parser.new
|
63
|
-
# parser.load_uri!('./style.css')
|
64
|
-
# parser
|
65
|
-
# end
|