lita-vaxcalc 0.1.0 → 0.2.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cb350de7fa812526ab581f48bd8f8957809fbe5389498adbfa19407a9ecacfe5
4
- data.tar.gz: 94751ae28549811c0dd60ac06c76e65b054459de3d3134af9867d0da937183b9
3
+ metadata.gz: 6bd7fdb0b647f0df06fbbf6444445cbdc3dc8a2479afcef308a413102ddf4203
4
+ data.tar.gz: 7666268e735ee5c9edd1e5f52d1ee7a5817f13e79d4b4d9b6ebb3be70b97197c
5
5
  SHA512:
6
- metadata.gz: 4e4a01d5a2287952bf0aeab6cb8d072b0ac05e55a4d293e91ae1d179233d3c7551d5431bef03ecd3e7bd69a3c99ae98c46048c1277f6914ed06d817b41e796f2
7
- data.tar.gz: 8869c9c690d893b4a4e3e0a036a4c71283612ecd91deca4cfa8a5b62fa23dbf2830924cb9038c1931d4933a9466cff0eed0aa4479efcf84b6ec945c8048af39a
6
+ metadata.gz: 2c2331a2ce8e47418eef248ea29e0ffaa864ffb9e67e31bcd9e516511b93ed8f0238366ced7dbf8a3d551061ac3b5eac879d2c3c6e3a221bdb45ffa65b05cef9
7
+ data.tar.gz: eb1b23c7c1a51c8d3460cec4899f69ce15252c41e05de9a183b30e30d0e59b38f5b7dfa4286941fea5b92c92c06a3dd31336ccd571460a66312b0e7f5daa17fd
data/.travis.yml CHANGED
@@ -1,11 +1,19 @@
1
1
  language: ruby
2
2
  rvm:
3
- - 2.5.3
4
- script: bundle exec rake
3
+ - 2.5.3
5
4
  before_install:
6
- - gem update --system
7
- - gem install bundler -v '2.0.2'
5
+ - gem update --system
6
+ - gem install bundler -v '2.0.2'
8
7
  install:
9
- - bundle install
8
+ - bundle install
10
9
  services:
11
- - redis-server
10
+ - redis-server
11
+ addons:
12
+ sonarcloud:
13
+ organization: "yenwod"
14
+ token:
15
+ secure: F7ApWhoOlwMxN+NlEVzKQQGPX/lhPTnJMmAbtcC7rERSNUEp0R/D1+oUdA70mGyezMhP/Ej9fmq98FIwMbJnu0VRqQk+fgUI3oPiOrMhm+x73n6qpRD4vnx9ripxr6AJ65OK71fgTctBKIFHGm2/5YCmX7NZsQfG9hyXBy2LpTHiqdCNvGQrYs4oiKE39xV4Xayq4r0zyEdQ/Z2JBwwDOmRRlAbzZcVcyO8h1v2D2ocUuN5kfthiYz6q/YeOdu5oD9q6J45tiXCBcd9mZ3So6EcgxSeecig0nVR2WVW3hmFoD8YgX8DlnSt7vs1q0gtVemdRxRdjKt9rtEC0qCbBpfWfSbSLP9rFa52mchiMXah0+Vt7HApRZ+ivZo8kVya3W6MXZYdmp+b6sYA+llEVgBckGYRRURNxIZVO4V6AU77wmZewbmO/p38P/FBIOjrpkk6hSVgboE3P15PEWLJmMuy+nLfWdmNbKBHC46yaYoL7WYI1+SjJBDenRLDnR20u1uA/ajKJfFhMdGxbUgU+t79q7BinRbh5uxpTFvT6mXAgyDipZv5eJaeAxPONTsO4lKu9FGErEdOnI74ylxYOX9M4C+brHkNpKJiB1U+Tc94hazMNDiOJ/EqtKDpDnbExSqbHEF6vp47b33fevVG965l+WE9jFgAcIIAMBYSipjY=
16
+ script:
17
+ # the following command line builds the project, runs the tests with coverage and then execute the SonarCloud analysis
18
+ - bundle exec rake
19
+ - sonar-scanner
data/README.md CHANGED
@@ -1,7 +1,26 @@
1
1
  # lita-vaxcalc
2
2
 
