Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tkio-test-case
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
liuxiaoxing
tkio-test-case
Commits
ae39259b
Commit
ae39259b
authored
Jun 14, 2022
by
liuxiaoxing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Merge remote-tracking branch 'remotes/origin/recieveandroid-se' into receiveios-asa
# Conflicts: # microservices/receiveandroid.py # microservices/receiveios.py 合并asa和se代码
parent
105ee656
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
47 additions
and
52 deletions
+47
-52
click.py
android_click/click.py
+24
-26
android_script.py
android_event/android_script.py
+1
-1
android_fenlianjie.py
android_event_case/android_fenlianjie.py
+8
-8
attributioncase.py
microservices/attributioncase.py
+2
-2
receiveandroid.py
microservices/receiveandroid.py
+4
-3
receiveios.py
microservices/receiveios.py
+0
-2
redirectandroid.py
microservices/redirectandroid.py
+4
-6
redirectios.py
microservices/redirectios.py
+4
-4
No files found.
android_click/click.py
View file @
ae39259b
...
...
@@ -19,6 +19,9 @@ def code_nums2(n=6):
s
=
str
(
random
.
choice
([
num
]))
ret
+=
s
return
ret
# from jiami.md5 import get_str_sha1_secret_str
# 向短链发送点击数据
# 广告创意ID
...
...
@@ -35,8 +38,8 @@ ry_adplan_name = 'c测试1'
ry_adcreative_name
=
'c测试1'
# bytedance_int 今日头条,kuaishou_int 快手,tencentams_int (新)广点通,rryingxiao_int 人人营销
pid
=
'rryingxiao_int'
# URL = 'http://52.80.137.106:8083/tkio/
V3Q7bqa?noredirect=true
'
URL
=
'http://uri6.com/tkio/
A3QzEva?noredirect=true
'
# URL = 'http://52.80.137.106:8083/tkio/
euAVfua?noredirect=true&callback=http%3A%2F%2Fad.toutiao.com%2Ftrack%2Factivate%2F%3Fcallback%3DCKP4rs-Zn4QDEKiQ6teZn4QDGN6L8Y-h9Wcg3ovxj6H1ZyiE0PjgroSEAzAOOM_X-8IDQik0YWY1NzdlOC1lZmViLTRmZDEtYmZkZC00MzE1Zjc1MmJhMGF1NTQ5M0iA0pOtA1AAiAEAkAECmAEA%26os%3D0%26muid%3D
'
URL
=
'http://uri6.com/tkio/
vMn2eea?noredirect=true&callback=http
%3
A
%2
F
%2
Fad.toutiao.com
%2
Ftrack
%2
Factivate
%2
F
%3
Fcallback
%3
DCKP4rs-Zn4QDEKiQ6teZn4QDGN6L8Y-h9Wcg3ovxj6H1ZyiE0PjgroSEAzAOOM_X-8IDQik0YWY1NzdlOC1lZmViLTRmZDEtYmZkZC00MzE1Zjc1MmJhMGF1NTQ5M0iA0pOtA1AAiAEAkAECmAEA
%26
os
%3
D0
%26
muid
%3
D
'
# 测试头条衍生事件回调时加上
# callback= http%3A%2F%2Fad.toutiao.com%2Ftrack%2Factivate%2F%3Fcallback%3DCKP4rs-Zn4QDEKiQ6teZn4QDGN6L8Y-h9Wcg3ovxj6H1ZyiE0PjgroSEAzAOOM_X-8IDQik0YWY1NzdlOC1lZmViLTRmZDEtYmZkZC00MzE1Zjc1MmJhMGF1NTQ5M0iA0pOtA1AAiAEAkAECmAEA%26os%3D0%26muid%3D
...
...
@@ -57,7 +60,7 @@ def computeMD5upper(message):
return
m
.
hexdigest
()
.
upper
()
appkey
=
'
16dc0cb882d3dbec4f7f66251a84d6dd
'
appkey
=
'
3f2706b7afdf89d95ffa7d2e9cc13e2e
'
lst
=
[]
nowTime
=
datetime
.
datetime
.
now
()
.
strftime
(
'
%
Y-
%
m-
%
d
%
H:
%
M:
%
S'
)
s
=
0
...
...
@@ -98,9 +101,10 @@ for index in range(1):
# ip = '156.119.456.190'
try
:
parms
=
{
'click_time'
:
str
(
round
(
time
.
time
()
*
1000
)),
'click_time'
:
str
(
round
(
time
.
time
()
*
1000
)),
# 'androidid': '86ab7f6642bdde717709216e68d0b',
'imei'
:
i
,
'callback_param'
:
'EPHk9cX3pv4CGJax4ZENKI7w4MDev_4C'
,
# 'imei_MD5': computeMD5upper(i),
# 'campuuid': '@#¥%……&……%¥#@#¥%&……&*****',
# 'clickid': '测试测试',
...
...
@@ -186,14 +190,14 @@ for index in range(1):
# print('androidid', a)
w
=
w
+
1
#
time.sleep(10)
#
try:
#
allEvent().installUpload(i, ip, appkey)
#
# allEvent().formevent(i, ip, appkey)
#
#
except Exception:
#
print('install_wrong:', w)
#
w = w + 1
time
.
sleep
(
10
)
try
:
allEvent
()
.
installUpload
(
i
,
ip
,
appkey
)
# allEvent().formevent(i, ip, appkey)
except
Exception
:
print
(
'install_wrong:'
,
w
)
w
=
w
+
1
# #
# #
# time.sleep(5)
...
...
@@ -270,20 +274,14 @@ for index in range(1):
# num = index + 1
# event = 'event_' + str(num)
# event = 'event_1'
# time.sleep(3)
# try:
# allEvent().ziding_event(i, ip, appkey, event)
# print(event)
# except Exception as err:
# print(err)
# print('自定义_wrong:', w)
event
=
'event_30'
time
.
sleep
(
3
)
try
:
allEvent
()
.
ziding_event
(
i
,
ip
,
appkey
,
event
)
print
(
event
)
except
Exception
as
err
:
print
(
err
)
print
(
'自定义_wrong:'
,
w
)
# time.sleep(6)
# try:
...
...
android_event/android_script.py
View file @
ae39259b
...
...
@@ -398,7 +398,7 @@ class allEvent:
# 识别是否为自定义事件,默认传1
'_isreyundefaultevent'
:
'1'
,
# 'who': 'lxxtest',
'param
1'
:
'1
'
,
'param
7'
:
'5
'
,
},
...
...
android_event_case/android_fenlianjie.py
View file @
ae39259b
...
...
@@ -8,7 +8,7 @@ import hashlib
#安卓常规渠道激活
appkey
=
'
b7c0146c5b14d7d6d87cfd9bf1853b3
e'
appkey
=
'
3f2706b7afdf89d95ffa7d2e9cc13e2
e'
# 线上预约app
# 7f64fbd64513bc74aa6b5bf753ae0953
# 16dc0cb882d3dbec4f7f66251a84d6dd
...
...
@@ -38,8 +38,8 @@ for index in range(1):
# p = '987654321234567'
# s = '2321321312h8ro321'
i
=
''
.
join
(
str
(
random
.
choice
(
range
(
10
)))
for
_
in
range
(
12
))
# i = '990993451126
'
#
i = ''.join(str(random.choice(range(10))) for _ in range(12))
i
=
'686032665843
'
# i = '00000000-0000-0000-0000-000000000000'
# 随机生成ipXXXX XXCB489741-0029-4A35-8E38-D142F836B623
ip
=
socket
.
inet_ntoa
(
struct
.
pack
(
'>I'
,
random
.
randint
(
1
,
0xffffffff
)))
...
...
@@ -48,11 +48,11 @@ for index in range(1):
# 60.13.148.23 新疆维吾尔自治区吐鲁番市
# 61.139.239.255 广西壮族自治区北海市
# 119.60.0.0 宁夏回族自治区银川市
allEvent
()
.
installUpload
(
i
,
ip
,
appkey
)
#
allEvent().installUpload(i, ip, appkey)
# time.sleep(1)
allEvent
()
.
startupEvent
(
i
,
ip
,
appkey
)
#
allEvent().startupEvent(i, ip, appkey)
# # time.sleep(1)
allEvent
()
.
loginEvent
(
i
,
ip
,
appkey
)
#
allEvent().loginEvent(i, ip, appkey)
# time.sleep(1)
# allEvent().registerEvent(i, ip, appkey)
# allEvent().payEvent(i, ip, appkey)
...
...
@@ -61,8 +61,8 @@ for index in range(1):
# time.sleep(1)
# num = index + 1
# event = 'event_' + str(num)
# event = 'event_6
'
#
allEvent().ziding_event(i, ip, appkey, event)
event
=
'event_30
'
allEvent
()
.
ziding_event
(
i
,
ip
,
appkey
,
event
)
# print(s)
# s = int(s) + 1
# time.sleep(3)
...
...
microservices/attributioncase.py
View file @
ae39259b
...
...
@@ -995,7 +995,7 @@ def test_atb42():
g
=
code_nums
(
36
)
redirectandroid
.
parms
[
'gaid'
]
=
g
redirectandroid
.
parms
[
'imei1'
]
=
q
redirectandroid
.
send_request3
(
"73iIZ3a"
,
''
)
redirectandroid
.
send_request3
(
''
)
time
.
sleep
(
10
)
receiveandroid
.
data
[
0
][
'device_info'
][
'gaid'
]
=
g
receiveandroid
.
data
[
0
][
'device_info'
][
'device_id'
]
=
g
...
...
@@ -1009,7 +1009,7 @@ def test_atb43():
a
=
code_nums
(
16
)
redirectandroid
.
parms
[
'android_id'
]
=
a
redirectandroid
.
parms
[
'imei1'
]
=
q
redirectandroid
.
send_request3
(
"73iIZ3a"
,
''
)
redirectandroid
.
send_request3
(
''
)
time
.
sleep
(
10
)
receiveandroid
.
data
[
0
][
'device_info'
][
'android_id'
]
=
a
receiveandroid
.
data
[
0
][
'device_info'
][
'device_id'
]
=
a
...
...
microservices/receiveandroid.py
View file @
ae39259b
...
...
@@ -48,7 +48,7 @@ data = [
"application_info"
:
{
# 线上-a8ed96ae9051499fd98bc46ab9c9495c
# 测试-decbeb4d840b4bcd1a068ca7233e6ac2
"appkey"
:
"
2a33891fd3ea53f8edb0fca391a2432e
"
,
"appkey"
:
"
ea5f9f976bc7e58adcb39effc5a405e3
"
,
"bundleid"
:
"3423232"
,
"app_version"
:
"1.9.0"
,
"channel_name"
:
"HUAWEI"
...
...
@@ -142,7 +142,7 @@ def send_request():
url
=
"http://tmtest.trackingio.com/receive/tkiov2/sdk"
# 线上
# url = "http://tkio-receive.solar-engine.com/receive/tkiov2/sdk"
#
data[0]['timestamp_info']['install_time'] = int(round(time.time() * 1000))
data
[
0
][
'timestamp_info'
][
'install_time'
]
=
int
(
round
(
time
.
time
()
*
1000
))
print
(
data
)
response
=
requests
.
request
(
"POST"
,
url
,
headers
=
headers
,
data
=
json
.
dumps
(
data
))
...
...
@@ -157,8 +157,9 @@ def send_request():
def
send_request2
():
global
data
url
=
"http://tkio-receive.solar-engine.com/receive/tkiov2/sdk"
url
=
"http://tkiomicro-receive-788931749.cn-north-1.elb.amazonaws.com.cn/receive/tkiov2/sdk"
#
url = "http://tkiomicro-receive-788931749.cn-north-1.elb.amazonaws.com.cn/receive/tkiov2/sdk"
data
[
0
][
'timestamp_info'
][
'install_time'
]
=
int
(
round
(
time
.
time
()
*
1000
))
print
(
data
)
response
=
requests
.
request
(
"POST"
,
url
,
headers
=
headers
,
data
=
json
.
dumps
(
data
))
...
...
microservices/receiveios.py
View file @
ae39259b
...
...
@@ -37,8 +37,6 @@ global data
data
=
[
{
"application_info"
:
{
# 线上-55705dbd45dd246751b87bba94b8c73c
# 测试-55705dbd45dd246751b87bba94b8c73c
"appkey"
:
"2a33891fd3ea53f8edb0fca391a2432e"
,
"bundleid"
:
"3423232"
,
"app_version"
:
"1.9.0"
,
...
...
microservices/redirectandroid.py
View file @
ae39259b
...
...
@@ -117,7 +117,7 @@ def send_request(dl, cs):
# 302跳转时用该方法
def
send_request2
():
url1
=
'http://tmtest.trackingio.com/receive/turl/
Nja2aa
a'
url1
=
'http://tmtest.trackingio.com/receive/turl/
QN3eQb
a'
# parms['ts'] = int(round(time.time() * 1000))
response
=
requests
.
get
(
url
=
url1
,
params
=
parms
,
timeout
=
10
,
verify
=
False
)
print
(
response
.
url
)
...
...
@@ -128,9 +128,9 @@ def send_request2():
def
send_request3
(
cs
):
global
parms
# 测试
# url1 = 'http://tmtest.trackingio.com/receive/turl/B73uQj
a' + cs
url1
=
'http://tmtest.trackingio.com/receive/turl/QN3eQb
a'
+
cs
# 线上
url1
=
'http://tkio-redirect.solar-engine.com/receive/turl/vMvqE3
a'
+
cs
# url1 = 'http://tkio-redirect.solar-engine.com/receive/turl/MFBfqq
a' + cs
parms
[
'ts'
]
=
int
(
round
(
time
.
time
()
*
1000
))
response
=
requests
.
get
(
url
=
url1
,
params
=
parms
,
timeout
=
10
,
verify
=
False
)
print
(
response
.
url
)
...
...
@@ -141,11 +141,9 @@ def send_request3(cs):
# 没有短链及参数要求的用该方法,测试环境默认参数为2586渠道短链
# appeky:0dd83bd5079ab3b20d9e66ebb195f6c4
def
send_request4
():
global
parms
url1
=
'http://tmtest.trackingio.com/receive/turl/
zMFjQv
a'
url1
=
'http://tmtest.trackingio.com/receive/turl/
QN3eQb
a'
# url1 = 'http://tkio-redirect.solar-engine.com/receive/turl/vMvqE3a'
response
=
requests
.
get
(
url
=
url1
,
params
=
parms
,
timeout
=
10
,
verify
=
False
)
...
...
microservices/redirectios.py
View file @
ae39259b
...
...
@@ -87,9 +87,9 @@ data_temp = json.dumps(parms)
def
send_request
(
cs
):
global
parms
# 测试
# url1 = 'http://tmtest.trackingio.com/receive/turl/aimmey
a' + cs
url1
=
'http://tmtest.trackingio.com/receive/turl/I3eYve
a'
+
cs
# 线上
url1
=
'http://tkio-redirect.solar-engine.com/receive/turl/f6F7zia'
+
cs
#
url1 = 'http://tkio-redirect.solar-engine.com/receive/turl/f6F7zia' + cs
response
=
requests
.
get
(
url
=
url1
,
params
=
parms
,
timeout
=
10
,
verify
=
False
)
print
(
response
.
url
)
...
...
@@ -102,9 +102,9 @@ def send_request(cs):
def
send_request3
(
cs
):
global
parms
# 测试
#
url1 = 'http://tmtest.trackingio.com/receive/turl/I3eYvea' + cs
url1
=
'http://tmtest.trackingio.com/receive/turl/I3eYvea'
+
cs
# 线上
url1
=
'http://tkio-redirect.solar-engine.com/receive/turl/qY7fQza'
+
cs
#
url1 = 'http://tkio-redirect.solar-engine.com/receive/turl/qY7fQza' + cs
parms
[
'ts'
]
=
int
(
round
(
time
.
time
()
*
1000
))
response
=
requests
.
get
(
url
=
url1
,
params
=
parms
,
timeout
=
10
,
verify
=
False
)
print
(
response
.
url
)
...
...
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