Skip to content

Commit d8d0a78

Browse files
Merge pull request #6 from ultimatecoder/master-add-license
[ADD] Master adding licensing notes.
2 parents c1c268a + 8eedc5a commit d8d0a78

18 files changed

+727
-2
lines changed

LICENSE

Lines changed: 621 additions & 0 deletions
Large diffs are not rendered by default.

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,6 @@
11
[![Build Status](https://travis-ci.org/ultimatecoder/yamq.svg?branch=master)](https://travis-ci.org/ultimatecoder/yamq)
2+
3+
License
4+
-------
5+
Under GPLv3 (https://www.python.org/download/other/). For more details, please
6+
read LICENSE file at the root of the project.

test/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])
2+
# Please find copy of license at "LICENSE"
3+
# at the root of the project.

test/functional/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])
2+
# Please find copy of license at "LICENSE"
3+
# at the root of the project.

test/functional/test_license.py

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])
2+
# Please find copy of license at "LICENSE"
3+
# at the root of the project.
4+
5+
6+
import glob
7+
import unittest
8+
import subprocess
9+
10+
11+
class TestLicense(unittest.TestCase):
12+
13+
def test_each_file_starts_with_license(self):
14+
license = [
15+
'# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])',
16+
'# Please find copy of license at "LICENSE"',
17+
'# at the root of the project.',
18+
]
19+
files = glob.glob("**/*.py", recursive=True)
20+
for file_ in files:
21+
with open(file_) as file_obj:
22+
heading = file_obj.read(135)
23+
heading = heading.splitlines() if heading else []
24+
message = (
25+
"\nFile: {} is missing license note. It is compulsory to add a"
26+
"license note to each file."
27+
)
28+
self.assertListEqual(heading, license, message.format(file_))

test/unit/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])
2+
# Please find copy of license at "LICENSE"
3+
# at the root of the project.

test/unit/test_frame.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
1+
# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])
2+
# Please find copy of license at "LICENSE"
3+
# at the root of the project.

test/unit/test_message.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])
2+
# Please find copy of license at "LICENSE"
3+
# at the root of the project.
4+
5+
16
from unittest import TestCase
27

38
from yamq import message

test/unit/test_parse.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])
2+
# Please find copy of license at "LICENSE"
3+
# at the root of the project.
4+
5+
16
from unittest import TestCase
27

38
from yamq import stomp

test/unit/test_subject.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# Copyright (C) 2017-2018 Jaysinh Shukla ([email protected])
2+
# Please find copy of license at "LICENSE"
3+
# at the root of the project.
4+
5+
16
import unittest
27
from unittest import mock
38

0 commit comments

Comments
 (0)