tests_doc 0.0.4 → 0.0.5
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/CHANGELOG.md +13 -0
- data/lib/tests_doc/version.rb +1 -1
- data/tests_doc.gemspec +2 -2
- metadata +9 -152
- data/examples/rails-4.2.5/.gitignore +0 -21
- data/examples/rails-4.2.5/.rspec +0 -3
- data/examples/rails-4.2.5/Gemfile +0 -34
- data/examples/rails-4.2.5/Gemfile.lock +0 -143
- data/examples/rails-4.2.5/README.md +0 -3
- data/examples/rails-4.2.5/Rakefile +0 -6
- data/examples/rails-4.2.5/app/assets/images/.keep +0 -0
- data/examples/rails-4.2.5/app/controllers/application_controller.rb +0 -2
- data/examples/rails-4.2.5/app/controllers/concerns/.keep +0 -0
- data/examples/rails-4.2.5/app/controllers/posts_controller.rb +0 -61
- data/examples/rails-4.2.5/app/controllers/users_controller.rb +0 -59
- data/examples/rails-4.2.5/app/mailers/.keep +0 -0
- data/examples/rails-4.2.5/app/models/.keep +0 -0
- data/examples/rails-4.2.5/app/models/concerns/.keep +0 -0
- data/examples/rails-4.2.5/app/models/post.rb +0 -3
- data/examples/rails-4.2.5/app/models/user.rb +0 -2
- data/examples/rails-4.2.5/bin/bundle +0 -3
- data/examples/rails-4.2.5/bin/rails +0 -9
- data/examples/rails-4.2.5/bin/rake +0 -9
- data/examples/rails-4.2.5/bin/setup +0 -29
- data/examples/rails-4.2.5/bin/spring +0 -15
- data/examples/rails-4.2.5/config.ru +0 -4
- data/examples/rails-4.2.5/config/application.rb +0 -26
- data/examples/rails-4.2.5/config/boot.rb +0 -3
- data/examples/rails-4.2.5/config/database.yml +0 -25
- data/examples/rails-4.2.5/config/environment.rb +0 -5
- data/examples/rails-4.2.5/config/environments/development.rb +0 -41
- data/examples/rails-4.2.5/config/environments/production.rb +0 -79
- data/examples/rails-4.2.5/config/environments/test.rb +0 -42
- data/examples/rails-4.2.5/config/initializers/filter_parameter_logging.rb +0 -4
- data/examples/rails-4.2.5/config/initializers/secret_token.rb +0 -19
- data/examples/rails-4.2.5/config/initializers/wrap_parameters.rb +0 -13
- data/examples/rails-4.2.5/config/locales/en.yml +0 -23
- data/examples/rails-4.2.5/config/routes.rb +0 -60
- data/examples/rails-4.2.5/config/secrets.yml +0 -22
- data/examples/rails-4.2.5/db/migrate/20151119010359_create_users.rb +0 -11
- data/examples/rails-4.2.5/db/migrate/20151119010415_create_posts.rb +0 -11
- data/examples/rails-4.2.5/db/schema.rb +0 -34
- data/examples/rails-4.2.5/db/seeds.rb +0 -7
- data/examples/rails-4.2.5/lib/assets/.keep +0 -0
- data/examples/rails-4.2.5/lib/tasks/.keep +0 -0
- data/examples/rails-4.2.5/log/.keep +0 -0
- data/examples/rails-4.2.5/public/404.html +0 -67
- data/examples/rails-4.2.5/public/422.html +0 -67
- data/examples/rails-4.2.5/public/500.html +0 -66
- data/examples/rails-4.2.5/public/favicon.ico +0 -0
- data/examples/rails-4.2.5/public/robots.txt +0 -5
- data/examples/rails-4.2.5/spec/rails_helper.rb +0 -62
- data/examples/rails-4.2.5/spec/requests/posts_spec.rb +0 -33
- data/examples/rails-4.2.5/spec/requests/users_spec.rb +0 -24
- data/examples/rails-4.2.5/spec/spec_helper.rb +0 -89
- data/examples/rails-4.2.5/tests-doc/README.md +0 -32
- data/examples/rails-4.2.5/tests-doc/api/posts.md +0 -24
- data/examples/rails-4.2.5/tests-doc/api/posts/@id.md +0 -29
- data/examples/rails-4.2.5/tests-doc/api/posts@with-filter.md +0 -25
- data/examples/rails-4.2.5/tests-doc/api/users.md +0 -24
- data/examples/rails-4.2.5/tests-doc/api/users/@id/posts.md +0 -24
- data/examples/rails-5.2.3/.gitignore +0 -31
- data/examples/rails-5.2.3/.ruby-version +0 -1
- data/examples/rails-5.2.3/Gemfile +0 -49
- data/examples/rails-5.2.3/Gemfile.lock +0 -235
- data/examples/rails-5.2.3/README.md +0 -24
- data/examples/rails-5.2.3/Rakefile +0 -6
- data/examples/rails-5.2.3/app/assets/config/manifest.js +0 -3
- data/examples/rails-5.2.3/app/assets/images/.keep +0 -0
- data/examples/rails-5.2.3/app/assets/javascripts/application.js +0 -16
- data/examples/rails-5.2.3/app/assets/javascripts/cable.js +0 -13
- data/examples/rails-5.2.3/app/assets/javascripts/channels/.keep +0 -0
- data/examples/rails-5.2.3/app/assets/javascripts/posts.js +0 -2
- data/examples/rails-5.2.3/app/assets/javascripts/users.js +0 -2
- data/examples/rails-5.2.3/app/assets/stylesheets/application.css +0 -15
- data/examples/rails-5.2.3/app/assets/stylesheets/posts.scss +0 -3
- data/examples/rails-5.2.3/app/assets/stylesheets/users.scss +0 -3
- data/examples/rails-5.2.3/app/channels/application_cable/channel.rb +0 -4
- data/examples/rails-5.2.3/app/channels/application_cable/connection.rb +0 -4
- data/examples/rails-5.2.3/app/controllers/application_controller.rb +0 -2
- data/examples/rails-5.2.3/app/controllers/concerns/.keep +0 -0
- data/examples/rails-5.2.3/app/controllers/posts_controller.rb +0 -61
- data/examples/rails-5.2.3/app/controllers/users_controller.rb +0 -59
- data/examples/rails-5.2.3/app/helpers/application_helper.rb +0 -2
- data/examples/rails-5.2.3/app/helpers/posts_helper.rb +0 -2
- data/examples/rails-5.2.3/app/helpers/users_helper.rb +0 -2
- data/examples/rails-5.2.3/app/jobs/application_job.rb +0 -2
- data/examples/rails-5.2.3/app/mailers/application_mailer.rb +0 -4
- data/examples/rails-5.2.3/app/models/application_record.rb +0 -3
- data/examples/rails-5.2.3/app/models/concerns/.keep +0 -0
- data/examples/rails-5.2.3/app/models/post.rb +0 -3
- data/examples/rails-5.2.3/app/models/user.rb +0 -2
- data/examples/rails-5.2.3/app/views/layouts/application.html.erb +0 -15
- data/examples/rails-5.2.3/app/views/layouts/mailer.html.erb +0 -13
- data/examples/rails-5.2.3/app/views/layouts/mailer.text.erb +0 -1
- data/examples/rails-5.2.3/bin/bundle +0 -3
- data/examples/rails-5.2.3/bin/rails +0 -9
- data/examples/rails-5.2.3/bin/rake +0 -9
- data/examples/rails-5.2.3/bin/setup +0 -36
- data/examples/rails-5.2.3/bin/spring +0 -17
- data/examples/rails-5.2.3/bin/update +0 -31
- data/examples/rails-5.2.3/bin/yarn +0 -11
- data/examples/rails-5.2.3/config.ru +0 -5
- data/examples/rails-5.2.3/config/application.rb +0 -19
- data/examples/rails-5.2.3/config/boot.rb +0 -4
- data/examples/rails-5.2.3/config/cable.yml +0 -10
- data/examples/rails-5.2.3/config/credentials.yml.enc +0 -1
- data/examples/rails-5.2.3/config/database.yml +0 -25
- data/examples/rails-5.2.3/config/environment.rb +0 -5
- data/examples/rails-5.2.3/config/environments/development.rb +0 -61
- data/examples/rails-5.2.3/config/environments/production.rb +0 -94
- data/examples/rails-5.2.3/config/environments/test.rb +0 -46
- data/examples/rails-5.2.3/config/initializers/application_controller_renderer.rb +0 -8
- data/examples/rails-5.2.3/config/initializers/assets.rb +0 -14
- data/examples/rails-5.2.3/config/initializers/backtrace_silencers.rb +0 -7
- data/examples/rails-5.2.3/config/initializers/content_security_policy.rb +0 -25
- data/examples/rails-5.2.3/config/initializers/cookies_serializer.rb +0 -5
- data/examples/rails-5.2.3/config/initializers/filter_parameter_logging.rb +0 -4
- data/examples/rails-5.2.3/config/initializers/inflections.rb +0 -16
- data/examples/rails-5.2.3/config/initializers/mime_types.rb +0 -4
- data/examples/rails-5.2.3/config/initializers/wrap_parameters.rb +0 -14
- data/examples/rails-5.2.3/config/locales/en.yml +0 -33
- data/examples/rails-5.2.3/config/puma.rb +0 -34
- data/examples/rails-5.2.3/config/routes.rb +0 -6
- data/examples/rails-5.2.3/config/spring.rb +0 -6
- data/examples/rails-5.2.3/config/storage.yml +0 -34
- data/examples/rails-5.2.3/db/migrate/20190618211257_create_users.rb +0 -11
- data/examples/rails-5.2.3/db/migrate/20190618211325_create_posts.rb +0 -11
- data/examples/rails-5.2.3/db/schema.rb +0 -32
- data/examples/rails-5.2.3/db/seeds.rb +0 -7
- data/examples/rails-5.2.3/lib/assets/.keep +0 -0
- data/examples/rails-5.2.3/lib/tasks/.keep +0 -0
- data/examples/rails-5.2.3/log/.keep +0 -0
- data/examples/rails-5.2.3/package.json +0 -5
- data/examples/rails-5.2.3/public/404.html +0 -67
- data/examples/rails-5.2.3/public/422.html +0 -67
- data/examples/rails-5.2.3/public/500.html +0 -66
- data/examples/rails-5.2.3/public/apple-touch-icon-precomposed.png +0 -0
- data/examples/rails-5.2.3/public/apple-touch-icon.png +0 -0
- data/examples/rails-5.2.3/public/favicon.ico +0 -0
- data/examples/rails-5.2.3/public/robots.txt +0 -1
- data/examples/rails-5.2.3/spec/rails_helper.rb +0 -62
- data/examples/rails-5.2.3/spec/requests/posts_spec.rb +0 -33
- data/examples/rails-5.2.3/spec/requests/users_spec.rb +0 -24
- data/examples/rails-5.2.3/spec/spec_helper.rb +0 -89
- data/examples/rails-5.2.3/storage/.keep +0 -0
- data/examples/rails-5.2.3/tests-doc/README.md +0 -32
- data/examples/rails-5.2.3/tests-doc/api/posts.md +0 -24
- data/examples/rails-5.2.3/tests-doc/api/posts/@id.md +0 -29
- data/examples/rails-5.2.3/tests-doc/api/posts@with-filter.md +0 -25
- data/examples/rails-5.2.3/tests-doc/api/users.md +0 -24
- data/examples/rails-5.2.3/tests-doc/api/users/@id/posts.md +0 -24
- data/examples/rails-5.2.3/tmp/.keep +0 -0
- data/examples/rails-5.2.3/vendor/.keep +0 -0
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
require 'rails_helper'
|
|
2
|
-
|
|
3
|
-
RSpec.describe "Posts", :type => :request do
|
|
4
|
-
describe "GET /posts" do
|
|
5
|
-
it "renders posts" do
|
|
6
|
-
recording_api_interaction do
|
|
7
|
-
get posts_path
|
|
8
|
-
expect(response.status).to be(200)
|
|
9
|
-
end
|
|
10
|
-
end
|
|
11
|
-
|
|
12
|
-
it "renders posts with filter" do
|
|
13
|
-
recording_api_interaction do |options|
|
|
14
|
-
options.key = 'with-filter'
|
|
15
|
-
get posts_path(published: true)
|
|
16
|
-
expect(response.status).to be(200)
|
|
17
|
-
end
|
|
18
|
-
end
|
|
19
|
-
end
|
|
20
|
-
|
|
21
|
-
describe "GET /posts/:id" do
|
|
22
|
-
it "renders posts with id" do
|
|
23
|
-
User.create
|
|
24
|
-
Post.create(user_id: User.first.id)
|
|
25
|
-
|
|
26
|
-
recording_api_interaction do |options|
|
|
27
|
-
options.path = 'posts/@id'
|
|
28
|
-
get post_path(Post.first.id)
|
|
29
|
-
expect(response.status).to be(200)
|
|
30
|
-
end
|
|
31
|
-
end
|
|
32
|
-
end
|
|
33
|
-
end
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
require 'rails_helper'
|
|
2
|
-
|
|
3
|
-
RSpec.describe "Users", :type => :request do
|
|
4
|
-
describe "GET /users" do
|
|
5
|
-
it "renders users" do
|
|
6
|
-
recording_api_interaction do
|
|
7
|
-
get users_path
|
|
8
|
-
expect(response.status).to be(200)
|
|
9
|
-
end
|
|
10
|
-
end
|
|
11
|
-
end
|
|
12
|
-
|
|
13
|
-
describe "GET /users/:user_id/posts" do
|
|
14
|
-
it "renders posts" do
|
|
15
|
-
User.create
|
|
16
|
-
|
|
17
|
-
recording_api_interaction do |options|
|
|
18
|
-
options.path = 'users/@id/posts'
|
|
19
|
-
get user_posts_path(User.first.id)
|
|
20
|
-
expect(response.status).to be(200)
|
|
21
|
-
end
|
|
22
|
-
end
|
|
23
|
-
end
|
|
24
|
-
end
|
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
# This file was generated by the `rails generate rspec:install` command. Conventionally, all
|
|
2
|
-
# specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
|
|
3
|
-
# The generated `.rspec` file contains `--require spec_helper` which will cause this
|
|
4
|
-
# file to always be loaded, without a need to explicitly require it in any files.
|
|
5
|
-
#
|
|
6
|
-
# Given that it is always loaded, you are encouraged to keep this file as
|
|
7
|
-
# light-weight as possible. Requiring heavyweight dependencies from this file
|
|
8
|
-
# will add to the boot time of your test suite on EVERY test run, even for an
|
|
9
|
-
# individual file that may not need all of that loaded. Instead, make a
|
|
10
|
-
# separate helper file that requires this one and then use it only in the specs
|
|
11
|
-
# that actually need it.
|
|
12
|
-
#
|
|
13
|
-
# The `.rspec` file also contains a few flags that are not defaults but that
|
|
14
|
-
# users commonly want.
|
|
15
|
-
#
|
|
16
|
-
# See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
|
|
17
|
-
RSpec.configure do |config|
|
|
18
|
-
# The settings below are suggested to provide a good initial experience
|
|
19
|
-
# with RSpec, but feel free to customize to your heart's content.
|
|
20
|
-
=begin
|
|
21
|
-
# These two settings work together to allow you to limit a spec run
|
|
22
|
-
# to individual examples or groups you care about by tagging them with
|
|
23
|
-
# `:focus` metadata. When nothing is tagged with `:focus`, all examples
|
|
24
|
-
# get run.
|
|
25
|
-
config.filter_run :focus
|
|
26
|
-
config.run_all_when_everything_filtered = true
|
|
27
|
-
|
|
28
|
-
# Many RSpec users commonly either run the entire suite or an individual
|
|
29
|
-
# file, and it's useful to allow more verbose output when running an
|
|
30
|
-
# individual spec file.
|
|
31
|
-
if config.files_to_run.one?
|
|
32
|
-
# Use the documentation formatter for detailed output,
|
|
33
|
-
# unless a formatter has already been configured
|
|
34
|
-
# (e.g. via a command-line flag).
|
|
35
|
-
config.default_formatter = 'doc'
|
|
36
|
-
end
|
|
37
|
-
|
|
38
|
-
# Print the 10 slowest examples and example groups at the
|
|
39
|
-
# end of the spec run, to help surface which specs are running
|
|
40
|
-
# particularly slow.
|
|
41
|
-
config.profile_examples = 10
|
|
42
|
-
|
|
43
|
-
# Run specs in random order to surface order dependencies. If you find an
|
|
44
|
-
# order dependency and want to debug it, you can fix the order by providing
|
|
45
|
-
# the seed, which is printed after each run.
|
|
46
|
-
# --seed 1234
|
|
47
|
-
config.order = :random
|
|
48
|
-
|
|
49
|
-
# Seed global randomization in this process using the `--seed` CLI option.
|
|
50
|
-
# Setting this allows you to use `--seed` to deterministically reproduce
|
|
51
|
-
# test failures related to randomization by passing the same `--seed` value
|
|
52
|
-
# as the one that triggered the failure.
|
|
53
|
-
Kernel.srand config.seed
|
|
54
|
-
|
|
55
|
-
# rspec-expectations config goes here. You can use an alternate
|
|
56
|
-
# assertion/expectation library such as wrong or the stdlib/minitest
|
|
57
|
-
# assertions if you prefer.
|
|
58
|
-
config.expect_with :rspec do |expectations|
|
|
59
|
-
# Enable only the newer, non-monkey-patching expect syntax.
|
|
60
|
-
# For more details, see:
|
|
61
|
-
# - http://myronmars.to/n/dev-blog/2012/06/rspecs-new-expectation-syntax
|
|
62
|
-
expectations.syntax = :expect
|
|
63
|
-
end
|
|
64
|
-
|
|
65
|
-
# rspec-mocks config goes here. You can use an alternate test double
|
|
66
|
-
# library (such as bogus or mocha) by changing the `mock_with` option here.
|
|
67
|
-
config.mock_with :rspec do |mocks|
|
|
68
|
-
# Enable only the newer, non-monkey-patching expect syntax.
|
|
69
|
-
# For more details, see:
|
|
70
|
-
# - http://teaisaweso.me/blog/2013/05/27/rspecs-new-message-expectation-syntax/
|
|
71
|
-
mocks.syntax = :expect
|
|
72
|
-
|
|
73
|
-
# Prevents you from mocking or stubbing a method that does not exist on
|
|
74
|
-
# a real object. This is generally recommended.
|
|
75
|
-
mocks.verify_partial_doubles = true
|
|
76
|
-
end
|
|
77
|
-
=end
|
|
78
|
-
|
|
79
|
-
config.after :suite do |test|
|
|
80
|
-
# block executed when there is any api interactions were recorded during the rspec
|
|
81
|
-
TestsDoc.with_api_interaction do
|
|
82
|
-
require 'rake'
|
|
83
|
-
require 'tests_doc/tasks'
|
|
84
|
-
|
|
85
|
-
Rake::Task["tests_doc:index:build"].invoke(TestsDoc.configuration.root_folder)
|
|
86
|
-
end
|
|
87
|
-
end
|
|
88
|
-
|
|
89
|
-
end
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
# Api Interactions
|
|
2
|
-
|
|
3
|
-
This document contains a list of api endpoints tested.
|
|
4
|
-
If one of the api endpoint is modified during the test suite if its a deletion,
|
|
5
|
-
make sure this wont affect any of code consuming the api endpoint.
|
|
6
|
-
|
|
7
|
-
Last modified at: 06/18/2019 11:34PM
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
# Endpoints
|
|
11
|
-
|
|
12
|
-
## Api Interactions
|
|
13
|
-
|
|
14
|
-
[/README.md](README.md)
|
|
15
|
-
|
|
16
|
-
## GET posts
|
|
17
|
-
|
|
18
|
-
[/api/posts.md](api/posts.md)
|
|
19
|
-
|
|
20
|
-
[/api/posts@with-filter.md](api/posts@with-filter.md)
|
|
21
|
-
|
|
22
|
-
## GET posts/@id
|
|
23
|
-
|
|
24
|
-
[/api/posts/@id.md](api/posts/@id.md)
|
|
25
|
-
|
|
26
|
-
## GET users
|
|
27
|
-
|
|
28
|
-
[/api/users.md](api/users.md)
|
|
29
|
-
|
|
30
|
-
## GET users/@id/posts
|
|
31
|
-
|
|
32
|
-
[/api/users/@id/posts.md](api/users/@id/posts.md)
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
# GET posts
|
|
2
|
-
|
|
3
|
-
Rspec description: Posts GET /posts renders posts
|
|
4
|
-
|
|
5
|
-
[spec/requests/posts_spec.rb:5](/spec/requests/posts_spec.rb#L5)
|
|
6
|
-
|
|
7
|
-
# Parameters
|
|
8
|
-
|
|
9
|
-
```json
|
|
10
|
-
{
|
|
11
|
-
}
|
|
12
|
-
```
|
|
13
|
-
|
|
14
|
-
# Response
|
|
15
|
-
|
|
16
|
-
```
|
|
17
|
-
HTTP CODE = 200
|
|
18
|
-
```
|
|
19
|
-
|
|
20
|
-
```json
|
|
21
|
-
[
|
|
22
|
-
|
|
23
|
-
]
|
|
24
|
-
```
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
# GET posts/@id
|
|
2
|
-
|
|
3
|
-
Rspec description: Posts GET /posts/:id renders posts with id
|
|
4
|
-
|
|
5
|
-
[spec/requests/posts_spec.rb:22](/spec/requests/posts_spec.rb#L22)
|
|
6
|
-
|
|
7
|
-
# Parameters
|
|
8
|
-
|
|
9
|
-
```json
|
|
10
|
-
{
|
|
11
|
-
}
|
|
12
|
-
```
|
|
13
|
-
|
|
14
|
-
# Response
|
|
15
|
-
|
|
16
|
-
```
|
|
17
|
-
HTTP CODE = 200
|
|
18
|
-
```
|
|
19
|
-
|
|
20
|
-
```json
|
|
21
|
-
{
|
|
22
|
-
"id": 1,
|
|
23
|
-
"title": null,
|
|
24
|
-
"body": null,
|
|
25
|
-
"user_id": 1,
|
|
26
|
-
"created_at": "2019-06-18T21:34:32.172Z",
|
|
27
|
-
"updated_at": "2019-06-18T21:34:32.172Z"
|
|
28
|
-
}
|
|
29
|
-
```
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
# GET posts
|
|
2
|
-
|
|
3
|
-
Rspec description: Posts GET /posts renders posts with filter
|
|
4
|
-
|
|
5
|
-
[spec/requests/posts_spec.rb:12](/spec/requests/posts_spec.rb#L12)
|
|
6
|
-
|
|
7
|
-
# Parameters
|
|
8
|
-
|
|
9
|
-
```json
|
|
10
|
-
{
|
|
11
|
-
"published": "true"
|
|
12
|
-
}
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
# Response
|
|
16
|
-
|
|
17
|
-
```
|
|
18
|
-
HTTP CODE = 200
|
|
19
|
-
```
|
|
20
|
-
|
|
21
|
-
```json
|
|
22
|
-
[
|
|
23
|
-
|
|
24
|
-
]
|
|
25
|
-
```
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
# GET users
|
|
2
|
-
|
|
3
|
-
Rspec description: Users GET /users renders users
|
|
4
|
-
|
|
5
|
-
[spec/requests/users_spec.rb:5](/spec/requests/users_spec.rb#L5)
|
|
6
|
-
|
|
7
|
-
# Parameters
|
|
8
|
-
|
|
9
|
-
```json
|
|
10
|
-
{
|
|
11
|
-
}
|
|
12
|
-
```
|
|
13
|
-
|
|
14
|
-
# Response
|
|
15
|
-
|
|
16
|
-
```
|
|
17
|
-
HTTP CODE = 200
|
|
18
|
-
```
|
|
19
|
-
|
|
20
|
-
```json
|
|
21
|
-
[
|
|
22
|
-
|
|
23
|
-
]
|
|
24
|
-
```
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
# GET users/@id/posts
|
|
2
|
-
|
|
3
|
-
Rspec description: Users GET /users/:user_id/posts renders posts
|
|
4
|
-
|
|
5
|
-
[spec/requests/users_spec.rb:14](/spec/requests/users_spec.rb#L14)
|
|
6
|
-
|
|
7
|
-
# Parameters
|
|
8
|
-
|
|
9
|
-
```json
|
|
10
|
-
{
|
|
11
|
-
}
|
|
12
|
-
```
|
|
13
|
-
|
|
14
|
-
# Response
|
|
15
|
-
|
|
16
|
-
```
|
|
17
|
-
HTTP CODE = 200
|
|
18
|
-
```
|
|
19
|
-
|
|
20
|
-
```json
|
|
21
|
-
[
|
|
22
|
-
|
|
23
|
-
]
|
|
24
|
-
```
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
# See https://help.github.com/articles/ignoring-files for more about ignoring files.
|
|
2
|
-
#
|
|
3
|
-
# If you find yourself ignoring temporary files generated by your text editor
|
|
4
|
-
# or operating system, you probably want to add a global ignore instead:
|
|
5
|
-
# git config --global core.excludesfile '~/.gitignore_global'
|
|
6
|
-
|
|
7
|
-
# Ignore bundler config.
|
|
8
|
-
/.bundle
|
|
9
|
-
|
|
10
|
-
# Ignore the default SQLite database.
|
|
11
|
-
/db/*.sqlite3
|
|
12
|
-
/db/*.sqlite3-journal
|
|
13
|
-
|
|
14
|
-
# Ignore all logfiles and tempfiles.
|
|
15
|
-
/log/*
|
|
16
|
-
/tmp/*
|
|
17
|
-
!/log/.keep
|
|
18
|
-
!/tmp/.keep
|
|
19
|
-
|
|
20
|
-
# Ignore uploaded files in development
|
|
21
|
-
/storage/*
|
|
22
|
-
!/storage/.keep
|
|
23
|
-
|
|
24
|
-
/node_modules
|
|
25
|
-
/yarn-error.log
|
|
26
|
-
|
|
27
|
-
/public/assets
|
|
28
|
-
.byebug_history
|
|
29
|
-
|
|
30
|
-
# Ignore master key for decrypting credentials and more.
|
|
31
|
-
/config/master.key
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
2.3.4
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
source 'https://rubygems.org'
|
|
2
|
-
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
|
|
3
|
-
|
|
4
|
-
ruby '2.3.4'
|
|
5
|
-
|
|
6
|
-
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
|
|
7
|
-
gem 'rails', '~> 5.2.3'
|
|
8
|
-
|
|
9
|
-
# Use sqlite3 as the database for Active Record
|
|
10
|
-
gem 'sqlite3'
|
|
11
|
-
|
|
12
|
-
# Use Puma as the app server
|
|
13
|
-
gem 'puma', '~> 3.11'
|
|
14
|
-
|
|
15
|
-
# Use SCSS for stylesheets
|
|
16
|
-
gem 'sass-rails', '~> 5.0'
|
|
17
|
-
|
|
18
|
-
# Use Uglifier as compressor for JavaScript assets
|
|
19
|
-
gem 'uglifier', '>= 1.3.0'
|
|
20
|
-
|
|
21
|
-
# Reduces boot times through caching; required in config/boot.rb
|
|
22
|
-
gem 'bootsnap', '>= 1.1.0', require: false
|
|
23
|
-
|
|
24
|
-
group :development, :test do
|
|
25
|
-
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
|
|
26
|
-
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
|
|
27
|
-
gem 'rspec-rails', '~> 3.4'
|
|
28
|
-
end
|
|
29
|
-
|
|
30
|
-
group :development do
|
|
31
|
-
# Access an interactive console on exception pages or by calling 'console' anywhere in the code.
|
|
32
|
-
gem 'web-console', '>= 3.3.0'
|
|
33
|
-
gem 'listen', '>= 3.0.5', '< 3.2'
|
|
34
|
-
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
|
|
35
|
-
gem 'spring'
|
|
36
|
-
gem 'spring-watcher-listen', '~> 2.0.0'
|
|
37
|
-
end
|
|
38
|
-
|
|
39
|
-
group :test do
|
|
40
|
-
# Adds support for Capybara system testing and selenium driver
|
|
41
|
-
gem 'capybara', '>= 2.15'
|
|
42
|
-
gem 'selenium-webdriver'
|
|
43
|
-
# Easy installation and use of chromedriver to run system tests with Chrome
|
|
44
|
-
gem 'chromedriver-helper'
|
|
45
|
-
gem 'tests_doc', path: '../../../tests_doc', :group => :test
|
|
46
|
-
end
|
|
47
|
-
|
|
48
|
-
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
|
|
49
|
-
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
|
|
@@ -1,235 +0,0 @@
|
|
|
1
|
-
PATH
|
|
2
|
-
remote: ../..
|
|
3
|
-
specs:
|
|
4
|
-
tests_doc (0.0.4)
|
|
5
|
-
rails (>= 4)
|
|
6
|
-
rspec (>= 2.0)
|
|
7
|
-
rspec-rails (>= 2.0)
|
|
8
|
-
|
|
9
|
-
GEM
|
|
10
|
-
remote: https://rubygems.org/
|
|
11
|
-
specs:
|
|
12
|
-
actioncable (5.2.3)
|
|
13
|
-
actionpack (= 5.2.3)
|
|
14
|
-
nio4r (~> 2.0)
|
|
15
|
-
websocket-driver (>= 0.6.1)
|
|
16
|
-
actionmailer (5.2.3)
|
|
17
|
-
actionpack (= 5.2.3)
|
|
18
|
-
actionview (= 5.2.3)
|
|
19
|
-
activejob (= 5.2.3)
|
|
20
|
-
mail (~> 2.5, >= 2.5.4)
|
|
21
|
-
rails-dom-testing (~> 2.0)
|
|
22
|
-
actionpack (5.2.3)
|
|
23
|
-
actionview (= 5.2.3)
|
|
24
|
-
activesupport (= 5.2.3)
|
|
25
|
-
rack (~> 2.0)
|
|
26
|
-
rack-test (>= 0.6.3)
|
|
27
|
-
rails-dom-testing (~> 2.0)
|
|
28
|
-
rails-html-sanitizer (~> 1.0, >= 1.0.2)
|
|
29
|
-
actionview (5.2.3)
|
|
30
|
-
activesupport (= 5.2.3)
|
|
31
|
-
builder (~> 3.1)
|
|
32
|
-
erubi (~> 1.4)
|
|
33
|
-
rails-dom-testing (~> 2.0)
|
|
34
|
-
rails-html-sanitizer (~> 1.0, >= 1.0.3)
|
|
35
|
-
activejob (5.2.3)
|
|
36
|
-
activesupport (= 5.2.3)
|
|
37
|
-
globalid (>= 0.3.6)
|
|
38
|
-
activemodel (5.2.3)
|
|
39
|
-
activesupport (= 5.2.3)
|
|
40
|
-
activerecord (5.2.3)
|
|
41
|
-
activemodel (= 5.2.3)
|
|
42
|
-
activesupport (= 5.2.3)
|
|
43
|
-
arel (>= 9.0)
|
|
44
|
-
activestorage (5.2.3)
|
|
45
|
-
actionpack (= 5.2.3)
|
|
46
|
-
activerecord (= 5.2.3)
|
|
47
|
-
marcel (~> 0.3.1)
|
|
48
|
-
activesupport (5.2.3)
|
|
49
|
-
concurrent-ruby (~> 1.0, >= 1.0.2)
|
|
50
|
-
i18n (>= 0.7, < 2)
|
|
51
|
-
minitest (~> 5.1)
|
|
52
|
-
tzinfo (~> 1.1)
|
|
53
|
-
addressable (2.6.0)
|
|
54
|
-
public_suffix (>= 2.0.2, < 4.0)
|
|
55
|
-
archive-zip (0.12.0)
|
|
56
|
-
io-like (~> 0.3.0)
|
|
57
|
-
arel (9.0.0)
|
|
58
|
-
bindex (0.7.0)
|
|
59
|
-
bootsnap (1.4.4)
|
|
60
|
-
msgpack (~> 1.0)
|
|
61
|
-
builder (3.2.3)
|
|
62
|
-
byebug (11.0.1)
|
|
63
|
-
capybara (3.15.1)
|
|
64
|
-
addressable
|
|
65
|
-
mini_mime (>= 0.1.3)
|
|
66
|
-
nokogiri (~> 1.8)
|
|
67
|
-
rack (>= 1.6.0)
|
|
68
|
-
rack-test (>= 0.6.3)
|
|
69
|
-
regexp_parser (~> 1.2)
|
|
70
|
-
xpath (~> 3.2)
|
|
71
|
-
childprocess (1.0.1)
|
|
72
|
-
rake (< 13.0)
|
|
73
|
-
chromedriver-helper (2.1.1)
|
|
74
|
-
archive-zip (~> 0.10)
|
|
75
|
-
nokogiri (~> 1.8)
|
|
76
|
-
concurrent-ruby (1.1.5)
|
|
77
|
-
crass (1.0.4)
|
|
78
|
-
diff-lcs (1.3)
|
|
79
|
-
erubi (1.8.0)
|
|
80
|
-
execjs (2.7.0)
|
|
81
|
-
ffi (1.11.1)
|
|
82
|
-
globalid (0.4.2)
|
|
83
|
-
activesupport (>= 4.2.0)
|
|
84
|
-
i18n (1.6.0)
|
|
85
|
-
concurrent-ruby (~> 1.0)
|
|
86
|
-
io-like (0.3.0)
|
|
87
|
-
listen (3.1.5)
|
|
88
|
-
rb-fsevent (~> 0.9, >= 0.9.4)
|
|
89
|
-
rb-inotify (~> 0.9, >= 0.9.7)
|
|
90
|
-
ruby_dep (~> 1.2)
|
|
91
|
-
loofah (2.2.3)
|
|
92
|
-
crass (~> 1.0.2)
|
|
93
|
-
nokogiri (>= 1.5.9)
|
|
94
|
-
mail (2.7.1)
|
|
95
|
-
mini_mime (>= 0.1.1)
|
|
96
|
-
marcel (0.3.3)
|
|
97
|
-
mimemagic (~> 0.3.2)
|
|
98
|
-
method_source (0.9.2)
|
|
99
|
-
mimemagic (0.3.3)
|
|
100
|
-
mini_mime (1.0.1)
|
|
101
|
-
mini_portile2 (2.4.0)
|
|
102
|
-
minitest (5.11.3)
|
|
103
|
-
msgpack (1.2.10)
|
|
104
|
-
nio4r (2.3.1)
|
|
105
|
-
nokogiri (1.10.3)
|
|
106
|
-
mini_portile2 (~> 2.4.0)
|
|
107
|
-
public_suffix (3.1.0)
|
|
108
|
-
puma (3.12.1)
|
|
109
|
-
rack (2.0.7)
|
|
110
|
-
rack-test (1.1.0)
|
|
111
|
-
rack (>= 1.0, < 3)
|
|
112
|
-
rails (5.2.3)
|
|
113
|
-
actioncable (= 5.2.3)
|
|
114
|
-
actionmailer (= 5.2.3)
|
|
115
|
-
actionpack (= 5.2.3)
|
|
116
|
-
actionview (= 5.2.3)
|
|
117
|
-
activejob (= 5.2.3)
|
|
118
|
-
activemodel (= 5.2.3)
|
|
119
|
-
activerecord (= 5.2.3)
|
|
120
|
-
activestorage (= 5.2.3)
|
|
121
|
-
activesupport (= 5.2.3)
|
|
122
|
-
bundler (>= 1.3.0)
|
|
123
|
-
railties (= 5.2.3)
|
|
124
|
-
sprockets-rails (>= 2.0.0)
|
|
125
|
-
rails-dom-testing (2.0.3)
|
|
126
|
-
activesupport (>= 4.2.0)
|
|
127
|
-
nokogiri (>= 1.6)
|
|
128
|
-
rails-html-sanitizer (1.0.4)
|
|
129
|
-
loofah (~> 2.2, >= 2.2.2)
|
|
130
|
-
railties (5.2.3)
|
|
131
|
-
actionpack (= 5.2.3)
|
|
132
|
-
activesupport (= 5.2.3)
|
|
133
|
-
method_source
|
|
134
|
-
rake (>= 0.8.7)
|
|
135
|
-
thor (>= 0.19.0, < 2.0)
|
|
136
|
-
rake (12.3.2)
|
|
137
|
-
rb-fsevent (0.10.3)
|
|
138
|
-
rb-inotify (0.10.0)
|
|
139
|
-
ffi (~> 1.0)
|
|
140
|
-
regexp_parser (1.5.1)
|
|
141
|
-
rspec (3.8.0)
|
|
142
|
-
rspec-core (~> 3.8.0)
|
|
143
|
-
rspec-expectations (~> 3.8.0)
|
|
144
|
-
rspec-mocks (~> 3.8.0)
|
|
145
|
-
rspec-core (3.8.1)
|
|
146
|
-
rspec-support (~> 3.8.0)
|
|
147
|
-
rspec-expectations (3.8.4)
|
|
148
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
|
149
|
-
rspec-support (~> 3.8.0)
|
|
150
|
-
rspec-mocks (3.8.1)
|
|
151
|
-
diff-lcs (>= 1.2.0, < 2.0)
|
|
152
|
-
rspec-support (~> 3.8.0)
|
|
153
|
-
rspec-rails (3.8.2)
|
|
154
|
-
actionpack (>= 3.0)
|
|
155
|
-
activesupport (>= 3.0)
|
|
156
|
-
railties (>= 3.0)
|
|
157
|
-
rspec-core (~> 3.8.0)
|
|
158
|
-
rspec-expectations (~> 3.8.0)
|
|
159
|
-
rspec-mocks (~> 3.8.0)
|
|
160
|
-
rspec-support (~> 3.8.0)
|
|
161
|
-
rspec-support (3.8.2)
|
|
162
|
-
ruby_dep (1.5.0)
|
|
163
|
-
rubyzip (1.2.3)
|
|
164
|
-
sass (3.7.4)
|
|
165
|
-
sass-listen (~> 4.0.0)
|
|
166
|
-
sass-listen (4.0.0)
|
|
167
|
-
rb-fsevent (~> 0.9, >= 0.9.4)
|
|
168
|
-
rb-inotify (~> 0.9, >= 0.9.7)
|
|
169
|
-
sass-rails (5.0.7)
|
|
170
|
-
railties (>= 4.0.0, < 6)
|
|
171
|
-
sass (~> 3.1)
|
|
172
|
-
sprockets (>= 2.8, < 4.0)
|
|
173
|
-
sprockets-rails (>= 2.0, < 4.0)
|
|
174
|
-
tilt (>= 1.1, < 3)
|
|
175
|
-
selenium-webdriver (3.142.3)
|
|
176
|
-
childprocess (>= 0.5, < 2.0)
|
|
177
|
-
rubyzip (~> 1.2, >= 1.2.2)
|
|
178
|
-
spring (2.0.2)
|
|
179
|
-
activesupport (>= 4.2)
|
|
180
|
-
spring-watcher-listen (2.0.1)
|
|
181
|
-
listen (>= 2.7, < 4.0)
|
|
182
|
-
spring (>= 1.2, < 3.0)
|
|
183
|
-
sprockets (3.7.2)
|
|
184
|
-
concurrent-ruby (~> 1.0)
|
|
185
|
-
rack (> 1, < 3)
|
|
186
|
-
sprockets-rails (3.2.1)
|
|
187
|
-
actionpack (>= 4.0)
|
|
188
|
-
activesupport (>= 4.0)
|
|
189
|
-
sprockets (>= 3.0.0)
|
|
190
|
-
sqlite3 (1.4.1)
|
|
191
|
-
thor (0.20.3)
|
|
192
|
-
thread_safe (0.3.6)
|
|
193
|
-
tilt (2.0.9)
|
|
194
|
-
tzinfo (1.2.5)
|
|
195
|
-
thread_safe (~> 0.1)
|
|
196
|
-
uglifier (4.1.20)
|
|
197
|
-
execjs (>= 0.3.0, < 3)
|
|
198
|
-
web-console (3.7.0)
|
|
199
|
-
actionview (>= 5.0)
|
|
200
|
-
activemodel (>= 5.0)
|
|
201
|
-
bindex (>= 0.4.0)
|
|
202
|
-
railties (>= 5.0)
|
|
203
|
-
websocket-driver (0.7.1)
|
|
204
|
-
websocket-extensions (>= 0.1.0)
|
|
205
|
-
websocket-extensions (0.1.4)
|
|
206
|
-
xpath (3.2.0)
|
|
207
|
-
nokogiri (~> 1.8)
|
|
208
|
-
|
|
209
|
-
PLATFORMS
|
|
210
|
-
ruby
|
|
211
|
-
|
|
212
|
-
DEPENDENCIES
|
|
213
|
-
bootsnap (>= 1.1.0)
|
|
214
|
-
byebug
|
|
215
|
-
capybara (>= 2.15)
|
|
216
|
-
chromedriver-helper
|
|
217
|
-
listen (>= 3.0.5, < 3.2)
|
|
218
|
-
puma (~> 3.11)
|
|
219
|
-
rails (~> 5.2.3)
|
|
220
|
-
rspec-rails (~> 3.4)
|
|
221
|
-
sass-rails (~> 5.0)
|
|
222
|
-
selenium-webdriver
|
|
223
|
-
spring
|
|
224
|
-
spring-watcher-listen (~> 2.0.0)
|
|
225
|
-
sqlite3
|
|
226
|
-
tests_doc!
|
|
227
|
-
tzinfo-data
|
|
228
|
-
uglifier (>= 1.3.0)
|
|
229
|
-
web-console (>= 3.3.0)
|
|
230
|
-
|
|
231
|
-
RUBY VERSION
|
|
232
|
-
ruby 2.3.4p301
|
|
233
|
-
|
|
234
|
-
BUNDLED WITH
|
|
235
|
-
1.17.3
|