Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Adding Python docs precommit as separate suite.
  • Loading branch information
pabloem committed Aug 14, 2020
commit f4d840afb323d5a5afd2d0624cb452d620fa477a
38 changes: 38 additions & 0 deletions .test-infra/jenkins/job_PreCommit_PythonDocs.groovy
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

import PrecommitJobBuilder
import CommonJobProperties as common

PrecommitJobBuilder builder = new PrecommitJobBuilder(
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please fix indentation

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done, I think : )

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spotless complained. I undid this.

scope: this,
nameBase: 'Python',
gradleTask: ':pythonDocsPreCommit',
timeoutMins: 180,
triggerPathPatterns: [
'^model/.*$',
'^sdks/python/.*$',
'^release/.*$',
]
)
builder.build {
// Publish all test results to Jenkins.
publishers {
common.setArchiveJunitWithStabilityHistory(delegate, '**/pytest*.xml')
}
}
4 changes: 4 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,10 @@ task pythonPreCommit() {
// have caught. Note that the same tests will still run in postcommit.
}

task pythonDocsPreCommit() {
dependsOn ":sdks:python:test-suites:tox:pycommon:docs"
}

task pythonDockerBuildPreCommit() {
dependsOn ":sdks:python:container:py2:docker"
dependsOn ":sdks:python:container:py35:docker"
Expand Down
1 change: 0 additions & 1 deletion sdks/python/test-suites/tox/pycommon/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ toxTask "docs", "py38-docs"
assemble.dependsOn docs

task preCommitPyCommon() {
dependsOn "docs"
}

toxTask "dependency-check", "py3-dependency-check"