TOdo:添加库描述
batesterwithcustomparamdemov1的Python项目详细描述
#入门
\how to build
必须在系统上安装python```2>;=2.7.9``或python``3>;=3.4```才能安装和运行此sdk。此sdk包依赖于其他python包,如nose、jsonpickle等。
这些依赖项在sdk附带的``requirements.txt``文件中定义。
要解决这些依赖项,可以使用pip依赖项管理器。按照[https://pip.pypa.io/en/stable/installing/](https://pip.pypa.io/en/stable/installing/)中的步骤安装它。
python和pip可执行文件应在路径中定义。打开命令提示符并键入``pip--version``.
如果安装成功并正确定义了路径,则应显示安装的pip依赖关系管理器的版本。
*使用命令行,导航到包含为sdk生成的文件(包括``requirements.txt```)的目录。
*运行命令``pip install-r requirements.txt```。这应该安装所有必需的依赖项。
![构建sdk-步骤1](https://apidocs.io/illustration/python?step=installdependencies&workspacefolder=batester%20with%20custom%20parameters python)
在ide中打开项目
打开python ide,比如pycharm。如果您喜欢使用不同的编辑器或IDE,这里提供的基本工作流也适用。
![在PyCharm中打开项目-步骤1](https://apidocs.io/illustration/python?step=pycharm)
[在PyCharm中打开项目-第2步](https://apidocs.io/illustration/python?step=openproject0&workspacefolder=batester%20和%20custom%20parameters python)
项目文件将显示在侧栏中,如下所示:
![在PyCharm中打开项目-第3步](https://apidocs.io/illustration/python?step=openproject1&workspacefolder=batester%20with%20custom%20parameters python&;projectname=batesterwithcustomparamdemov1)
添加一个新的测试项目
右键单击解决方案名称创建一个新目录,如下所示:
![在PyCharm中添加新项目-步骤1](https://apidocs.io/illustration/python?step=createdirectory&workspacefolder=batester%20with%20custom%20parameters python&;projectname=batesterwithcustomparamdemov1)
[在PyCharm中添加新项目-步骤2](https://apidocs.io/illustration/python?step=nameditory)
将一个名为"testsdk"的python文件添加到此项目中
![在PyCharm中添加新项目-步骤3](https://apidocs.io/illustration/python?step=createfile&workspacefolder=batester%20with%20custom%20parameters python&;projectname=batesterwithcustomparamdemov1)
[在PyCharm中添加新项目-步骤4](https://apidocs.io/illustration/python?step=namefile)
在您的python文件中,您需要使用以下代码行从batesterwithcustomparamdemov1.batesterwithcustomparamdemov1_client import batesterwithcustomparamdemov1客户端导入生成的python库![在PyCharm中添加新项目-步骤4](https://apidocs.io/illustration/python?step=projectfiles&workspacefolder=batester%20with%20custom%20parameters python&libraryname=batesterwithcustomparamdemov1.batesterwithcustomparamdemov_1_client&projectname=batesterwithcustomparamdemov1&;classname=batesterwithcustomparamdemov1client)
示例代码在后续章节中给出。
3.运行测试项目以运行文件wi精简测试项目,右键单击测试项目中的python文件,然后单击``run``
![运行测试项目-步骤1](https://apidocs.io/illustation/python?step=runproject&workspacefolder=batester%20with%20custom%20parameters python&libraryname=batesterwithcustomparamdemov1.batesterwithcustomparamdemov_1_client&projectname=batesterwithcustomparamdemov1&;classname=batesterwithcustomparamdemov1client)
unittest用作测试框架,nose用作测试
运行器。您可以按如下方式运行测试:
1。从terminal/cmd导航到sdk的根目录。
2。调用``pip install-r test requirements.txt``
3。调用``nosetests``
|
password todo:添加描述
``` python
配置参数和凭据
用户名='farhan'
密码='apimatic'
client=batesterwithcustomparamdemov1client(用户名,密码)
```
[类:](https://apidocs.io/img/class.png.api controller)apicontroller
a name="get_basic_auth_test">;<;/a>;![方法:](https://apidocs.io/img/method.png".apicontroller.get_basic_auth_test")get_basic_auth_test
>;todo:添加方法描述
``python
def get_basic_auth_auth_auth_auth-test(self)
```
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `
>
` ` ` ` ` ` ` ` ` ` ` ` ` ` `列出控制器)
\how to build
必须在系统上安装python```2>;=2.7.9``或python``3>;=3.4```才能安装和运行此sdk。此sdk包依赖于其他python包,如nose、jsonpickle等。
这些依赖项在sdk附带的``requirements.txt``文件中定义。
要解决这些依赖项,可以使用pip依赖项管理器。按照[https://pip.pypa.io/en/stable/installing/](https://pip.pypa.io/en/stable/installing/)中的步骤安装它。
python和pip可执行文件应在路径中定义。打开命令提示符并键入``pip--version``.
如果安装成功并正确定义了路径,则应显示安装的pip依赖关系管理器的版本。
*使用命令行,导航到包含为sdk生成的文件(包括``requirements.txt```)的目录。
*运行命令``pip install-r requirements.txt```。这应该安装所有必需的依赖项。
![构建sdk-步骤1](https://apidocs.io/illustration/python?step=installdependencies&workspacefolder=batester%20with%20custom%20parameters python)
在ide中打开项目
打开python ide,比如pycharm。如果您喜欢使用不同的编辑器或IDE,这里提供的基本工作流也适用。
![在PyCharm中打开项目-步骤1](https://apidocs.io/illustration/python?step=pycharm)
[在PyCharm中打开项目-第2步](https://apidocs.io/illustration/python?step=openproject0&workspacefolder=batester%20和%20custom%20parameters python)
项目文件将显示在侧栏中,如下所示:
![在PyCharm中打开项目-第3步](https://apidocs.io/illustration/python?step=openproject1&workspacefolder=batester%20with%20custom%20parameters python&;projectname=batesterwithcustomparamdemov1)
添加一个新的测试项目
右键单击解决方案名称创建一个新目录,如下所示:
![在PyCharm中添加新项目-步骤1](https://apidocs.io/illustration/python?step=createdirectory&workspacefolder=batester%20with%20custom%20parameters python&;projectname=batesterwithcustomparamdemov1)
[在PyCharm中添加新项目-步骤2](https://apidocs.io/illustration/python?step=nameditory)
将一个名为"testsdk"的python文件添加到此项目中
![在PyCharm中添加新项目-步骤3](https://apidocs.io/illustration/python?step=createfile&workspacefolder=batester%20with%20custom%20parameters python&;projectname=batesterwithcustomparamdemov1)
[在PyCharm中添加新项目-步骤4](https://apidocs.io/illustration/python?step=namefile)
在您的python文件中,您需要使用以下代码行从batesterwithcustomparamdemov1.batesterwithcustomparamdemov1_client import batesterwithcustomparamdemov1客户端导入生成的python库![在PyCharm中添加新项目-步骤4](https://apidocs.io/illustration/python?step=projectfiles&workspacefolder=batester%20with%20custom%20parameters python&libraryname=batesterwithcustomparamdemov1.batesterwithcustomparamdemov_1_client&projectname=batesterwithcustomparamdemov1&;classname=batesterwithcustomparamdemov1client)
示例代码在后续章节中给出。
3.运行测试项目以运行文件wi精简测试项目,右键单击测试项目中的python文件,然后单击``run``
![运行测试项目-步骤1](https://apidocs.io/illustation/python?step=runproject&workspacefolder=batester%20with%20custom%20parameters python&libraryname=batesterwithcustomparamdemov1.batesterwithcustomparamdemov_1_client&projectname=batesterwithcustomparamdemov1&;classname=batesterwithcustomparamdemov1client)
unittest用作测试框架,nose用作测试
运行器。您可以按如下方式运行测试:
1。从terminal/cmd导航到sdk的根目录。
2。调用``pip install-r test requirements.txt``
3。调用``nosetests``
|
password todo:添加描述
``` python
配置参数和凭据
用户名='farhan'
密码='apimatic'
client=batesterwithcustomparamdemov1client(用户名,密码)
```
[类:](https://apidocs.io/img/class.png.api controller)apicontroller
a name="get_basic_auth_test">;<;/a>;![方法:](https://apidocs.io/img/method.png".apicontroller.get_basic_auth_test")get_basic_auth_test
>;todo:添加方法描述
``python
def get_basic_auth_auth_auth_auth-test(self)
```
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `
>
` ` ` ` ` ` ` ` ` ` ` ` ` ` `列出控制器)