code stringlengths 9 256k |
|---|
<s> """<STR_LIT>""" <EOL> from cloudcafe . common . models . configuration import ConfigSectionInterface <EOL> class OpenstackCLI_CommonConfig ( ConfigSectionInterface ) : <EOL> SECTION_NAME = '<STR_LIT>' <EOL> @ property <EOL> def debug ( self ) : <EOL> """<STR_LIT>""" <EOL> return self . get_boolean ( '<STR_LIT>' , d... |
<s> """<STR_LIT>""" <EOL> import unittest <EOL> import json <EOL> from cloudcafe . blockstorage . volumes_api . v2 . models import responses <EOL> class BaseTest ( object ) : <EOL> @ classmethod <EOL> def setUpClass ( cls ) : <EOL> cls . model = cls . model_type . deserialize ( <EOL> cls . serialized_input , cls . dese... |
<s> """<STR_LIT>""" <EOL> class HostsMockResponse ( ) : <EOL> def __init__ ( self , format ) : <EOL> self . format = format <EOL> def list_hosts ( self ) : <EOL> return getattr ( self , '<STR_LIT>' . format ( self . format ) ) ( ) <EOL> def get_host ( self ) : <EOL> return getattr ( self , '<STR_LIT>' . format ( self .... |
<s> """<STR_LIT>""" <EOL> import unittest <EOL> from cloudcafe . networking . lbaas . common . constants import Constants <EOL> from cloudcafe . networking . lbaas . lbaas_api . health_monitor . response import HealthMonitor , HealthMonitors <EOL> class BaseHealthMonitorResponseTest ( unittest . TestCase ) : <EOL> """<... |
<s> """<STR_LIT>""" <EOL> VALID_CONTAINER_NAME = '<STR_LIT:foo>' </s>
|
<s> from cafe . drivers . unittest . decorators import data_driven_test , DataDrivenFixture , tags <EOL> from cloudcafe . blockstorage . datasets import BlockstorageDatasets <EOL> from cloudroast . blockstorage . volumes_api . integration . oscli . fixtures import NovaCLI_IntegrationFixture <EOL> volume_type_complete_d... |
<s> """<STR_LIT>""" <EOL> import unittest <EOL> from cafe . drivers . unittest . decorators import tags <EOL> from cloudcafe . common . tools . datagen import rand_name <EOL> from cloudcafe . compute . common . exceptions import ItemNotFound <EOL> from cloudcafe . compute . common . types import NovaImageStatusTypes <E... |
<s> """<STR_LIT>""" <EOL> import base64 <EOL> from cafe . drivers . unittest . decorators import tags <EOL> from cloudcafe . common . tools . datagen import rand_name <EOL> from cloudroast . compute . fixtures import ComputeFixture <EOL> class CloudInitIncludeTest ( ComputeFixture ) : <EOL> @ classmethod <EOL> def setU... |
<s> """<STR_LIT>""" <EOL> import unittest <EOL> from cafe . drivers . unittest . decorators import tags <EOL> from cloudcafe . common . tools . datagen import rand_name <EOL> from cloudcafe . compute . common . types import ComputeHypervisors , NovaServerStatusTypes <EOL> from cloudcafe . compute . config import Comput... |
<s> """<STR_LIT>""" <EOL> from cafe . drivers . unittest . decorators import tags <EOL> from cloudcafe . common . tools . datagen import rand_name <EOL> from cloudroast . compute . instance_actions . api . test_rebuild_server import RebuildServerTests , RebuildBaseFixture <EOL> from cloudroast . compute . fixtures impo... |
<s> """<STR_LIT>""" <EOL> from test_repo . database . fixtures import DBaaSFixture <EOL> class test_hosts ( DBaaSFixture ) : <EOL> instance_id = None <EOL> dbaas = None <EOL> @ classmethod <EOL> def setUpClass ( cls ) : <EOL> """<STR_LIT>""" <EOL> super ( test_hosts , cls ) . setUpClass ( ) <EOL> cls . mgmt_dbaas = cls... |
<s> """<STR_LIT>""" <EOL> import unittest <EOL> from cloudcafe . common . tools . datagen import rand_name <EOL> from cloudcafe . glance . common . constants import Messages <EOL> from cloudcafe . glance . common . types import ImageMemberStatus <EOL> from cloudroast . glance . fixtures import ImagesFixture <EOL> class... |
<s> from random import randint <EOL> import unittest <EOL> from cloudroast . identity . v2_0 . fixtures import IdentityBaseTestFixture <EOL> class BaseOSKSADMApiSmoke ( object ) : <EOL> GET_STATUS_CODE = <NUM_LIT:200> <EOL> CREATE_STATUS_CODE = <NUM_LIT:200> <EOL> UPDATE_STATUS_CODE = <NUM_LIT:200> <EOL> DELETE_STATUS_... |
<s> """<STR_LIT>""" <EOL> from cafe . drivers . unittest . decorators import tags <EOL> from cloudroast . images . fixtures import ImagesFixture <EOL> class TestGetImageMember ( ImagesFixture ) : <EOL> @ tags ( type = '<STR_LIT>' ) <EOL> def test_get_image_member ( self ) : <EOL> """<STR_LIT>""" <EOL> member_id = self ... |
<s> """<STR_LIT>""" <EOL> import unittest2 as unittest <EOL> from cafe . drivers . unittest . decorators import tags <EOL> from cloudcafe . common . tools . datagen import rand_name <EOL> from cloudcafe . images . config import ImagesConfig <EOL> from cloudroast . images . fixtures import ImagesFixture <EOL> images_con... |
<s> """<STR_LIT>""" <EOL> from cafe . drivers . unittest . decorators import tags <EOL> from cafe . drivers . unittest . fixtures import BaseTestFixture <EOL> from cloudcafe . networking . networks . extensions . limits_api . composites import LimitsComposite <EOL> class LimitsGetTest ( BaseTestFixture ) : <EOL> @ clas... |
<s> """<STR_LIT>""" <EOL> from cloudcafe . common . tools import randomstring as randstring <EOL> from cafe . drivers . unittest . decorators import data_driven_test <EOL> from cafe . drivers . unittest . decorators import DataDrivenFixture <EOL> from cloudroast . objectstorage . fixtures import ObjectStorageFixture <E... |
<s> """<STR_LIT>""" <EOL> from datetime import datetime , timedelta <EOL> from cafe . drivers . unittest . fixtures import BaseTestFixture <EOL> from cloudcafe . common . tools . datagen import rand_name <EOL> from cloudcafe . common . tools . time import string_to_datetime <EOL> from cloudcafe . compute . common . con... |
<s> """<STR_LIT>""" <EOL> import logging <EOL> import os <EOL> import os . path <EOL> import sys <EOL> current_dir = os . path . dirname ( os . path . realpath ( __file__ ) ) <EOL> sys . path . append ( current_dir ) <EOL> import switch_virtualenv <EOL> from compass . actions import clean <EOL> from compass . db . api ... |
<s> """<STR_LIT>""" <EOL> import commands <EOL> import os <EOL> import platform <EOL> import re <EOL> def validate_setting ( module , setting , param ) : <EOL> """<STR_LIT>""" <EOL> if hasattr ( setting , param ) : <EOL> return True <EOL> else : <EOL> err_msg = "<STR_LIT>" % ( module , param ) <EOL> return err_msg <EOL... |
<s> """<STR_LIT>""" <EOL> import logging <EOL> import netaddr <EOL> import re <EOL> from compass . db . api import database <EOL> from compass . db . api import permission <EOL> from compass . db . api import user as user_api <EOL> from compass . db . api import utils <EOL> from compass . db import exception <EOL> from... |
<s> """<STR_LIT>""" <EOL> from compass . hdsdiscovery import base <EOL> CLASS_NAME = '<STR_LIT>' <EOL> class Arista ( base . BaseSnmpVendor ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self ) : <EOL> base . BaseSnmpVendor . __init__ ( self , [ '<STR_LIT>' ] ) <EOL> self . _name = '<STR_LIT>' <EOL> @ property <EOL> de... |
<s> import datetime <EOL> import logging <EOL> import os <EOL> import unittest2 <EOL> os . environ [ '<STR_LIT>' ] = '<STR_LIT:true>' <EOL> from compass . utils import setting_wrapper as setting <EOL> reload ( setting ) <EOL> from base import BaseTest <EOL> from compass . db . api import database <EOL> from compass . d... |
<s> """<STR_LIT>""" <EOL> try : <EOL> from setuptools import find_packages <EOL> except ImportError : <EOL> from ez_setup import use_setuptools <EOL> use_setuptools ( ) <EOL> from setuptools . command . test import test as TestCommand <EOL> from setuptools import setup <EOL> import os <EOL> import sys <EOL> class Tox (... |
<s> import mock <EOL> from os_win import exceptions as os_win_exc <EOL> from hyperv . nova . cluster import livemigrationops <EOL> from hyperv . nova import livemigrationops as base_livemigrationops <EOL> from hyperv . tests import fake_instance <EOL> from hyperv . tests . unit import test_base <EOL> class ClusterLiveM... |
<s> class KeystoneAuthException ( Exception ) : <EOL> """<STR_LIT>""" <EOL> pass </s>
|
<s> from oslo_utils import excutils <EOL> import six <EOL> from dragonflow . _i18n import _ <EOL> class DragonflowException ( Exception ) : <EOL> """<STR_LIT>""" <EOL> message = _ ( "<STR_LIT>" ) <EOL> def __init__ ( self , ** kwargs ) : <EOL> try : <EOL> super ( DragonflowException , self ) . __init__ ( self . message... |
<s> import retrying <EOL> import six <EOL> import threading <EOL> from dragonflow . common import constants <EOL> from dragonflow . db import api_vswitch <EOL> from neutron . agent . ovsdb import impl_idl <EOL> from neutron . agent . ovsdb . native import commands <EOL> from neutron . agent . ovsdb . native . commands ... |
<s> from dragonflow . controller . common import constants as const <EOL> from dragonflow . tests . common import utils <EOL> from dragonflow . tests . fullstack import test_base <EOL> from dragonflow . tests . fullstack import test_objects as objects <EOL> import re <EOL> class TestL2Multicast ( test_base . DFTestBase... |
<s> import netaddr <EOL> from oslo_config import cfg <EOL> from oslo_log import log as logging <EOL> from ec2api . api import common <EOL> from ec2api . api import ec2utils <EOL> from ec2api import clients <EOL> from ec2api . db import api as db_api <EOL> from ec2api import exception <EOL> from ec2api . i18n import _ <... |
<s> """<STR_LIT>""" <EOL> from eventlet import tpool <EOL> from oslo_config import cfg <EOL> from oslo_db import api as db_api <EOL> from oslo_log import log as logging <EOL> tpool_opts = [ <EOL> cfg . BoolOpt ( '<STR_LIT>' , <EOL> default = False , <EOL> deprecated_name = '<STR_LIT>' , <EOL> deprecated_group = '<STR_L... |
<s> import time <EOL> import botocore . exceptions <EOL> from oslo_log import log <EOL> from tempest . lib . common . utils import data_utils <EOL> import testtools <EOL> from ec2api . tests . functional import base <EOL> from ec2api . tests . functional import config <EOL> CONF = config . CONF <EOL> LOG = log . getLog... |
<s> from oslo_log import log <EOL> from tempest . lib . common import ssh <EOL> from tempest . lib . common . utils import data_utils <EOL> import testtools <EOL> from ec2api . tests . functional import base <EOL> from ec2api . tests . functional import config <EOL> from ec2api . tests . functional . scenario import ba... |
<s> import mock <EOL> from neutronclient . common import exceptions as neutron_exception <EOL> from ec2api . tests . unit import base <EOL> from ec2api . tests . unit import fakes <EOL> from ec2api . tests . unit import matchers <EOL> from ec2api . tests . unit import tools <EOL> class IgwTestCase ( base . ApiTestCase ... |
<s> """<STR_LIT>""" <EOL> import datetime <EOL> import glob <EOL> import os <EOL> import subprocess <EOL> import sys <EOL> def dump_db ( db_driver , db_name , migration_version , dump_filename ) : <EOL> db_driver . create ( db_name ) <EOL> try : <EOL> migrate ( db_driver , db_name , migration_version ) <EOL> db_driver ... |
<s> import sys <EOL> import os <EOL> extensions = [ <EOL> '<STR_LIT>' , <EOL> ] <EOL> templates_path = [ '<STR_LIT>' ] <EOL> source_suffix = '<STR_LIT>' <EOL> master_doc = '<STR_LIT:index>' <EOL> project = u'<STR_LIT>' <EOL> copyright = u'<STR_LIT>' <EOL> version = '<STR_LIT>' <EOL> release = '<STR_LIT>' <EOL> exclude_... |
<s> from oslo_serialization import jsonutils as json <EOL> from tempest import config <EOL> from tempest . lib . common import rest_client <EOL> CONF = config . CONF <EOL> class FreezerApiClient ( rest_client . RestClient ) : <EOL> def __init__ ( self , auth_provider ) : <EOL> super ( FreezerApiClient , self ) . __init... |
<s> import logging <EOL> from django import shortcuts <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from horizon import exceptions <EOL> from horizon import forms <EOL> from horizon import workflows <EOL> import disaster_recovery . api . api as freezer_api <EOL> LOG = logging . getLogger ( __n... |
<s> from django . conf . urls import patterns <EOL> from django . conf . urls import url <EOL> from disaster_recovery . sessions import views <EOL> urlpatterns = patterns ( <EOL> '<STR_LIT>' , <EOL> url ( r'<STR_LIT>' , <EOL> views . SessionsView . as_view ( ) , <EOL> name = '<STR_LIT:index>' ) , <EOL> url ( r'<STR_LIT... |
<s> """<STR_LIT>""" <EOL> import json <EOL> import os <EOL> import subprocess <EOL> import sys <EOL> from oslo_config import cfg <EOL> from oslo_log import log <EOL> from freezer . common import config as freezer_config <EOL> from freezer . engine . tar import tar_engine <EOL> from freezer import job <EOL> from freezer... |
<s> from oslo_config import cfg <EOL> service_available_group = cfg . OptGroup ( name = "<STR_LIT>" , <EOL> title = "<STR_LIT>" ) <EOL> ServiceAvailableGroup = [ <EOL> cfg . BoolOpt ( "<STR_LIT>" , <EOL> default = True , <EOL> help = "<STR_LIT>" ) , <EOL> ] </s>
|
<s> import unittest <EOL> from freezer . scheduler import scheduler_job <EOL> class TestSchedulerJob ( unittest . TestCase ) : <EOL> def setUp ( self ) : <EOL> self . job = scheduler_job . Job ( None , None , { "<STR_LIT>" : { } } ) <EOL> def test ( self ) : <EOL> scheduler_job . RunningState . stop ( self . job , { } ... |
<s> import logging <EOL> import six <EOL> from fuel_dev_tools import command <EOL> class BasicInfo ( object ) : <EOL> pass <EOL> class Info ( command . BaseCommand ) : <EOL> """<STR_LIT>""" <EOL> log = logging . getLogger ( __name__ ) <EOL> def take_action ( self , parsed_args ) : <EOL> urls = [ <EOL> ( '<STR_LIT>' , <... |
<s> SCANCODES = { <EOL> '<STR_LIT:1>' : <NUM_LIT> , <EOL> '<STR_LIT:2>' : <NUM_LIT> , <EOL> '<STR_LIT:3>' : <NUM_LIT> , <EOL> '<STR_LIT:4>' : <NUM_LIT> , <EOL> '<STR_LIT:5>' : <NUM_LIT> , <EOL> '<STR_LIT>' : <NUM_LIT> , <EOL> '<STR_LIT>' : <NUM_LIT> , <EOL> '<STR_LIT>' : <NUM_LIT> , <EOL> '<STR_LIT>' : <NUM_LIT> , <EOL... |
<s> from django . test import TestCase <EOL> from devops . models import Environment <EOL> class DriverlessTestCase ( TestCase ) : <EOL> def setUp ( self ) : <EOL> self . env = Environment . create ( name = '<STR_LIT:test>' ) <EOL> self . admin_ap = self . env . add_address_pool ( <EOL> name = '<STR_LIT>' , net = '<STR... |
<s> from netaddr import IPNetwork <EOL> from devops . helpers . ssh_client import SSHClient <EOL> from devops . models import DiskDevice <EOL> from devops . models import Environment <EOL> from devops . models import Interface <EOL> from devops . models import Network <EOL> from devops . models import Node <EOL> from d... |
<s> import six <EOL> from nailgun . api . v1 . handlers import base <EOL> from nailgun . api . v1 . handlers . base import content <EOL> from nailgun . api . v1 . validators . role import RoleValidator <EOL> from nailgun import errors <EOL> from nailgun import objects <EOL> from nailgun . objects . serializers . role i... |
<s> from distutils . version import StrictVersion <EOL> from nailgun . api . v1 . validators . base import BasicValidator <EOL> from nailgun import consts <EOL> from nailgun . db import db <EOL> from nailgun import errors <EOL> from nailgun import objects <EOL> from nailgun . api . v1 . validators . json_schema import ... |
<s> from sqlalchemy import Boolean <EOL> from sqlalchemy import Column <EOL> from sqlalchemy import DateTime <EOL> from sqlalchemy import Enum <EOL> from sqlalchemy import Integer <EOL> from sqlalchemy import String <EOL> from nailgun . db . sqlalchemy . models . base import Base <EOL> from nailgun . db . sqlalchemy . ... |
<s> from . base import NailgunException <EOL> class ExpressionParserException ( NailgunException ) : <EOL> """<STR_LIT>""" <EOL> class LexError ( ExpressionParserException ) : <EOL> message = "<STR_LIT>" <EOL> class ParseError ( ExpressionParserException ) : <EOL> message = "<STR_LIT>" <EOL> class UnknownModel ( Expres... |
<s> from itertools import chain <EOL> from stevedore . extension import ExtensionManager <EOL> from nailgun import errors <EOL> from nailgun . extensions import consts <EOL> _EXTENSION_MANAGER = None <EOL> def get_all_extensions ( ) : <EOL> """<STR_LIT>""" <EOL> global _EXTENSION_MANAGER <EOL> if _EXTENSION_MANAGER is ... |
<s> from netaddr import IPNetwork <EOL> from oslo_serialization import jsonutils <EOL> import six <EOL> from nailgun . api . v1 . validators . base import BasicValidator <EOL> from nailgun . api . v1 . validators . json_schema import iface_schema <EOL> from nailgun import consts <EOL> from nailgun . db import db <EOL> ... |
<s> </s>
|
<s> from nailgun . objects . serializers . base import BasicSerializer <EOL> class DeploymentHistorySerializer ( BasicSerializer ) : <EOL> fields = ( <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" , <EOL> "<STR_LIT:status>" , <EOL> "<STR_LIT>" <EOL> ) <EOL> @ classmethod <EOL> def seriali... |
<s> from oslo_serialization import jsonutils <EOL> import requests <EOL> import six <EOL> from nailgun import consts <EOL> from nailgun . logger import logger <EOL> from nailgun . settings import settings <EOL> from nailgun . utils import debian <EOL> def make_upload_task ( uids , data , path ) : <EOL> return { <EOL> '... |
<s> try : <EOL> from unittest . case import TestCase <EOL> except ImportError : <EOL> from unittest2 . case import TestCase <EOL> import copy <EOL> import mock <EOL> import os <EOL> import re <EOL> import six <EOL> from six . moves import range <EOL> import uuid <EOL> from datetime import datetime <EOL> from functools ... |
<s> import copy <EOL> from random import randint <EOL> from nailgun import consts <EOL> from nailgun import objects <EOL> from nailgun . db . sqlalchemy . models import NetworkGroup <EOL> from nailgun . orchestrator . provisioning_serializers import serialize as prov_serializer <EOL> from nailgun . test . integration .... |
<s> from mock import patch <EOL> from nailgun import consts <EOL> from nailgun import objects <EOL> from nailgun . test . base import BaseIntegrationTest <EOL> from nailgun . test . base import fake_tasks <EOL> class TestProvisioning ( BaseIntegrationTest ) : <EOL> @ fake_tasks ( fake_rpc = False , mock_rpc = False ) <... |
<s> import sys <EOL> from mock import patch <EOL> from nailgun . test . base import BaseTestCase <EOL> from nailgun import consts <EOL> from nailgun . objects import Cluster <EOL> from nailgun . objects import OpenStackWorkloadStats <EOL> from nailgun . statistics . oswl . collector import collect as oswl_collect_once ... |
<s> import inspect <EOL> from nailgun import errors <EOL> from nailgun . expression import Expression <EOL> from nailgun . test . base import BaseTestCase <EOL> class TestExpressionParser ( BaseTestCase ) : <EOL> def test_expression_parser ( self ) : <EOL> cluster = self . env . create_cluster ( api = False , mode = '<... |
<s> from oslo_serialization import jsonutils <EOL> from nailgun . extensions . network_manager . validators . network import NetworkTemplateValidator <EOL> from nailgun . test . base import BaseValidatorTest <EOL> class BaseNetworkTemplateValidatorTest ( BaseValidatorTest ) : <EOL> validator = NetworkTemplateValidator ... |
<s> from nailgun . api . v1 . validators . json_schema import base_types <EOL> from nailgun . api . v1 . validators . json_schema import role <EOL> from nailgun . api . v1 . validators . role import RoleValidator <EOL> from nailgun import errors <EOL> from nailgun . test . base import BaseUnitTest <EOL> class TestRoleV... |
<s> import logging <EOL> import os <EOL> import shutil <EOL> import sys <EOL> from nailgun import consts <EOL> from nailgun . db import db <EOL> from nailgun . db . sqlalchemy . models import IPAddr <EOL> from nailgun . db . sqlalchemy . models import NetworkGroup <EOL> from nailgun . db . sqlalchemy . models import No... |
<s> """<STR_LIT>""" <EOL> revision = '<STR_LIT>' <EOL> down_revision = '<STR_LIT>' <EOL> import warnings <EOL> from alembic import op <EOL> import sqlalchemy as sa <EOL> from gertty . dbsupport import sqlite_alter_columns , sqlite_drop_columns <EOL> def upgrade ( ) : <EOL> with warnings . catch_warnings ( ) : <EOL> war... |
<s> def mouse_event_scrolling ( class_type ) : <EOL> def mouse_event_scrolling ( self , size , event , button , col , row , focus ) : <EOL> if event == '<STR_LIT>' : <EOL> if button == <NUM_LIT:4> : <EOL> self . keypress ( size , '<STR_LIT>' ) <EOL> return True <EOL> if button == <NUM_LIT:5> : <EOL> self . keypress ( s... |
<s> """<STR_LIT>""" <EOL> import inspect <EOL> import os <EOL> from testscenarios import TestWithScenarios <EOL> from testtools . content import text_content <EOL> from testtools . matchers import Contains <EOL> from testtools . matchers import Equals <EOL> from git_upstream . lib . pygitcompat import Commit <EOL> from... |
<s> """<STR_LIT>""" <EOL> import logging <EOL> from oslo_config import cfg <EOL> from six . moves import urllib <EOL> from glance_store import exceptions <EOL> CONF = cfg . CONF <EOL> LOG = logging . getLogger ( __name__ ) <EOL> SCHEME_TO_CLS_MAP = { } <EOL> def get_location_from_uri ( uri , conf = CONF ) : <EOL> """<S... |
<s> from heat . common import exception <EOL> from heat . engine import resource <EOL> from heat . engine import scheduler <EOL> from oslo_log import log as logging <EOL> LOG = logging . getLogger ( __name__ ) <EOL> class GBPResource ( resource . Resource ) : <EOL> default_client_name = '<STR_LIT>' <EOL> def grouppolic... |
<s> import logging <EOL> from django . core . urlresolvers import reverse <EOL> from django import http <EOL> from django import shortcuts <EOL> from django . utils import html <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from horizon import exceptions <EOL> from horizon import forms <EOL> fr... |
<s> import netaddr <EOL> from neutron . api . v2 import attributes as attr <EOL> from neutron import context <EOL> from neutron . db import common_db_mixin <EOL> from neutron . db import model_base <EOL> from neutron . db import models_v2 <EOL> from oslo_log import helpers as log <EOL> from oslo_log import log as loggi... |
<s> from keystoneclient import exceptions as k_exceptions <EOL> from keystoneclient . v2_0 import client as k_client <EOL> from neutron . _i18n import _LE <EOL> from neutron . db import model_base <EOL> from neutron . db import models_v2 <EOL> from oslo_config import cfg <EOL> from oslo_log import helpers as log <EOL> ... |
<s> from neutron import manager <EOL> from neutron . plugins . common import constants as pconst <EOL> from gbpservice . common import utils <EOL> from gbpservice . neutron . services . grouppolicy . drivers import resource_mapping <EOL> from gbpservice . neutron . services . servicechain . plugins . ncp import model <... |
<s> import requests <EOL> import unittest <EOL> import mock <EOL> from oslo_serialization import jsonutils <EOL> from gbpservice . neutron . services . grouppolicy import config <EOL> from gbpservice . neutron . services . grouppolicy . drivers . odl import odl_manager <EOL> HOST = '<STR_LIT>' <EOL> PORT = '<STR_LIT>' ... |
<s> import commands <EOL> import logging <EOL> import sys <EOL> from libs import config_libs <EOL> from libs import utils_libs <EOL> from libs import verify_libs <EOL> def main ( ) : <EOL> test = test_gbp_nsp_func ( ) <EOL> if test . test_gbp_nsp_func_1 ( ) == <NUM_LIT:0> : <EOL> test . cleanup ( tc_name = '<STR_LIT>' ... |
<s> from django import forms <EOL> from django . forms . forms import NON_FIELD_ERRORS <EOL> class SelfHandlingMixin ( object ) : <EOL> def __init__ ( self , request , * args , ** kwargs ) : <EOL> self . request = request <EOL> if not hasattr ( self , "<STR_LIT>" ) : <EOL> raise NotImplementedError ( "<STR_LIT>" <EOL> ... |
<s> import logging <EOL> import os <EOL> import socket <EOL> import time <EOL> import unittest <EOL> from django . contrib . auth . middleware import AuthenticationMiddleware <EOL> from django . contrib . auth . models import Permission <EOL> from django . contrib . auth . models import User <EOL> from django . contrib... |
<s> from __future__ import division <EOL> from csv import DictWriter <EOL> from csv import writer <EOL> from django . http import HttpResponse <EOL> from django . http import StreamingHttpResponse <EOL> from django import template as django_template <EOL> import six <EOL> from six import StringIO <EOL> class CsvDataMix... |
<s> import json <EOL> import json . encoder as encoder <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> import six <EOL> class NaNJSONEncoder ( json . JSONEncoder ) : <EOL> def __init__ ( self , nan_str = '<STR_LIT>' , inf_str = '<STR_LIT>' , ** kwargs ) : <EOL> self . nan_str = nan_str <EOL> sel... |
<s> from django . utils . translation import ugettext_lazy as _ <EOL> from horizon import tables <EOL> class QuotaFilterAction ( tables . FilterAction ) : <EOL> def filter ( self , table , tenants , filter_string ) : <EOL> q = filter_string . lower ( ) <EOL> def comp ( tenant ) : <EOL> if q in tenant . name . lower ( )... |
<s> from django . conf . urls import url <EOL> from openstack_dashboard . dashboards . admin . images import views <EOL> urlpatterns = [ <EOL> url ( r'<STR_LIT>' , views . IndexView . as_view ( ) , name = '<STR_LIT:index>' ) , <EOL> url ( r'<STR_LIT>' , views . CreateView . as_view ( ) , name = '<STR_LIT>' ) , <EOL> ur... |
<s> import logging <EOL> from django . core . urlresolvers import reverse <EOL> from django . template import defaultfilters as filters <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from django . utils . translation import ungettext_lazy <EOL> from horizon import exceptions <EOL> from horizon ... |
<s> from django . utils . translation import ugettext_lazy as _ <EOL> from horizon import tables <EOL> from openstack_dashboard . dashboards . project . routers . ports import tables as routers_tables <EOL> class PortsTable ( routers_tables . PortsTable ) : <EOL> name = tables . Column ( "<STR_LIT>" , <EOL> verbose_nam... |
<s> from django . core . urlresolvers import reverse <EOL> from django . template import defaultfilters as filters <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from django . utils . translation import ungettext_lazy <EOL> from horizon import exceptions <EOL> from horizon import forms <EOL> fr... |
<s> from django . core . urlresolvers import reverse <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from horizon import forms <EOL> from openstack_dashboard . dashboards . identity . identity_providers . protocols import forms as protocol_forms <EOL> class AddProtocolView ( forms . ModalFormVie... |
<s> from django . utils . translation import ugettext_lazy as _ <EOL> import horizon <EOL> from openstack_dashboard . api import keystone <EOL> class Users ( horizon . Panel ) : <EOL> name = _ ( "<STR_LIT>" ) <EOL> slug = '<STR_LIT>' <EOL> policy_rules = ( ( "<STR_LIT>" , "<STR_LIT>" ) , <EOL> ( "<STR_LIT>" , "<STR_LIT... |
<s> from copy import deepcopy <EOL> from django . core . urlresolvers import reverse <EOL> from django import http <EOL> from mox3 . mox import IsA <EOL> import six <EOL> from horizon . workflows import views <EOL> from openstack_dashboard import api <EOL> from openstack_dashboard . dashboards . project . access_and_se... |
<s> import os <EOL> from socket import timeout as socket_timeout <EOL> import unittest <EOL> from django . core . urlresolvers import reverse <EOL> from django import http <EOL> from glanceclient . common import exceptions as glance_exec <EOL> from mox3 . mox import IsA <EOL> import six <EOL> from horizon import except... |
<s> from django . utils . translation import ugettext_lazy as _ <EOL> from openstack_dashboard . dashboards . project . routers . ports import tables <EOL> class RemoveInterface ( tables . RemoveInterface ) : <EOL> failure_url = '<STR_LIT>' <EOL> class PortsTable ( tables . PortsTable ) : <EOL> class Meta ( object ) : ... |
<s> from django . template . defaultfilters import capfirst <EOL> from django . template . defaultfilters import floatformat <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from horizon . utils import csvbase <EOL> from horizon import views <EOL> from openstack_dashboard import usage <EOL> from ... |
<s> import yaml <EOL> from django . core . urlresolvers import reverse <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from horizon import exceptions <EOL> from horizon import tables <EOL> from horizon import tabs <EOL> from openstack_dashboard import api <EOL> import openstack_dashboard . dashb... |
<s> from django . conf import settings <EOL> from django . core . urlresolvers import NoReverseMatch <EOL> from django . core . urlresolvers import reverse <EOL> from django . http import HttpResponse <EOL> from django . template import defaultfilters as filters <EOL> from django . utils import html <EOL> from django .... |
<s> from django . utils . translation import ugettext_lazy as _ <EOL> PANEL_GROUP = '<STR_LIT>' <EOL> PANEL_GROUP_NAME = _ ( '<STR_LIT>' ) <EOL> PANEL_GROUP_DASHBOARD = '<STR_LIT>' </s>
|
<s> DASHBOARD = '<STR_LIT>' <EOL> DEFAULT = False <EOL> ADD_EXCEPTIONS = { } <EOL> ADD_INSTALLED_APPS = [ '<STR_LIT>' ] <EOL> ADD_ANGULAR_MODULES = [ <EOL> '<STR_LIT>' , <EOL> ] <EOL> AUTO_DISCOVER_STATIC_FILES = True </s>
|
<s> import json <EOL> import mock <EOL> from openstack_dashboard import api <EOL> from openstack_dashboard . api . rest import heat <EOL> from openstack_dashboard . test import helpers as test <EOL> class ValidateRestTestCase ( test . TestCase ) : <EOL> @ mock . patch . object ( heat . api , '<STR_LIT>' ) <EOL> def tes... |
<s> from openstack_dashboard . test . integration_tests . pages import basepage <EOL> from openstack_dashboard . test . integration_tests . regions import forms <EOL> from openstack_dashboard . test . integration_tests . regions import tables <EOL> class QosSpecsTable ( tables . TableRegion ) : <EOL> name = '<STR_LIT>'... |
<s> import functools <EOL> from selenium . common import exceptions <EOL> from selenium . webdriver . common import by <EOL> from openstack_dashboard . test . integration_tests . regions import baseregion <EOL> NORMAL_COLUMN_CLASS = '<STR_LIT>' <EOL> class RowRegion ( baseregion . BaseRegion ) : <EOL> """<STR_LIT>""" <... |
<s> """<STR_LIT>""" <EOL> from django . conf import settings <EOL> from django . conf . urls import include <EOL> from django . conf . urls . static import static <EOL> from django . conf . urls import url <EOL> from django . contrib . staticfiles . urls import staticfiles_urlpatterns <EOL> from django . views import d... |
<s> import collections <EOL> import functools <EOL> import inspect <EOL> import threading <EOL> import uuid <EOL> from oslo_log import log <EOL> import six <EOL> from ironic_python_agent import encoding <EOL> from ironic_python_agent import errors <EOL> LOG = log . getLogger ( ) <EOL> class AgentCommandStatus ( object ... |
<s> import errno <EOL> import glob <EOL> import os <EOL> import shutil <EOL> import tempfile <EOL> import testtools <EOL> import mock <EOL> from oslo_concurrency import processutils <EOL> from oslotest import base as test_base <EOL> from ironic_python_agent import errors <EOL> from ironic_python_agent import utils <EOL... |
<s> """<STR_LIT>""" <EOL> import json <EOL> from xml import etree as et <EOL> from oslo_log import log <EOL> import six <EOL> import webob <EOL> from ironic . common . i18n import _ <EOL> from ironic . common . i18n import _LE <EOL> LOG = log . getLogger ( __name__ ) <EOL> class ParsableErrorMiddleware ( object ) : <EO... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.