Skip to content

Commit

Permalink
added more sorted files
Browse files Browse the repository at this point in the history
  • Loading branch information
dineshkrishnareddy committed Oct 4, 2019
1 parent c3ca96a commit 936ea95
Show file tree
Hide file tree
Showing 81 changed files with 95 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .isort.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ line_length=79
; docs: https://github.com/timothycrosley/isort#multi-line-output-modes
multi_line_output=3
known_future_library = six,six.moves,__future__
known_third_party=google,google.rpc
known_third_party=google,mock,pymysql,sqlalchemy,psycopg2
known_first_party=opencensus
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import unittest

import mock

from opencensus.ext.azure import log_exporter

TEST_FOLDER = os.path.abspath('.test.logs')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
from datetime import datetime

import mock

from opencensus.common import utils
from opencensus.ext.azure import metrics_exporter
from opencensus.ext.azure.common import Options
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import unittest

import mock

import requests
from opencensus.ext.azure.metrics_exporter import standard_metrics
from opencensus.trace import execution_context
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import unittest

import mock

from opencensus.ext.azure import trace_exporter

TEST_FOLDER = os.path.abspath('.test.exporter')
Expand Down
1 change: 1 addition & 0 deletions contrib/opencensus-ext-azure/tests/test_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import unittest

import mock

