cleanup and fix test_attachments.py
-# coding=utf-8
-# --------------------------------------------------------------------------
-# Copyright (c) Microsoft Corporation. All rights reserved.
-# Licensed under the MIT License. See License.txt in the project root for
-# license information.
-#
-# Code generated by Microsoft (R) AutoRest Code Generator.
-# Changes may cause incorrect behavior and will be lost if the code is
-# regenerated.
-# --------------------------------------------------------------------------
import os
import base64
import pytest
@@ -29,13 +19,13 @@ CONVERSATION_ID = 'B21UTEF8S:T03CWQ0QB:D2369CT7C'
def get_auth_token():
try:
- import app_creds_real
+ from .app_creds_real import MICROSOFT_APP_ID, MICROSOFT_APP_PASSWORD
# Define a "app_creds_real.py" file with your bot credentials as follows:
# MICROSOFT_APP_ID = '...'
# MICROSOFT_APP_PASSWORD = '...'
return MicrosoftAppCredentials(
- app_creds_real.MICROSOFT_APP_ID,
- app_creds_real.MICROSOFT_APP_PASSWORD).get_accessToken()
+ MICROSOFT_APP_ID,
+ MICROSOFT_APP_PASSWORD).get_access_token()
except ImportError:
return 'STUB_ACCESS_TOKEN'
