Module Expr Str Assign NameStore Str ImportFrom alias identifier ImportFrom alias Import alias Assign NameStore Call AttributeLoad NameLoad attr Str ImportFrom alias identifier ImportFrom alias identifier ImportFrom alias identifier ImportFrom alias identifier ClassDef bases AttributeLoad NameLoad attr body Expr Str FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Str Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Str Assign AttributeStore NameLoad attr Str Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad Num Str Assign NameStore Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad Num Str Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr attr Str Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr attr Str Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr attr Str Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr attr Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore BinOpAdd NameLoad Call NameLoad keyword Num Expr Call AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad Assign NameStore BinOpAdd NameLoad Call NameLoad keyword Num Assign NameStore BinOpAdd NameLoad Call NameLoad keyword Num Expr Call AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str AttributeLoad NameLoad attr SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Str Assign AttributeStore NameLoad attr Num Assign AttributeStore NameLoad attr Num Assign AttributeStore NameLoad attr Num Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Assign NameStore Call AttributeLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr attr Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Assign NameStore Call AttributeLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Str Assign NameStore TupleLoad BinOpAdd Call AttributeLoad NameLoad attr Call NameLoad keyword Num BinOpAdd Call AttributeLoad NameLoad attr Call NameLoad keyword Num Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr keyword AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list decorator_list
N/A N/A 
   Copyright 2013, 2014 Ricardo Tubio-Pardavila

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

       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.
 N/A __author__ rtubiopa@calpoly.edu datetime timedelta py_timedelta django test N/A logging N/A logger N/A N/A logging getLogger simulation services.common misc sn_misc services.common helpers db_tools services.configuration.models tle tle_models services.simulation.models passes pass_models TestModels N/A N/A test TestCase N/A N/A Test class for the pass model methods
     setUp N/A N/A self N/A N/A N/A Database setup for the tests.
         N/A N/A self __verbose_testing False N/A N/A self __user N/A N/A db_tools create_user_profile N/A N/A self __request_1 N/A N/A db_tools create_request user_profile N/A self __user N/A N/A self __gs_1_id gs-uvigo N/A N/A self __gs_1 N/A N/A db_tools create_gs user_profile N/A self __user identifier N/A self __gs_1_id N/A N/A self __sc_1_id xatcobeo-sc N/A N/A self __sc_1_tle_id CANX-2 N/A N/A self __sc_1 N/A N/A db_tools create_sc user_profile N/A self __user identifier N/A self __sc_1_id tle_id N/A self __sc_1_tle_id N/A test_pass_models N/A N/A self N/A N/A N/A UNIT test: services.simulation.create_pass_slots_sc
        Validation of the creation of the pass slots
         N/A sc_slots_1 N/A N/A N/A N/A pass_models PassSlots objects create_pass_slots_sc N/A self __sc_1 N/A N/A N/A self assertIsNot N/A len sc_slots_1 0 Spacecraft pass slots should have been created N/A gs_slots_1 N/A N/A N/A N/A pass_models PassSlots objects create_pass_slots_gs N/A self __gs_1 N/A N/A N/A self assertIsNot N/A len gs_slots_1 0 Groundstation pass slots should have been created N/A N/A N/A self assertTrue N/A N/A N/A N/A N/A N/A pass_models PassSlots objects filter spacecraft N/A self __sc_1 exists Spacecraft associated pass slots should have been created N/A N/A N/A self assertTrue N/A N/A N/A N/A N/A N/A pass_models PassSlots objects filter groundstation N/A self __gs_1 exists GroundStation associated pass slots should have been created N/A N/A N/A N/A N/A pass_models PassSlots objects remove_pass_slots_sc N/A self __sc_1 N/A N/A N/A self assertFalse N/A N/A N/A N/A N/A N/A pass_models PassSlots objects filter spacecraft N/A self __sc_1 exists Spacecraft associated pass slots should have been removed N/A N/A N/A N/A N/A pass_models PassSlots objects remove_pass_slots_gs N/A self __gs_1 N/A N/A N/A self assertFalse N/A N/A N/A N/A N/A N/A pass_models PassSlots objects filter groundstation N/A self __gs_1 exists GroundStation associated pass slots should have been removed N/A test_create_passes N/A N/A self N/A N/A N/A UNIT test: services.simulation.models.passes
        This test validates the creation of an availability slot and the
        further automatic rejections for the creation of availability slots
        that match the start and end of this one.
         N/A slot_s N/A N/A sn_misc get_next_midnight N/A slot_e N/A slot_s N/A py_timedelta days 1 N/A N/A N/A self assertIsNotNone N/A N/A N/A N/A pass_models PassSlots objects create spacecraft N/A self __sc_1 groundstation N/A self __gs_1 start slot_s end slot_e N/A N/A N/A self assertIsNone N/A N/A N/A N/A pass_models PassSlots objects create spacecraft N/A self __sc_1 groundstation N/A self __gs_1 start slot_s end slot_e N/A slot_s N/A slot_s N/A py_timedelta days 1 N/A slot_e N/A slot_s N/A py_timedelta days 1 N/A N/A N/A self assertIsNotNone N/A N/A N/A N/A pass_models PassSlots objects create spacecraft N/A self __sc_1 groundstation N/A self __gs_1 start slot_s end slot_e N/A N/A N/A self assertIsNone N/A N/A N/A N/A pass_models PassSlots objects create spacecraft N/A self __sc_1 groundstation N/A self __gs_1 start slot_s end slot_e N/A test_firebird N/A N/A self N/A N/A N/A UNIT test: Firebird TLE bug
        Test carried out to find what is the problem with the Firebird TLE and
        UVIGO groundstation.
         N/A N/A self __tle_fb N/A N/A N/A N/A tle_models TwoLineElement objects create testingsource N/A db_tools ISS_TLE_ID N/A N/A db_tools ISS_TLE N/A 0 N/A N/A db_tools ISS_TLE N/A 1 N/A N/A self __sc_fb N/A N/A db_tools create_sc user_profile N/A self __user tle_id N/A db_tools ISS_TLE_ID N/A N/A self __gs_uvigo_id uvigo-gs N/A N/A self __gs_uvigo_e 0 N/A N/A self __gs_uvigo_lat 42.170075 N/A N/A self __gs_uvigo_lng -8.68826 N/A N/A self __gs_uvigo N/A N/A db_tools create_gs user_profile N/A self __user identifier N/A self __gs_uvigo_id latitude N/A self __gs_uvigo_lat longitude N/A self __gs_uvigo_lng contact_elevation N/A self __gs_uvigo_e N/A test_passes_reboot N/A N/A self N/A N/A N/A UNIT test: services.simulation.models - passes generation REBOOT
        This test validates that subsequent attempts to generate passes do not
        succeed in case that for the given update window, the passes had
        already been generated.
         N/A N/A N/A logger debug #### FIRST PART OF THE TEST, CURRENT INTERVAL N/A N/A N/A N/A N/A pass_models PassSlots objects propagate N/A sc_passes_n_1 N/A N/A N/A N/A N/A N/A pass_models PassSlots objects filter spacecraft N/A self __sc_1 count N/A N/A N/A N/A N/A pass_models PassSlots objects propagate N/A sc_passes_n_2 N/A N/A N/A N/A N/A N/A pass_models PassSlots objects filter spacecraft N/A self __sc_1 count N/A N/A N/A self assertEquals sc_passes_n_1 sc_passes_n_2 N/A N/A N/A logger debug #### SECOND PART OF THE TEST, FUTURE INTERVAL N/A interval N/A N/A N/A N/A sn_misc get_next_midnight N/A py_timedelta days 30 N/A N/A N/A sn_misc get_next_midnight N/A py_timedelta days 33 N/A N/A N/A N/A N/A pass_models PassSlots objects propagate interval interval N/A sc_passes_n_3 N/A N/A N/A N/A N/A N/A pass_models PassSlots objects filter spacecraft N/A self __sc_1 count N/A N/A N/A self assertGreater sc_passes_n_3 sc_passes_n_2 N/A N/A N/A N/A N/A pass_models PassSlots objects propagate interval interval N/A sc_passes_n_4 N/A N/A N/A N/A N/A N/A pass_models PassSlots objects filter spacecraft N/A self __sc_1 count N/A N/A N/A self assertEquals sc_passes_n_4 sc_passes_n_3 N/A N/A