3
3
  [![Build Status](https://travis-ci.org/Yenwod/lita-vaxcalc.png?branch=master)](https://travis-ci.org/Yenwod/lita-vaxcalc)
4
- [![Coverage Status](https://coveralls.io/repos/Yenwod/lita-vaxcalc/badge.png)](https://coveralls.io/r/Yenwod/lita-vaxcalc)
4
+
5
+ ## Quality
6
+ [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=alert_status)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
7
+
8
+ ## Tests
9
+ [![Coverage](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=coverage)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
10
+
11
+ ## Security
12
+ [![Security Rating](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=security_rating)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
13
+ [![Vulnerabilities](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=vulnerabilities)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
14
+
15
+ ## Reliability
16
+ [![Reliability Rating](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=reliability_rating)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
17
+ [![Bugs](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=bugs)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
18
+
19
+ ## Maintainability
20
+ [![Maintainability Rating](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=sqale_rating)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
21
+ [![Code Smells](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=code_smells)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
22
+ [![Technical Debt](https://sonarcloud.io/api/project_badges/measure?project=Yenwod_lita-vaxcalc&metric=sqale_index)](https://sonarcloud.io/dashboard?id=Yenwod_lita-vaxcalc)
23
+
5
24
 
6
25
  Provides the capability to chat about vaccines and their ingredients.
7
26
 
@@ -9,6 +9,12 @@ module Lita
9
9
  help: { 'contains [ingredient]' => 'prints vaccine list' }
10
10
  )
11
11
 
12
+ route(
13
+ /^exemptions\s+(\D+)$/i, :respond_with_exemptions,
14
+ command: true,
15
+ help: { 'exemptions [VA] or [Virginia]' => 'responds with vaccine exemption info for your state' }
16
+ )
17
+
12
18
  def double_number(n)
13
19
  n + n
14
20
  end
@@ -19,6 +25,10 @@ module Lita
19
25
  response.reply "#{n}"
20
26
  end
21
27
 
28
+ def respond_with_exemptions(response)
29
+ response.reply "Medical and religious"
30
+ end
31
+
22
32
  Lita.register_handler(self)
23
33
  end
24
34
  end
data/lita-vaxcalc.gemspec CHANGED
@@ -1,11 +1,11 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = "lita-vaxcalc"
3
- spec.version = "0.1.0"
3
+ spec.version = "0.2.0"
4
4
  spec.authors = ["Chris Downey"]
5
5
  spec.email = ["cdowney@gmail.com"]
6
6
  spec.description = "VaxCalc (vaccine ingredient calculator) skills"
7
7
  spec.summary = "Provides vaccine ingredient information via VaxCalc API"
8
- spec.homepage = "https://censored.vaxcalc.org/category/vaxbot"
8
+ spec.homepage = "https://github.com/Yenwod/lita-vaxcalc"
9
9
  spec.license = "MIT"
10
10
  spec.metadata = { "lita_plugin_type" => "handler" }
11
11
 
@@ -22,5 +22,4 @@ Gem::Specification.new do |spec|
22
22
  spec.add_development_dependency "rack-test"
23
23
  spec.add_development_dependency "rspec", ">= 3.0.0"
24
24
  spec.add_development_dependency "simplecov"
25
- spec.add_development_dependency "coveralls"
26
25
  end
@@ -0,0 +1,23 @@
1
+ sonar.projectKey=Yenwod_lita-vaxcalc
2
+ # this is the name and version displayed in the SonarCloud UI.
3
+ sonar.projectName=lita-vaxcalc
4
+ sonar.projectVersion=1.0
5
+
6
+ # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows.
7
+ # This property is optional if sonar.modules is set.
8
+ sonar.sources=lib
9
+
10
+ # Encoding of the source code. Default is default system encoding
11
+ # sonar.sourceEncoding=UTF-8
12
+
13
+ # sonar.exclusions=**/node_modules/**,**/*.spec.ts
14
+ sonar.tests=spec
15
+ # sonar.test.inclusions=**/*.spec.ts
16
+
17
+ # sonar.ruby.file.suffixes=rb,ruby
18
+ # sonar.ruby.coverage.reportPath=coverage/.resultset.json
19
+ # sonar.ruby.coverage.framework=RSpec
20
+ # sonar.ruby.rubocopConfig=.rubocop.yml
21
+ # sonar.ruby.rubocop=/usr/bin/rubocop
22
+ # sonar.ruby.rubocop.reportPath=rubocop-result.json
23
+ # sonar.ruby.rubocop.filePath=.
@@ -11,6 +11,15 @@ describe Lita::Handlers::Vaxcalc, lita_handler: true do
11
11
  it { is_expected.to route('Lita contains aluminum') }
12
12
  #it { is_expected.to_not route('Lita contains 1e4') }
13
13
  it { is_expected.to_not route('Lita contains 1e4') }
14
+
15
+ it { is_expected.to route('Lita exemptions Virginia')}
16
+ end
17
+
18
+ describe ':exemptions' do
19
+ it 'returns exemptions for Virginia' do
20
+ send_message 'Lita exemptions Virginia'
21
+ expect(replies.last).to eq('Medical and religious')
22
+ end
14
23
  end
15
24
 
16
25
  describe ':double_number' do
data/spec/spec_helper.rb CHANGED
@@ -1,8 +1,6 @@
1
1
  require "simplecov"
2
- require "coveralls"
3
2
  SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter.new([
4
3
  SimpleCov::Formatter::HTMLFormatter,
5
- Coveralls::SimpleCov::Formatter
6
4
  ])
7
5
  SimpleCov.start { add_filter "/spec/" }
8
6
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lita-vaxcalc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Downey
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-03 00:00:00.000000000 Z
11
+ date: 2019-09-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: lita
@@ -114,20 +114,6 @@ dependencies:
114
114
  - - ">="
115
115
  - !ruby/object:Gem::Version
116
116
  version: '0'
117
- - !ruby/object:Gem::Dependency
118
- name: coveralls
119
- requirement: !ruby/object:Gem::Requirement
120
- requirements:
121
- - - ">="
122
- - !ruby/object:Gem::Version
123
- version: '0'
124
- type: :development
125
- prerelease: false
126
- version_requirements: !ruby/object:Gem::Requirement
127
- requirements:
128
- - - ">="
129
- - !ruby/object:Gem::Version
130
- version: '0'
131
117
  description: VaxCalc (vaccine ingredient calculator) skills
132
118
  email:
133
119
  - cdowney@gmail.com
@@ -145,10 +131,11 @@ files:
145
131
  - lib/lita/handlers/vaxcalc.rb
146
132
  - lita-vaxcalc.gemspec
147
133
  - locales/en.yml
134
+ - sonar-project.properties
148
135
  - spec/lita/handlers/vaxcalc_spec.rb
149
136
  - spec/spec_helper.rb
150
137
  - templates/.gitkeep
151
- homepage: https://censored.vaxcalc.org/category/vaxbot
138
+ homepage: https://github.com/Yenwod/lita-vaxcalc
152
139
  licenses:
153
140
  - MIT
154
141
  metadata: