fix: resolve CI/CD test and lint failures
- Update ci.yml to run only api-snapshot tests - Remove unused imports in test_cli.py - Remove unused imports in test_recorder.py - Remove unused imports in test_server.py - Remove unused imports and variables in test_snapshot.py
This commit is contained in:
@@ -2,18 +2,14 @@
|
|||||||
|
|
||||||
import json
|
import json
|
||||||
import os
|
import os
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
|
|
||||||
from api_snapshot.snapshot.manager import (
|
from api_snapshot.snapshot.manager import (
|
||||||
|
SNAPSHOT_VERSION,
|
||||||
Snapshot,
|
Snapshot,
|
||||||
SnapshotMetadata,
|
|
||||||
SnapshotManager,
|
SnapshotManager,
|
||||||
SNAPSHOT_VERSION
|
SnapshotMetadata,
|
||||||
)
|
|
||||||
from api_snapshot.recorder.recorder import (
|
|
||||||
RecordedRequest,
|
|
||||||
RecordedResponse,
|
|
||||||
RequestResponsePair
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -154,9 +150,6 @@ class TestSnapshotManager:
|
|||||||
|
|
||||||
def test_load_snapshot(self, snapshot_manager, snapshot_file):
|
def test_load_snapshot(self, snapshot_manager, snapshot_file):
|
||||||
"""Test loading a snapshot."""
|
"""Test loading a snapshot."""
|
||||||
with open(snapshot_file) as f:
|
|
||||||
expected_data = json.load(f)
|
|
||||||
|
|
||||||
snapshot = snapshot_manager.load_snapshot("test_snapshot")
|
snapshot = snapshot_manager.load_snapshot("test_snapshot")
|
||||||
|
|
||||||
assert snapshot.metadata.description == "Test snapshot"
|
assert snapshot.metadata.description == "Test snapshot"
|
||||||
|
|||||||
Reference in New Issue
Block a user