Skip to content

Commit

Permalink
Come on headers
Browse files Browse the repository at this point in the history
  • Loading branch information
DarthHater committed May 28, 2020
1 parent 32fa5e6 commit 0326db4
Show file tree
Hide file tree
Showing 20 changed files with 93 additions and 40 deletions.
2 changes: 2 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#
# Copyright 2019-present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -11,6 +12,7 @@
# 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.
#

FROM docker-all.repo.sonatype.com/python:3.7-alpine

Expand Down
30 changes: 15 additions & 15 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
/*
* Copyright 2019-present Sonatype Inc.
*
* Licensed 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.
*/
//
// Copyright 2019-Present Sonatype Inc.
//
// Licensed 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.
//
@Library(['private-pipeline-library', 'jenkins-shared']) _

dockerizedBuildPipeline(
Expand Down
7 changes: 5 additions & 2 deletions jake/audit/audit.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
""" audit.py for all your audit py needs """
# pylint: disable=no-else-return
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -13,6 +12,10 @@
# 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.
#

""" audit.py for all your audit py needs """
# pylint: disable=no-else-return
import logging

from typing import List
Expand Down
5 changes: 4 additions & 1 deletion jake/config/config.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""config.py stores OSSIndex credentials"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""config.py stores OSSIndex credentials"""
import logging
import os

Expand Down
5 changes: 4 additions & 1 deletion jake/config/iq_config.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""iq_config.py stores IQ credentials"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""iq_config.py stores IQ credentials"""
from ..config.config import Config

class IQConfig(Config):
Expand Down
6 changes: 4 additions & 2 deletions jake/cyclonedx/generator.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
"""generator.py will craft and validate a CycloneDX SBOM"""
# pylint: disable=protected-access
#
# Copyright 2019-Present Sonatype Inc.
#
Expand All @@ -14,6 +12,10 @@
# 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.
#

"""generator.py will craft and validate a CycloneDX SBOM"""
# pylint: disable=protected-access
import logging

from lxml import etree
Expand Down
5 changes: 4 additions & 1 deletion jake/cyclonedx/v1_1/generator.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""generator.py will craft a CycloneDX 1.1 SBOM"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""generator.py will craft a CycloneDX 1.1 SBOM"""
import pathlib
import logging

Expand Down
6 changes: 4 additions & 2 deletions jake/iq/iq.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
"""iq.py handles requests to IQ Server"""
# pylint: disable=too-many-instance-attributes
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -13,6 +12,9 @@
# 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.
#
"""iq.py handles requests to IQ Server"""
# pylint: disable=too-many-instance-attributes
import json
import logging

Expand Down
5 changes: 4 additions & 1 deletion jake/ossindex/ossindex.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""ossindex.py makes a request to OSSIndex"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""ossindex.py makes a request to OSSIndex"""
import logging
import json

Expand Down
5 changes: 4 additions & 1 deletion jake/parse/parse.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""parse.py parses dependencies and converts them to purls"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""parse.py parses dependencies and converts them to purls"""
import logging
from shutil import which

Expand Down
8 changes: 5 additions & 3 deletions jake/pip/pip.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
"""pip.py gets installed pip dependencies"""
# pylint: disable=protected-access
# Copyright 2020 Sonatype Inc.
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -13,7 +12,10 @@
# 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.
#

"""pip.py gets installed pip dependencies"""
# pylint: disable=protected-access
import logging
import ast
import pkg_resources
Expand Down
5 changes: 4 additions & 1 deletion jake/test/test_audit.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
""" test_audit.py , for all your testing of audit py needs """
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

""" test_audit.py , for all your testing of audit py needs """
import unittest
import json

Expand Down
5 changes: 4 additions & 1 deletion jake/test/test_config.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""test_config.py audits the Config class"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""test_config.py audits the Config class"""
import unittest

from ..config.config import Config
Expand Down
5 changes: 4 additions & 1 deletion jake/test/test_coordinateresults.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""test_coordinateresults.py audits the CoordinateResult type"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""test_coordinateresults.py audits the CoordinateResult type"""
import unittest
import ast

Expand Down
7 changes: 5 additions & 2 deletions jake/test/test_iq_config.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""test_iq_config.py verifies the IQConfig class"""
# Copyright 2020 Sonatype Inc.
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""test_iq_config.py verifies the IQConfig class"""
import io

import sys
Expand Down
5 changes: 4 additions & 1 deletion jake/test/test_ossindex.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""test_ossindex.py audits the call to OSSIndex"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""test_ossindex.py audits the call to OSSIndex"""
import unittest
import json
from unittest.mock import patch
Expand Down
5 changes: 4 additions & 1 deletion jake/test/test_parse.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""test_parse.py adits the Parse class"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""test_parse.py adits the Parse class"""
import unittest
import pathlib

Expand Down
7 changes: 5 additions & 2 deletions jake/test/test_pip.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""test_pip.py audits the Pip class"""
# Copyright 2020 Sonatype Inc.
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""test_pip.py audits the Pip class"""
import unittest

from ..pip.pip import Pip
Expand Down
5 changes: 4 additions & 1 deletion jake/test/test_results_decoder.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""test_results_decoder.py audits the ResultsDecoder class"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""test_results_decoder.py audits the ResultsDecoder class"""
import unittest
import pathlib
import json
Expand Down
5 changes: 4 additions & 1 deletion jake/test/test_sbom_generator.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""test_sbom_generator.py audits the cyclonedx/1.1/CycloneDx11Generator class"""
#
# Copyright 2019-Present Sonatype Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,6 +12,9 @@
# 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.
#

"""test_sbom_generator.py audits the cyclonedx/1.1/CycloneDx11Generator class"""
import unittest
import pathlib
import json
Expand Down

0 comments on commit 0326db4

Please sign in to comment.