# Path: firebase_admin/firestore.py
# _FIRESTORE_ATTRIBUTE = '_firestore'
# def client(app=None):
#     def __init__(self, credentials, project):
#     def get(self):
#     def from_app(cls, app):
# class _FirestoreClient:


import datetime
from firebase_admin import firestore
#     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.

"""Integration tests for firebase_admin.firestore module."""



def test_firestore():
    client = firestore.client()
    expected = {
        'name': u'Mountain View',
        'country': u'USA',
        'population': 77846,
        'capital': False
    }
    doc = client.collection('cities').document()
    doc.set(expected)

    data = doc.get().to_dict()
    assert data == expected

    doc.delete()
    assert doc.get().exists is False

def test_server_timestamp():

# Path: firebase_admin/firestore.py
# _FIRESTORE_ATTRIBUTE = '_firestore'
# def client(app=None):
#     def __init__(self, credentials, project):
#     def get(self):
#     def from_app(cls, app):
# class _FirestoreClient:


# Path: integration/test_firestore.py
import datetime
from firebase_admin import firestore

#     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.

"""Integration tests for firebase_admin.firestore module."""



def test_firestore():
    client = firestore.client()
    expected = {
        'name': u'Mountain View',
        'country': u'USA',
        'population': 77846,
        'capital': False
    }
    doc = client.collection('cities').document()
    doc.set(expected)

    data = doc.get().to_dict()
    assert data == expected

    doc.delete()
    assert doc.get().exists is False

def test_server_timestamp():

    client = firestore.client()