solid-process 0.2.0 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d4b6ab233b8f225123d7a74114c281011f94f7a186faeaee54b3d25e9ba51c2e
4
- data.tar.gz: 57a1de84e07d74971640ce4c03b1e12812d1da7765eb83b6ebb460e92972d1bb
3
+ metadata.gz: e3b27456b398dffc893e5034953dcb74baa2406beeafd8d88f1be31c26611d90
4
+ data.tar.gz: ac372ee023cc5730e80d00951dda408634efdcc0d25322406d4fe37c85313edf
5
5
  SHA512:
6
- metadata.gz: 378aff92aaacc388198e4c72a5ce0fb72df788b1dd7763d2b0f11024629c8988d95e4e52015393dddd4cfbd1116539f1c6f5e1a541422e296117a27e7a7e778b
7
- data.tar.gz: 0040c63c885ff1177dd11c864d208a64c2b46dec1bee9bf71ea2e7df5ac2340668ac8e524c848c30b736457c3a64051e0084e01c3d401cf3bbaf1293959e6764
6
+ metadata.gz: '09a4852a76e0e47ef0b3dd02554805647d33b500efb939cc1221f1ff48d538220db9ffa426df2774855d5a014a7de49d28e9e3e7660aca8bab4e12aa85286214'
7
+ data.tar.gz: 2074bc2fef703376047a43e273e138ec038dba78b228a5ec14655351954ecf5b5ad71e50a306480b0dda37d85c6b60920bff0a210581507469709ba52817c0f8
data/CHANGELOG.md CHANGED
@@ -1,5 +1,7 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.3.0] - 2024-04-14
4
+
3
5
  ## [0.2.0] - 2024-03-18
4
6
 
5
7
  ## [0.1.0] - 2024-03-16
data/README.md CHANGED
@@ -1,9 +1,9 @@
1
1
  <p align="center">
2
2
  <h1 align="center" id="-solidprocess">🚄 Solid::Process</h1>
3
- <p align="center"><i>Ruby on Rails + Business Processes</i></p>
3
+ <p align="center"><i>Write self-documenting and self-observable business processes in Ruby/Rails.</i></p>
4
4
  <p align="center">
5
- <a href="https://codeclimate.com/github/serradura/solid-process/maintainability"><img src="https://api.codeclimate.com/v1/badges/643a53e99bb591321c9f/maintainability" /></a>
6
- <a href="https://codeclimate.com/github/serradura/solid-process/test_coverage"><img src="https://api.codeclimate.com/v1/badges/643a53e99bb591321c9f/test_coverage" /></a>
5
+ <a href="https://codeclimate.com/github/solid-process/solid-process/maintainability"><img src="https://api.codeclimate.com/v1/badges/643a53e99bb591321c9f/maintainability" /></a>
6
+ <a href="https://codeclimate.com/github/solid-process/solid-process/test_coverage"><img src="https://api.codeclimate.com/v1/badges/643a53e99bb591321c9f/test_coverage" /></a>
7
7
  <img src="https://img.shields.io/badge/Ruby%20%3E%3D%202.7%2C%20%3C%3D%20Head-ruby.svg?colorA=444&colorB=333" alt="Ruby">
8
8
  <img src="https://img.shields.io/badge/Rails%20%3E%3D%206.0%2C%20%3C%3D%20Edge-rails.svg?colorA=444&colorB=333" alt="Rails">
9
9
  </p>
@@ -54,7 +54,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
54
54
 
55
55
  ## Contributing
56
56
 
57
- Bug reports and pull requests are welcome on GitHub at https://github.com/serradura/solid-process. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/serradura/solid-process/blob/master/CODE_OF_CONDUCT.md).
57
+ Bug reports and pull requests are welcome on GitHub at https://github.com/solid-process/solid-process. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/solid-process/solid-process/blob/main/CODE_OF_CONDUCT.md).
58
58
 
59
59
  ## License
60
60
 
