Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
weixin_43530661
opencv-python
提交
623401a5
O
opencv-python
项目概览
weixin_43530661
/
opencv-python
与 Fork 源项目一致
Fork自
OpenCV / opencv-python
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
O
opencv-python
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
623401a5
编写于
3月 24, 2022
作者:
A
Andrey Senyaev
提交者:
GitHub
3月 24, 2022
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #638 from asenyaev/asen/pylint_test
Added pylint test
上级
8880543c
ed16e8ef
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
54 addition
and
20 deletion
+54
-20
.github/workflows/build_wheels_linux.yml
.github/workflows/build_wheels_linux.yml
+1
-1
.github/workflows/build_wheels_macos.yml
.github/workflows/build_wheels_macos.yml
+7
-0
.github/workflows/build_wheels_macos_m1.yml
.github/workflows/build_wheels_macos_m1.yml
+7
-0
.github/workflows/build_wheels_windows.yml
.github/workflows/build_wheels_windows.yml
+8
-0
tests/pylintrc
tests/pylintrc
+12
-0
travis_config.sh
travis_config.sh
+19
-19
未找到文件。
.github/workflows/build_wheels_linux.yml
浏览文件 @
623401a5
...
...
@@ -102,7 +102,7 @@ jobs:
-
name
:
Checkout
uses
:
actions/checkout@v2
with
:
submodules
:
fals
e
submodules
:
tru
e
fetch-depth
:
0
-
name
:
Setup Environment variables
...
...
.github/workflows/build_wheels_macos.yml
浏览文件 @
623401a5
...
...
@@ -137,6 +137,7 @@ jobs:
CONFIG_PATH
:
travis_config.sh
PLAT
:
x86_64
OPENCV_TEST_DATA_PATH
:
${{ github.workspace }}/opencv_extra/testdata
PYLINT_TEST_FILE
:
${{ github.workspace }}/opencv/samples/python/squares.py
steps
:
-
name
:
Checkout
...
...
@@ -171,6 +172,12 @@ jobs:
cd ${{ github.workspace }}/opencv
python modules/python/test/test.py -v --repo .
-
name
:
Pylint test
run
:
|
python -m pip install pylint==2.12.2
cd ${{ github.workspace }}/tests
python -m pylint $PYLINT_TEST_FILE
test_release_opencv_python
:
if
:
github.event_name == 'release' && github.event.release.prerelease
needs
:
[
build
,
test
]
...
...
.github/workflows/build_wheels_macos_m1.yml
浏览文件 @
623401a5
...
...
@@ -81,6 +81,7 @@ jobs:
env
:
OPENCV_TEST_DATA_PATH
:
${{ github.workspace }}/opencv_extra/testdata
PYLINT_TEST_FILE
:
${{ github.workspace }}/opencv/samples/python/squares.py
steps
:
-
name
:
Checkout
...
...
@@ -106,6 +107,12 @@ jobs:
cd ${{ github.workspace }}/opencv
arch -arm64 python${{ matrix.python-version }} modules/python/test/test.py -v --repo .
-
name
:
Pylint test
run
:
|
arch -arm64 python${{ matrix.python-version }} -m pip install pylint==2.12.2
cd ${{ github.workspace }}/tests
arch -arm64 python${{ matrix.python-version }} -m pylint $PYLINT_TEST_FILE
test_release_opencv_python
:
if
:
github.event_name == 'release' && github.event.release.prerelease
needs
:
[
build
,
test
]
...
...
.github/workflows/build_wheels_windows.yml
浏览文件 @
623401a5
...
...
@@ -96,6 +96,7 @@ jobs:
env
:
ACTIONS_ALLOW_UNSECURE_COMMANDS
:
true
OPENCV_TEST_DATA_PATH
:
${{ github.workspace }}\opencv_extra\testdata
PYLINT_TEST_FILE
:
${{ github.workspace }}\opencv\samples\python\squares.py
steps
:
-
name
:
Checkout
...
...
@@ -130,6 +131,13 @@ jobs:
python modules\python\test\test.py -v --repo .
shell
:
cmd
-
name
:
Pylint test
run
:
|
python -m pip install pylint==2.12.2
cd ${{ github.workspace }}\tests
python -m pylint $PYLINT_TEST_FILE
shell
:
cmd
test_release_opencv_python
:
if
:
github.event_name == 'release' && github.event.release.prerelease
needs
:
[
build-windows-x86_64
,
test
]
...
...
tests/pylintrc
0 → 100644
浏览文件 @
623401a5
# Source: opencv/platforms/scripts/pylintrc
[MESSAGES CONTROL]
# Disable all to choose the Tests one by one
disable=all
# Tests
enable=bad-indentation, # Used when an unexpected number of indentation’s tabulations or spaces has been found.
mixed-indentation, # Used when there are some mixed tabs and spaces in a module.
unnecessary-semicolon, # Used when a statement is ended by a semi-colon (”;”), which isn’t necessary.
unused-variable # Used when a variable is defined but not used. (Use _var to ignore var).
travis_config.sh
浏览文件 @
623401a5
...
...
@@ -141,37 +141,37 @@ function run_tests {
PYTHON
=
python
$PYTHON_VERSION
if
[
-n
"
$IS_OSX
"
]
;
then
echo
"Running for OS X"
cd
../tests
$PYTHON
get_build_info.py
cd
../opencv/
export
OPENCV_TEST_DATA_PATH
=
../opencv_extra/testdata
else
echo
"Running for linux"
if
[
$PYTHON
==
"python3.6"
]
;
then
$PYTHON
-m
pip
install
-U
numpy
==
1.19.4
fi
cd
/io/tests
$PYTHON
get_build_info.py
echo
"Running for linux"
cd
/io/opencv
export
OPENCV_TEST_DATA_PATH
=
/io/opencv_extra/testdata
if
[
$PYTHON
==
"python3.6"
]
;
then
$PYTHON
-m
pip
install
-U
numpy
==
1.19.4
fi
cd
/io/tests
$PYTHON
get_build_info.py
cd
/io/opencv
export
OPENCV_TEST_DATA_PATH
=
/io/opencv_extra/testdata
test_wheels
pylint_test
}
function
test_wheels
{
echo
"Starting tests..."
echo
"Starting
OpenCV
tests..."
#Test package
$PYTHON
modules/python/test/test.py
-v
--repo
.
}
function
pylint_test
{
echo
"Starting Pylint tests..."
$PYTHON
-m
pip
install
pylint
==
2.12.2
cd
/io/tests
$PYTHON
-m
pylint /io/opencv/samples/python/squares.py
}
export
PS4
=
'+(${BASH_SOURCE}:${LINENO}): ${FUNCNAME[0]:+${FUNCNAME[0]}(): }'
set
-x
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录