from opencensus.ext.azure.common.storage import (
LocalFileBlob,
LocalFileStorage,
Expand Down
1 change: 1 addition & 0 deletions contrib/opencensus-ext-datadog/tests/traces_test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import unittest

import mock

from opencensus.ext.datadog.traces import (
DatadogTraceExporter,
Options,
Expand Down
1 change: 1 addition & 0 deletions contrib/opencensus-ext-datadog/tests/transport_test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import unittest

import mock

from opencensus.ext.datadog.transport import DDTransport


Expand Down
1 change: 1 addition & 0 deletions contrib/opencensus-ext-dbapi/tests/test_dbapi_trace.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.dbapi import trace


Expand Down
5 changes: 3 additions & 2 deletions contrib/opencensus-ext-django/examples/app/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,11 @@

import os

import mysql.connector
import psycopg2
import requests
import sqlalchemy

import mysql.connector
import requests
from django.http import HttpResponse
from django.shortcuts import render
from opencensus.trace import config_integration
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,9 @@
import unittest
from collections import namedtuple

import django
import mock

import django
import pytest
from django.test.utils import teardown_test_environment
from opencensus.trace import execution_context
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from django.test import RequestFactory
from django.test.utils import teardown_test_environment
from opencensus.trace import execution_context, print_exporter, samplers
Expand Down
5 changes: 3 additions & 2 deletions contrib/opencensus-ext-flask/examples/custom.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,15 @@

import os

import psycopg2
import sqlalchemy

import flask
import grpc
import hello_world_pb2
import hello_world_pb2_grpc
import mysql.connector
import psycopg2
import requests
import sqlalchemy
from opencensus.ext.flask.flask_middleware import FlaskMiddleware
from opencensus.ext.grpc import client_interceptor
from opencensus.ext.stackdriver import trace_exporter as stackdriver_exporter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@

import unittest

import mock
from google.rpc import code_pb2

import flask
import mock
from opencensus.ext.flask import flask_middleware
from opencensus.trace import execution_context, print_exporter, samplers
from opencensus.trace import span as span_module
Expand Down
3 changes: 2 additions & 1 deletion contrib/opencensus-ext-gevent/tests/test_patching.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@

import unittest

import gevent.monkey
import mock

import gevent.monkey
import opencensus.common.runtime_context as runtime_context


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@

import unittest

import grpc
import mock

import grpc
from opencensus.ext.google_cloud_clientlibs import trace


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@
import threading
import unittest

import mock
from google.api_core import bidi
from google.protobuf import proto_builder

import grpc
import mock
from grpc.framework.foundation import logging_pool
from opencensus.ext.grpc import client_interceptor
from opencensus.trace import execution_context
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@

import unittest

import mock
from google.rpc import code_pb2

import mock
from opencensus.ext.grpc import server_interceptor
from opencensus.ext.grpc import utils as grpc_utils
from opencensus.trace import execution_context
Expand Down
1 change: 1 addition & 0 deletions contrib/opencensus-ext-httplib/tests/test_httplib_trace.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.httplib import trace
from opencensus.trace import span as span_module
from opencensus.trace.propagation import trace_context_http_header_format
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.jaeger import trace_exporter
from opencensus.ext.jaeger.trace_exporter.gen.jaeger import jaeger
from opencensus.trace import (
Expand Down
1 change: 1 addition & 0 deletions contrib/opencensus-ext-mysql/tests/test_mysql_trace.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.mysql import trace


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@
from concurrent import futures
from datetime import datetime

import mock
from google.protobuf import timestamp_pb2

import grpc
import mock
from opencensus.common import resource, utils
from opencensus.common.version import __version__ as opencensus_version
from opencensus.ext.ocagent import stats_exporter as ocagent
Expand Down
3 changes: 2 additions & 1 deletion contrib/opencensus-ext-ocagent/tests/test_trace_exporter.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,9 @@
import socket
import unittest

import grpc
import mock

import grpc
from opencensus.common.version import __version__
from opencensus.ext.ocagent.trace_exporter import TraceExporter
from opencensus.proto.trace.v1 import trace_config_pb2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,12 @@
import logging

import psycopg2
from opencensus.trace import execution_context
from opencensus.trace import span as span_module
from psycopg2 import connect as pg_connect
from psycopg2.extensions import cursor as pgcursor

from opencensus.trace import execution_context
from opencensus.trace import span as span_module

log = logging.getLogger(__name__)

MODULE_NAME = 'postgresql'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.postgresql import trace


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
from datetime import datetime

import mock

from opencensus.ext.prometheus import stats_exporter as prometheus
from opencensus.stats import aggregation as aggregation_module
from opencensus.stats import measure as measure_module
Expand Down
1 change: 1 addition & 0 deletions contrib/opencensus-ext-pymongo/tests/test_pymongo_trace.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.pymongo import trace


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
import logging

import pymysql

from opencensus.ext.dbapi import trace

MODULE_NAME = 'pymysql'
Expand Down
1 change: 1 addition & 0 deletions contrib/opencensus-ext-pymysql/tests/test_pymysql_trace.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.pymysql import trace


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.pyramid import config


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import unittest

import mock

from opencensus.common.transports import sync
from opencensus.ext.pyramid import pyramid_middleware
from opencensus.ext.zipkin import trace_exporter as zipkin_exporter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

import requests
from opencensus.ext.requests import trace
from opencensus.trace import execution_context
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@

import logging

from sqlalchemy import engine, event

from opencensus.trace import execution_context
from opencensus.trace import span as span_module
from sqlalchemy import engine, event

log = logging.getLogger(__name__)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.ext.sqlalchemy import trace
from opencensus.trace import span as span_module

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import unittest

import mock

from opencensus.common.version import __version__
from opencensus.ext.stackdriver import trace_exporter
from opencensus.trace import span_context
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
from datetime import datetime

import google.auth
import mock
from google.cloud import monitoring_v3

import mock
from opencensus.common import utils
from opencensus.common.version import __version__
from opencensus.ext.stackdriver import stats_exporter as stackdriver
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
from multiprocessing.pool import Pool

import mock

from opencensus.ext.threading import trace
from opencensus.trace import execution_context, tracer

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
from datetime import datetime

import mock

from opencensus.ext.zipkin import trace_exporter
from opencensus.trace import span_context
from opencensus.trace import span_data as span_data_module
Expand Down
2 changes: 1 addition & 1 deletion tests/system/stats/stackdriver/stackdriver_stats_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
import sys
import time

import mock
from google.cloud import monitoring_v3

import mock
from opencensus.ext.stackdriver import stats_exporter as stackdriver
from opencensus.metrics import transport
from opencensus.stats import aggregation as aggregation_module
Expand Down
3 changes: 2 additions & 1 deletion tests/system/trace/django/app/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@

import os

import mysql.connector
import psycopg2
import sqlalchemy

import mysql.connector
from django.http import HttpResponse
from django.shortcuts import render
from opencensus.trace import config_integration
Expand Down
5 changes: 3 additions & 2 deletions tests/system/trace/flask/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,11 @@

import os

import flask
import mysql.connector
import psycopg2
import sqlalchemy

import flask
import mysql.connector
from opencensus.common.transports import async_
from opencensus.ext.flask.flask_middleware import FlaskMiddleware
from opencensus.ext.stackdriver import trace_exporter as stackdriver_exporter
Expand Down
Loading

0 comments on commit 936ea95

Please sign in to comment.