diff options
| author | Dylan Baker <dylan@pnwbakers.com> | 2023-12-13 11:38:41 -0800 |
|---|---|---|
| committer | Eli Schwartz <eschwartz93@gmail.com> | 2023-12-13 15:19:21 -0500 |
| commit | e991c4d45460c09e5eaee6cb1041edb95d1e990e (patch) | |
| tree | 34e1d374aa99ecd5f4741396860b6463d60385e3 /unittests | |
| parent | 1f82afe8999e9b30403c57f9ac86ef2fc7ec1267 (diff) | |
| download | meson-e991c4d45460c09e5eaee6cb1041edb95d1e990e.tar.gz | |
Use SPDX-License-Identifier consistently
This replaces all of the Apache blurbs at the start of each file with an
`# SPDX-License-Identifier: Apache-2.0` string. It also fixes existing
uses to be consistent in capitalization, and to be placed above any
copyright notices.
This removes nearly 3000 lines of boilerplate from the project (only
python files), which no developer cares to look at.
SPDX is in common use, particularly in the Linux kernel, and is the
recommended format for Meson's own `project(license: )` field
Diffstat (limited to 'unittests')
| -rw-r--r-- | unittests/allplatformstests.py | 13 | ||||
| -rw-r--r-- | unittests/baseplatformtests.py | 13 | ||||
| -rw-r--r-- | unittests/darwintests.py | 13 | ||||
| -rw-r--r-- | unittests/datatests.py | 13 | ||||
| -rw-r--r-- | unittests/failuretests.py | 13 | ||||
| -rw-r--r-- | unittests/internaltests.py | 13 | ||||
| -rw-r--r-- | unittests/linuxcrosstests.py | 13 | ||||
| -rw-r--r-- | unittests/linuxliketests.py | 13 | ||||
| -rw-r--r-- | unittests/machinefiletests.py | 13 | ||||
| -rw-r--r-- | unittests/platformagnostictests.py | 13 | ||||
| -rw-r--r-- | unittests/pythontests.py | 13 | ||||
| -rw-r--r-- | unittests/rewritetests.py | 13 | ||||
| -rw-r--r-- | unittests/subprojectscommandtests.py | 13 | ||||
| -rw-r--r-- | unittests/taptests.py | 13 | ||||
| -rw-r--r-- | unittests/windowstests.py | 17 |
15 files changed, 17 insertions, 182 deletions
diff --git a/unittests/allplatformstests.py b/unittests/allplatformstests.py index 86a6b61c9..c15519874 100644 --- a/unittests/allplatformstests.py +++ b/unittests/allplatformstests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import subprocess import re import json diff --git a/unittests/baseplatformtests.py b/unittests/baseplatformtests.py index 514f3b759..ec3f18908 100644 --- a/unittests/baseplatformtests.py +++ b/unittests/baseplatformtests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - from pathlib import PurePath from unittest import mock, TestCase, SkipTest import json diff --git a/unittests/darwintests.py b/unittests/darwintests.py index 91ccb42b5..5528bbc9f 100644 --- a/unittests/darwintests.py +++ b/unittests/darwintests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import subprocess import re import os diff --git a/unittests/datatests.py b/unittests/datatests.py index 70fdcba46..ae32a9491 100644 --- a/unittests/datatests.py +++ b/unittests/datatests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import re import unittest from itertools import chain diff --git a/unittests/failuretests.py b/unittests/failuretests.py index 2b7c73ea5..baa592047 100644 --- a/unittests/failuretests.py +++ b/unittests/failuretests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import subprocess import tempfile import os diff --git a/unittests/internaltests.py b/unittests/internaltests.py index 3dc0fe7e6..945faa18b 100644 --- a/unittests/internaltests.py +++ b/unittests/internaltests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - from configparser import ConfigParser from pathlib import Path from unittest import mock diff --git a/unittests/linuxcrosstests.py b/unittests/linuxcrosstests.py index 28bf41555..a35633cdd 100644 --- a/unittests/linuxcrosstests.py +++ b/unittests/linuxcrosstests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import os import shutil import unittest diff --git a/unittests/linuxliketests.py b/unittests/linuxliketests.py index a02c99e8f..271822962 100644 --- a/unittests/linuxliketests.py +++ b/unittests/linuxliketests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2022 The Meson development team -# 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. - import stat import subprocess import re diff --git a/unittests/machinefiletests.py b/unittests/machinefiletests.py index d2309f802..c3802618d 100644 --- a/unittests/machinefiletests.py +++ b/unittests/machinefiletests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - from __future__ import annotations import subprocess diff --git a/unittests/platformagnostictests.py b/unittests/platformagnostictests.py index 31dea0ffe..581ecaccc 100644 --- a/unittests/platformagnostictests.py +++ b/unittests/platformagnostictests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2021 The Meson development team -# 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. - import json import os import pickle diff --git a/unittests/pythontests.py b/unittests/pythontests.py index afcfec378..6079bd587 100644 --- a/unittests/pythontests.py +++ b/unittests/pythontests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import glob, os, pathlib, shutil, subprocess, unittest from run_tests import ( diff --git a/unittests/rewritetests.py b/unittests/rewritetests.py index 7932fecae..af5e204dc 100644 --- a/unittests/rewritetests.py +++ b/unittests/rewritetests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import subprocess from itertools import zip_longest import json diff --git a/unittests/subprojectscommandtests.py b/unittests/subprojectscommandtests.py index d50828b29..85950a084 100644 --- a/unittests/subprojectscommandtests.py +++ b/unittests/subprojectscommandtests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import subprocess import tempfile import textwrap diff --git a/unittests/taptests.py b/unittests/taptests.py index 6c2ccb0ec..26d96eafd 100644 --- a/unittests/taptests.py +++ b/unittests/taptests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import unittest import io diff --git a/unittests/windowstests.py b/unittests/windowstests.py index be53d65a0..fc56eaa98 100644 --- a/unittests/windowstests.py +++ b/unittests/windowstests.py @@ -1,17 +1,6 @@ +# SPDX-License-Identifier: Apache-2.0 # Copyright 2016-2021 The Meson development team -# 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. - import subprocess import re import os @@ -184,7 +173,7 @@ class WindowsTests(BasePlatformTests): # to the right reason). return self.build() - + @skipIf(is_cygwin(), 'Test only applicable to Windows') def test_genvslite(self): # The test framework itself might be forcing a specific, non-ninja backend across a set of tests, which @@ -225,7 +214,7 @@ class WindowsTests(BasePlatformTests): # Wrap the following bulk of setup and msbuild invocation testing in a try-finally because any exception, # failure, or success must always clean up any of the suffixed build dir folders that may have been generated. try: - # Since this + # Since this self.init(testdir, extra_args=['--genvslite', 'vs2022']) # We need to bear in mind that the BasePlatformTests framework creates and cleans up its own temporary # build directory. However, 'genvslite' creates a set of suffixed build directories which we'll have |
