Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dingtalk-sdk
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open-source
dingtalk-sdk
Commits
25c0ca3d
Commit
25c0ca3d
authored
Sep 02, 2020
by
Francis Zhou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add missing constructor arguments
parent
858363cd
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
2 deletions
+12
-2
access_token_spec.rb
spec/dingtalk/access_token_spec.rb
+6
-1
auth_spec.rb
spec/dingtalk/auth_spec.rb
+6
-1
No files found.
spec/dingtalk/access_token_spec.rb
View file @
25c0ca3d
...
@@ -4,11 +4,16 @@ require "dingtalk/access_token"
...
@@ -4,11 +4,16 @@ require "dingtalk/access_token"
RSpec
.
describe
Dingtalk
::
AccessToken
do
RSpec
.
describe
Dingtalk
::
AccessToken
do
before
:each
do
before
:each
do
@agent_id
=
"mocked_agent_id"
@app_key
=
"mocked_app_key"
@app_key
=
"mocked_app_key"
@app_secret
=
"mocked_app_secret"
@app_secret
=
"mocked_app_secret"
@mocked_access_token
=
"mocked_access_token"
@mocked_access_token
=
"mocked_access_token"
@dingtalk_request
=
Dingtalk
::
Request
.
new
(
app_key:
@app_key
,
app_secret:
@app_secret
)
@dingtalk_request
=
Dingtalk
::
Request
.
new
(
agent_id:
@agent_id
,
app_key:
@app_key
,
app_secret:
@app_secret
,
)
response_body
=
{}.
tap
do
|
h
|
response_body
=
{}.
tap
do
|
h
|
h
[
:errcode
]
=
0
h
[
:errcode
]
=
0
...
...
spec/dingtalk/auth_spec.rb
View file @
25c0ca3d
...
@@ -8,6 +8,7 @@ require "dingtalk/auth"
...
@@ -8,6 +8,7 @@ require "dingtalk/auth"
RSpec
.
describe
Dingtalk
::
Auth
do
RSpec
.
describe
Dingtalk
::
Auth
do
before
:each
do
before
:each
do
@agent_id
=
"mocked_agent_id"
@app_key
=
"mocked_app_key"
@app_key
=
"mocked_app_key"
@app_secret
=
"mocked_app_secret"
@app_secret
=
"mocked_app_secret"
...
@@ -18,7 +19,11 @@ RSpec.describe Dingtalk::Auth do
...
@@ -18,7 +19,11 @@ RSpec.describe Dingtalk::Auth do
@signature
=
Dingtalk
.
login_free_signature
(
@app_secret
,
timestamp:
@timestamp
)
@signature
=
Dingtalk
.
login_free_signature
(
@app_secret
,
timestamp:
@timestamp
)
@dingtalk_request
=
Dingtalk
::
Request
.
new
(
app_key:
@app_key
,
app_secret:
@app_secret
)
@dingtalk_request
=
Dingtalk
::
Request
.
new
(
agent_id:
@agent_id
,
app_key:
@app_key
,
app_secret:
@app_secret
,
)
# 企业内部免登 响应结果
# 企业内部免登 响应结果
get_user_info_response_body
=
{}.
tap
do
|
h
|
get_user_info_response_body
=
{}.
tap
do
|
h
|
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment