Fix stations import and EVE API Connection calls.

This commit is contained in:
2013-11-11 21:12:35 +00:00
parent c8f503f053
commit 813358271d
3 changed files with 18 additions and 16 deletions

View File

@@ -1,16 +1,15 @@
"""
This file demonstrates writing tests using the unittest module. These will pass
when you run "manage.py test".
Replace this with more appropriate tests for your application.
"""
from django.test import TestCase
from evesde.models.locations import Station
from evesde.eveapi.eve import import_conquerable_stations
class SimpleTest(TestCase):
def test_basic_addition(self):
"""
Tests that 1 + 1 always equals 2.
"""
self.assertEqual(1 + 1, 2)
class TestConquerableStationsImport(TestCase):
"""Tests the import_conquerable_stations function"""
def setUp(self):
Station.objects.all().delete()
def test_import_stations(self):
import_conquerable_stations()
self.assertGreater(Station.objects.count(), 0)