Skip to content
This repository was archived by the owner on Nov 20, 2024. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add tests for scenevideo and gazedata url getters
  • Loading branch information
osode authored and m4reko committed Aug 22, 2022
commit 0083c30c7344999b306b9e480b74a4a783423f01
15 changes: 15 additions & 0 deletions tests/api_components/test_recording.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
from datetime import datetime, timedelta
from typing import cast

import aiohttp
import pytest

from g3pylib import Glasses3
Expand Down Expand Up @@ -96,3 +97,17 @@ async def test_meta_data(recording: Recording):
assert meta_keys == ["RuVersion", "HuSerial", "RuSerial", "key1"]
non_existing_message = await recording.meta_lookup("key3")
assert non_existing_message == None


async def test_get_scenevideo_url(recording: Recording):
url = await recording.get_scenevideo_url()
async with aiohttp.ClientSession() as session:
async with session.get(url) as response:
assert response.status == 200


async def test_get_gazedata_url(recording: Recording):
url = await recording.get_gazedata_url()
async with aiohttp.ClientSession() as session:
async with session.get(url) as response:
assert response.status == 200