def main_function():
    if ct.connection_test() == False:
        print("\nPlease check your internet connection.\n")
        return
    if len(argv) != 3:
        print("\nPlease enter valid input. e.g: wtc-clinic clinician create <date> <time>\n")
        return
    service = calender_api.create_auth_service()
    if auth_interface.check_if_credentials_have_expired():
        return
    username = get_events.get_username()
    add_to_calender(service, username)
Esempio n. 2
0
def main_function():
    if ct.connection_test() == False:
        print("\nPlease check your internet connection.\n")
        return
    if auth_interface.check_if_credentials_have_expired():
        return
    service = calender_api.create_auth_service()
    username = get_events.get_username()
    events, count = get_events.get_events_for_next_7_days_to_delete(
        username, service)
    if count == 0:
        print("\nYou currently don't have any slots created.\n")
Esempio n. 3
0
def main_function():
    if ct.connection_test() == False:
        print("\nPlease check your internet connection.\n")
        return
    if auth_interface.check_if_credentials_have_expired():
        return
    service = calender_api.create_auth_service()
    username = get_events.get_username()
    events, count = get_events.get_all_code_clinic_slots_to_delete(
        service, username)
    if count == 0:
        print("You currently haven't signed up for any Code Clinic.\n")
def main_function():
    if ct.connection_test() == False:
        print("\nPlease check your internet connection.\n")
        return
    if auth_interface.check_if_credentials_have_expired():
        return
    service = calender_api.create_auth_service()
    username = get_events.get_username()
    events, count = get_events.get_all_code_clinic_slots_to_signup(
        service, username)
    if count == 0:
        print(
            "\nThere are currently no available slots for Code Clinics. Check again later."
        )
Esempio n. 5
0
def main_function():
    if ct.connection_test() == False:
        print("\nPlease check your internet connection.\n")
        return
    if len(argv) != 2:
        print(
            "\nPlease enter valid input. e.g: wtc-clinic patient delete <ID>\n"
        )
        return
    service = calender_api.create_auth_service()
    if auth_interface.check_if_credentials_have_expired():
        return
    username = get_events.get_username()
    delete_patient_slot(service, username)
import sys, os, inspect
from io import StringIO


currentdir = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
parentdir = os.path.dirname(currentdir)
sys.path.insert(0, parentdir)

import unittest
import test_base
from unittest.mock import patch
import calender_api
import date_format as df
import datetime
import functions.clinicians.delete_clinician_slot
#import auth_interface

service = calender_api.create_auth_service()

class MyTestCase(unittest.TestCase):
    def test_asfa(self):
        

if __name__=="__main__":
    unittest.main()