@@ -62,4 +62,4 @@ The gem is available as open source under the terms of the [MIT License](https:/
62
62
 
63
63
  ## Code of Conduct
64
64
 
65
- Everyone interacting in the Solid::Process project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/serradura/solid-process/blob/master/CODE_OF_CONDUCT.md).
65
+ Everyone interacting in the Solid::Process project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/solid-process/solid-process/blob/main/CODE_OF_CONDUCT.md).
@@ -9,7 +9,7 @@ class Solid::Process
9
9
  self.input = arg
10
10
 
11
11
  run_callbacks(:call) do
12
- ::BCDD::Result.event_logs(name: self.class.name) do
12
+ ::Solid::Result.event_logs(name: self.class.name) do
13
13
  self.output =
14
14
  if dependencies&.invalid?
15
15
  Failure(:invalid_dependencies, dependencies: dependencies)
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Solid
4
4
  class Process
5
- VERSION = "0.2.0"
5
+ VERSION = "0.3.0"
6
6
  end
7
7
  end
data/lib/solid/process.rb CHANGED
@@ -2,11 +2,18 @@
2
2
 
3
3
  require "active_support/all"
4
4
  require "active_model"
5
- require "bcdd/result"
5
+ require "solid/result"
6
6
 
7
7
  module Solid
8
8
  require "solid/input"
9
- require "solid/result"
9
+
10
+ def self.Success(...)
11
+ ::Solid::Output::Success(...)
12
+ end
13
+
14
+ def self.Failure(...)
15
+ ::Solid::Output::Failure(...)
16
+ end
10
17
 
11
18
  class Process
12
19
  require "solid/process/version"
@@ -21,7 +28,7 @@ module Solid
21
28
 
22
29
  include Callbacks
23
30
  include ::ActiveSupport::Rescuable
24
- include ::BCDD::Context.mixin(config: {addon: {continue: true}})
31
+ include ::Solid::Output.mixin(config: {addon: {continue: true}})
25
32
 
26
33
  def self.inherited(subclass)
27
34
  super
@@ -120,7 +127,7 @@ module Solid
120
127
  def output=(result)
121
128
  output_already_set! unless output.nil?
122
129
 
123
- raise Error, "The result #{result.inspect} must be a BCDD::Context." unless result.is_a?(::BCDD::Context)
130
+ raise Error, "The result #{result.inspect} must be a Solid::Output." unless result.is_a?(::Solid::Output)
124
131
 
125
132
  @output = result
126
133
  end
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solid-process
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rodrigo Serradura
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-03-19 00:00:00.000000000 Z
11
+ date: 2024-04-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: bcdd-result
14
+ name: solid-result
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.0'
19
+ version: '2.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.0'
26
+ version: '2.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: activemodel
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -58,7 +58,7 @@ dependencies:
58
58
  - - "~>"
59
59
  - !ruby/object:Gem::Version
60
60
  version: '2.5'
61
- description: Ruby on Rails + Business Processes
61
+ description: Write self-documenting and self-observable business processes in Ruby/Rails.
62
62
  email:
63
63
  - rodrigo.serradura@gmail.com
64
64
  executables: []
@@ -95,7 +95,6 @@ files:
95
95
  - lib/solid/process/config.rb
96
96
  - lib/solid/process/error.rb
97
97
  - lib/solid/process/version.rb
98
- - lib/solid/result.rb
99
98
  - lib/solid/validators/all.rb
100
99
  - lib/solid/validators/bool_validator.rb
101
100
  - lib/solid/validators/email_validator.rb
@@ -132,5 +131,5 @@ requirements: []
132
131
  rubygems_version: 3.1.6
133
132
  signing_key:
134
133
  specification_version: 4
135
- summary: Ruby on Rails + Business Processes
134
+ summary: Write self-documenting and self-observable business processes in Ruby/Rails.
136
135
  test_files: []
data/lib/solid/result.rb DELETED
@@ -1,17 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Solid
4
- Output = ::BCDD::Context
5
-
6
- Result = ::BCDD::Context
7
- Success = Result::Success
8
- Failure = Result::Failure
9
-
10
- def self.Success(...)
11
- Result::Success(...)
12
- end
13
-
14
- def self.Failure(...)
15
- Result::Failure(...)
16
- end
17
- end