Commit cc2bcf2c by mingyuan

fix notifcat faild

parent 7e5b562c
......@@ -2,14 +2,15 @@ source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
gemspec
gem 'rails', '7.0.0.alpha.2'
gem 'pg'
gem 'puma'
gem 'sidekiq'
gem 'viter', github: 'qinmingyuan/viter'
gem 'rails_com', github: 'work-design/rails_com'
gem 'rails_vite', github: 'work-design/rails_vite'
gem 'rails_design', github: 'work-design/rails_design'
gem 'rails_extend', github: 'work-design/rails_extend'
gem 'rails_com', github: 'work-design/rails_com'
gem 'amazing_print'
......
GIT
remote: https://github.com/qinmingyuan/viter.git
revision: 82d46c2eed89cc27b89811e3ded0cb6797f3b807
specs:
viter (0.1)
rails
GIT
remote: https://github.com/work-design/rails_com.git
revision: 2377ede7104b675247bf7b26bc279591d54d0a21
specs:
......@@ -31,11 +24,18 @@ GIT
GIT
remote: https://github.com/work-design/rails_extend.git
revision: c51aad1277fff57c53409a2c4c6c4e90461463d5
revision: 55221ffc89fed5836a60bdc037bfa727ef3fd048
specs:
rails_extend (1.0.0)
rails (>= 5.0)
GIT
remote: https://github.com/work-design/rails_vite.git
revision: ef130e9069c8f980bcc749dfbdeb026c632d4b8a
specs:
rails_vite (0.0.1)
rails
PATH
remote: .
specs:
......@@ -49,65 +49,64 @@ GEM
specs:
acme-client (2.0.9)
faraday (>= 0.17, < 2.0.0)
actioncable (6.1.4.1)
actionpack (= 6.1.4.1)
activesupport (= 6.1.4.1)
actioncable (7.0.0.alpha2)
actionpack (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
actionmailbox (6.1.4.1)
actionpack (= 6.1.4.1)
activejob (= 6.1.4.1)
activerecord (= 6.1.4.1)
activestorage (= 6.1.4.1)
activesupport (= 6.1.4.1)
actionmailbox (7.0.0.alpha2)
actionpack (= 7.0.0.alpha2)
activejob (= 7.0.0.alpha2)
activerecord (= 7.0.0.alpha2)
activestorage (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
mail (>= 2.7.1)
actionmailer (6.1.4.1)
actionpack (= 6.1.4.1)
actionview (= 6.1.4.1)
activejob (= 6.1.4.1)
activesupport (= 6.1.4.1)
actionmailer (7.0.0.alpha2)
actionpack (= 7.0.0.alpha2)
actionview (= 7.0.0.alpha2)
activejob (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
actionpack (6.1.4.1)
actionview (= 6.1.4.1)
activesupport (= 6.1.4.1)
rack (~> 2.0, >= 2.0.9)
actionpack (7.0.0.alpha2)
actionview (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
rack (~> 2.0, >= 2.2.0)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
actiontext (6.1.4.1)
actionpack (= 6.1.4.1)
activerecord (= 6.1.4.1)
activestorage (= 6.1.4.1)
activesupport (= 6.1.4.1)
actiontext (7.0.0.alpha2)
actionpack (= 7.0.0.alpha2)
activerecord (= 7.0.0.alpha2)
activestorage (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
nokogiri (>= 1.8.5)
actionview (6.1.4.1)
activesupport (= 6.1.4.1)
actionview (7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
activejob (6.1.4.1)
activesupport (= 6.1.4.1)
activejob (7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
globalid (>= 0.3.6)
activemodel (6.1.4.1)
activesupport (= 6.1.4.1)
activerecord (6.1.4.1)
activemodel (= 6.1.4.1)
activesupport (= 6.1.4.1)
activestorage (6.1.4.1)
actionpack (= 6.1.4.1)
activejob (= 6.1.4.1)
activerecord (= 6.1.4.1)
activesupport (= 6.1.4.1)
activemodel (7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
activerecord (7.0.0.alpha2)
activemodel (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
activestorage (7.0.0.alpha2)
actionpack (= 7.0.0.alpha2)
activejob (= 7.0.0.alpha2)
activerecord (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
marcel (~> 1.0.0)
mini_mime (>= 1.1.0)
activesupport (6.1.4.1)
activesupport (7.0.0.alpha2)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2)
minitest (>= 5.1)
tzinfo (~> 2.0)
zeitwerk (~> 2.3)
acts_as_list (1.0.4)
activerecord (>= 4.2)
amazing_print (1.3.0)
......@@ -118,7 +117,7 @@ GEM
concurrent-ruby (1.1.9)
connection_pool (2.2.5)
crass (1.0.6)
debug (1.0.0)
debug (1.1.0)
irb
reline (>= 0.2.7)
default_where (2.3.0)
......@@ -174,7 +173,7 @@ GEM
nokogiri (>= 1.5.9)
mail (2.7.1)
mini_mime (>= 0.1.1)
marcel (1.0.1)
marcel (1.0.2)
method_source (1.0.0)
mini_mime (1.1.1)
mini_portile2 (2.6.1)
......@@ -186,39 +185,44 @@ GEM
nokogiri (1.12.4)
mini_portile2 (~> 2.6.1)
racc (~> 1.4)
nokogiri (1.12.4-x86_64-darwin)
racc (~> 1.4)
nokogiri (1.12.4-x86_64-linux)
racc (~> 1.4)
pg (1.2.3)
puma (5.4.0)
puma (5.5.0)
nio4r (~> 2.0)
racc (1.5.2)
rack (2.2.3)
rack-test (1.1.0)
rack (>= 1.0, < 3)
rails (6.1.4.1)
actioncable (= 6.1.4.1)
actionmailbox (= 6.1.4.1)
actionmailer (= 6.1.4.1)
actionpack (= 6.1.4.1)
actiontext (= 6.1.4.1)
actionview (= 6.1.4.1)
activejob (= 6.1.4.1)
activemodel (= 6.1.4.1)
activerecord (= 6.1.4.1)
activestorage (= 6.1.4.1)
activesupport (= 6.1.4.1)
rails (7.0.0.alpha2)
actioncable (= 7.0.0.alpha2)
actionmailbox (= 7.0.0.alpha2)
actionmailer (= 7.0.0.alpha2)
actionpack (= 7.0.0.alpha2)
actiontext (= 7.0.0.alpha2)
actionview (= 7.0.0.alpha2)
activejob (= 7.0.0.alpha2)
activemodel (= 7.0.0.alpha2)
activerecord (= 7.0.0.alpha2)
activestorage (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
bundler (>= 1.15.0)
railties (= 6.1.4.1)
railties (= 7.0.0.alpha2)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.4.2)
loofah (~> 2.3)
railties (6.1.4.1)
actionpack (= 6.1.4.1)
activesupport (= 6.1.4.1)
railties (7.0.0.alpha2)
actionpack (= 7.0.0.alpha2)
activesupport (= 7.0.0.alpha2)
method_source
rake (>= 0.13)
thor (~> 1.0)
zeitwerk (~> 2.5.0.beta3)
rake (13.0.6)
rdoc (6.3.2)
redis (4.4.0)
......@@ -249,7 +253,7 @@ GEM
websocket-extensions (0.1.5)
with_advisory_lock (4.6.0)
activerecord (>= 4.2)
zeitwerk (2.4.2)
zeitwerk (2.5.0.beta4)
PLATFORMS
ruby
......@@ -263,13 +267,14 @@ DEPENDENCIES
minitest-hooks
pg
puma
rails (= 7.0.0.alpha.2)
rails_com!
rails_design!
rails_dingtalk!
rails_extend!
rails_vite!
sdoc
sidekiq
viter!
BUNDLED WITH
2.2.22
......@@ -42,8 +42,8 @@ module Dingtalk::Api
r = post '/message/workNotification', **payload
if r.is_a? Hash
r.dig('content', 'data')
if r.is_a?(Hash) && r.dig('success')
r.dig('content')
else
r
end
......
......@@ -6,11 +6,11 @@ ENV['NODE_ENV'] ||= ENV['RACK_ENV'] || 'development'
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../Gemfile', __dir__)
require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE'])
require 'viter'
require 'rails_vite'
require_relative '../test/dummy/config/application'
Viter::Exporter.export
RailsVite::Exporter.export
APP_ROOT = File.expand_path('../test/dummy', __dir__)
Dir.chdir(APP_ROOT) do
Viter::DevServerRunner.run(ARGV)
RailsVite::DevServerRunner.run(ARGV)
end
......@@ -18,10 +18,10 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest
end
test 'create ok' do
assert_difference('App.count') do
assert_difference('Dingtalk::App.count') do
post(
url_for(controller: 'dingtalk/admin/apps', action: 'create'),
params: { app: { agent_id: @dingtalk_admin_app.agent_id, app_key: @dingtalk_admin_app.app_key, app_secret: @dingtalk_admin_app.app_secret, corp_id: @dingtalk_admin_app.corp_id } },
params: { app: { agent_id: @app.agent_id, app_key: @app.app_key, app_secret: @app.app_secret, corp_id: @app.corp_id } },
as: :turbo_stream
)
end
......@@ -44,7 +44,7 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest
test 'update ok' do
patch(
url_for(controller: 'dingtalk/admin/apps', action: 'update', id: @app.id),
params: { app: { agent_id: @dingtalk_admin_app.agent_id, app_key: @dingtalk_admin_app.app_key, app_secret: @dingtalk_admin_app.app_secret, corp_id: @dingtalk_admin_app.corp_id } },
params: { app: { agent_id: @app.agent_id, app_key: @app.app_key, app_secret: @app.app_secret, corp_id: @app.corp_id } },
as: :turbo_stream
)
......@@ -52,7 +52,7 @@ class Dingtalk::Admin::AppsControllerTest < ActionDispatch::IntegrationTest
end
test 'destroy ok' do
assert_difference('App.count', -1) do
assert_difference('Dingtalk::App.count', -1) do
delete url_for(controller: 'dingtalk/admin/apps', action: 'destroy', id: @app.id), as: :turbo_stream
end
......
Subproject commit 2b3deeebfb0873934280a181a8a4a373bc0ce4e3
Subproject commit 66154deed8b98186debc34595b24bfffbe7141c5
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment