rasti-model 2.0.0 → 2.0.1
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/.github/workflows/ci.yml +26 -0
- data/README.md +1 -1
- data/lib/rasti/model/attribute.rb +4 -0
- data/lib/rasti/model/version.rb +1 -1
- data/spec/model_spec.rb +10 -0
- metadata +3 -3
- data/.travis.yml +0 -20
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cd4831ac82eadc7515e4103a10fe010346ec8719d16db0d30103a713b5cd15ef
|
4
|
+
data.tar.gz: b363b3bb323dbb5d1eec404e6adb7c3eef6d6673b0a19474d467a40551f280f8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2e0659afca7e7f8a38731ea5901029f4f346895f357430970eba5f251745e2ceaa765ac9731e47c03a7504e2d66d9fccf57e08ea7f58230fabab8c86ca3e2962
|
7
|
+
data.tar.gz: aabf1480e4bd1b45c6cde754775714047beff31d89a571fb1b617f4aa4f174a65b922fecd8ddcd90ee3b2acaedf5e3aae70a63d33ddfdcbdde41bbe35fcb8fc9
|
@@ -0,0 +1,26 @@
|
|
1
|
+
name: CI
|
2
|
+
|
3
|
+
on:
|
4
|
+
push:
|
5
|
+
branches: [ '**' ]
|
6
|
+
pull_request:
|
7
|
+
branches: [ '**' ]
|
8
|
+
|
9
|
+
jobs:
|
10
|
+
test:
|
11
|
+
|
12
|
+
name: Tests
|
13
|
+
runs-on: ubuntu-22.04
|
14
|
+
strategy:
|
15
|
+
matrix:
|
16
|
+
ruby-version: ['2.3', '2.4', '2.5', '2.6', '2.7', '3.0', 'jruby-9.2.9.0']
|
17
|
+
|
18
|
+
steps:
|
19
|
+
- uses: actions/checkout@v3
|
20
|
+
- name: Set up Ruby
|
21
|
+
uses: ruby/setup-ruby@v1
|
22
|
+
with:
|
23
|
+
ruby-version: ${{ matrix.ruby-version }}
|
24
|
+
bundler-cache: true
|
25
|
+
- name: Run tests
|
26
|
+
run: bundle exec rake
|
data/README.md
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# Rasti::Model
|
2
2
|
|
3
3
|
[](https://rubygems.org/gems/rasti-model)
|
4
|
-
[](https://github.com/gabynaiman/rasti-model/actions/workflows/ci.yml)
|
5
5
|
[](https://coveralls.io/github/gabynaiman/rasti-model?branch=master)
|
6
6
|
[](https://codeclimate.com/github/gabynaiman/rasti-model)
|
7
7
|
|
data/lib/rasti/model/version.rb
CHANGED
data/spec/model_spec.rb
CHANGED
@@ -257,6 +257,16 @@ describe Rasti::Model do
|
|
257
257
|
point_2.y.must_equal 2
|
258
258
|
end
|
259
259
|
|
260
|
+
it 'Custom attribute options' do
|
261
|
+
model = Class.new(Rasti::Model) do
|
262
|
+
attribute :text, T::String, description: 'Test description'
|
263
|
+
end
|
264
|
+
|
265
|
+
attribute = model.attributes.first
|
266
|
+
attribute.option(:description).must_equal 'Test description'
|
267
|
+
attribute.option(:undefined).must_be_nil
|
268
|
+
end
|
269
|
+
|
260
270
|
it 'to_s' do
|
261
271
|
Position.to_s.must_equal 'Position[type, point]'
|
262
272
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rasti-model
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gabriel Naiman
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2025-04-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: multi_require
|
@@ -150,10 +150,10 @@ extensions: []
|
|
150
150
|
extra_rdoc_files: []
|
151
151
|
files:
|
152
152
|
- ".coveralls.yml"
|
153
|
+
- ".github/workflows/ci.yml"
|
153
154
|
- ".gitignore"
|
154
155
|
- ".ruby-gemset"
|
155
156
|
- ".ruby-version"
|
156
|
-
- ".travis.yml"
|
157
157
|
- Gemfile
|
158
158
|
- LICENSE.txt
|
159
159
|
- README.md
|
data/.travis.yml
DELETED