mirror of
https://github.com/2061360308/NeteaseCloudMusic_PythonSDK.git
synced 2024-11-21 14:38:19 +00:00
chore:update workflow
This commit is contained in:
parent
3227ba3269
commit
464f0d206c
2
.github/workflows/pytest.yml
vendored
2
.github/workflows/pytest.yml
vendored
@ -23,5 +23,7 @@ jobs:
|
|||||||
pip install pytest
|
pip install pytest
|
||||||
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
|
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
|
||||||
- name: Run tests with pytest
|
- name: Run tests with pytest
|
||||||
|
env:
|
||||||
|
COOKIE: ${{ secrets.COOKIE }}
|
||||||
run: |
|
run: |
|
||||||
pytest
|
pytest
|
@ -2,9 +2,7 @@ from pytest_html import extras
|
|||||||
import json
|
import json
|
||||||
import os
|
import os
|
||||||
from pprint import pprint
|
from pprint import pprint
|
||||||
import dotenv
|
|
||||||
from package.NeteaseCloudMusic import NeteaseCloudMusicApi, api_help, api_list
|
from package.NeteaseCloudMusic import NeteaseCloudMusicApi, api_help, api_list
|
||||||
dotenv.load_dotenv() # 从.env文件中加载环境变量
|
|
||||||
netease_cloud_music_api = NeteaseCloudMusicApi() # 初始化API
|
netease_cloud_music_api = NeteaseCloudMusicApi() # 初始化API
|
||||||
netease_cloud_music_api.cookie = os.getenv('COOKIE') # 设置cookie
|
netease_cloud_music_api.cookie = os.getenv('COOKIE') # 设置cookie
|
||||||
netease_cloud_music_api.DEBUG = True # 开启调试模式
|
netease_cloud_music_api.DEBUG = True # 开启调试模式
|
||||||
|
Loading…
Reference in New Issue
Block a user