Repository: pyasi/pybuildkite

Issue:
Create functionality for the 'meta' endpoint
Create a new file and class to incorporate the [meta API](https://buildkite.com/docs/apis/rest-api/meta). 

- Create a new file called `meta.py`
- Create a class called Meta
- Return the Meta class from a method in  [buildkite.py](https://github.com/pyasi/pybuildkite/blob/master/pybuildkite/buildkite.py)
- Write unit tests for the new code

Comments:

Patch:
diff --git a/pybuildkite/buildkite.py b/pybuildkite/buildkite.py
index c89d8bd..1fd44b1 100644
--- a/pybuildkite/buildkite.py
+++ b/pybuildkite/buildkite.py
@@ -9,6 +9,7 @@ from pybuildkite.annotations import Annotations
 from pybuildkite.artifacts import Artifacts
 from pybuildkite.teams import Teams
 from pybuildkite.users import Users
+from pybuildkite.meta import Meta
 from pybuildkite.decorators import requires_token
 
 
@@ -110,3 +111,11 @@ class Buildkite(object):
         Get User operations for the Buildkite API
         """
         return Users(self.client, self.base_url)
+
+    def meta(self):
+        """
+        Get Meta operations for the Buildkite API
+
+        :return: Client
+        """
+        return Meta(self.client, self.base_url)
diff --git a/pybuildkite/meta.py b/pybuildkite/meta.py
new file mode 100644
index 0000000..10f7333
--- /dev/null
+++ b/pybuildkite/meta.py
@@ -0,0 +1,27 @@
+from posixpath import join as urljoin
+
+from pybuildkite.client import Client
+
+
+class Meta(Client):
+    """
+    Meta operations for the Buildkite API
+    """
+
+    def __init__(self, client, base_url):
+        """
+        Construct the class
+
+        :param client: API Client
+        :param base_url: Base Url
+        """
+        self.client = client
+        self.path = urljoin(base_url, "meta")
+
+    def get_meta_information(self):
+        """
+        Returns meta information
+
+        :return: Returns meta information
+        """
+        return self.client.get(self.path)
diff --git a/requirements.txt b/requirements.txt
index 0fda20c..b64cfd9 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -2,7 +2,7 @@ mock==3.0.5
 coveralls==2.0.0
 pytest==5.2.1
 pytest-cov==2.8.1
-requests==2.22.0
+requests==2.26.0
 urllib3==1.26.5
 black==19.3b0
 typing-extensions==3.7.4.2


Test patch:
diff --git a/tests/test_buildkite.py b/tests/test_buildkite.py
index 5bb9d1a..6f5e1db 100644
--- a/tests/test_buildkite.py
+++ b/tests/test_buildkite.py
@@ -11,6 +11,7 @@ from pybuildkite.buildkite import (
     Teams,
     Users,
     Organizations,
+    Meta,
 )
 from pybuildkite.exceptions import NoAcccessTokenException
 
@@ -46,6 +47,7 @@ def test_access_token_set():
         (Buildkite().users, Users),
         (Buildkite().annotations, Annotations),
         (Buildkite().organizations, Organizations),
+        (Buildkite().meta, Meta),
     ],
 )
 def test_eval(function, expected_type):
diff --git a/tests/test_meta.py b/tests/test_meta.py
new file mode 100644
index 0000000..fff0d8c
--- /dev/null
+++ b/tests/test_meta.py
@@ -0,0 +1,10 @@
+from pybuildkite.meta import Meta
+
+
+def test_get_meta_information(fake_client):
+    """
+    Test get user
+    """
+    meta = Meta(fake_client, "https://api.buildkite.com/v2/")
+    meta.get_meta_information()
+    fake_client.get.assert_called_with(meta.path)
diff --git a/tests/test_pipelines.py b/tests/test_pipelines.py
index 4e55fab..c4126de 100644
--- a/tests/test_pipelines.py
+++ b/tests/test_pipelines.py
@@ -51,6 +51,7 @@ def test_create_pipeline(fake_client):
                     "command": "buildkite-agent pipeline upload",
                 }
             ],
+            "team_uuids": None,
         }
     )
 
@@ -86,6 +87,7 @@ def test_create_yaml_pipeline(fake_client):
             "name": "test_pipeline",
             "repository": "my_repo",
             "configuration": "steps:\n  - command: ls",
+            "team_uuids": None,
         },
     )