Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 29 additions & 17 deletions .project
Original file line number Diff line number Diff line change
@@ -1,17 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>python.channelfinder.api</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.python.pydev.PyDevBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.python.pydev.pythonNature</nature>
</natures>
</projectDescription>
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>python.channelfinder.api</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.python.pydev.PyDevBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.python.pydev.pythonNature</nature>
</natures>
<linkedResources>
<link>
<name>test/prepare_graph.py</name>
<type>1</type>
<location>C:/Users/Michael/Downloads/prepare_graph.py</location>
</link>
<link>
<name>test/query_embedded.py</name>
<type>1</type>
<location>C:/Users/Michael/Downloads/query_embedded.py</location>
</link>
</linkedResources>
</projectDescription>
4 changes: 2 additions & 2 deletions channelfinder/ChannelFinderClient.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import requests
import ssl
from requests.adapters import HTTPAdapter
from urllib3 import PoolManager
from requests.packages.urllib3.poolmanager import PoolManager
from requests import auth
from copy import copy
from _conf import _conf
Expand Down Expand Up @@ -49,7 +49,7 @@ def __init__(self, BaseURL=None, username=None, password=None):
else:
self.__auth = None
self.__session = requests.Session()
self.__session.mount('https://localhost:8181/ChannelFinder/', Ssl3HttpAdapter())
self.__session.mount(BaseURL, Ssl3HttpAdapter())
self.__session.get(self.__baseURL, verify=False, headers=copy(self.__jsonheader)).raise_for_status()

except:
Expand Down
1 change: 1 addition & 0 deletions channelfinder/cfPropertyManager/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from CFPropertyManager import *
821 changes: 410 additions & 411 deletions test/CFUpdateIOCTest.py

Large diffs are not rendered by default.

7 changes: 4 additions & 3 deletions test/ChannelFinderClientTest.py
Original file line number Diff line number Diff line change
Expand Up @@ -547,12 +547,13 @@ def testDestructiveSetRemoveChannels(self):
This test will check that a POST in the channels resources is destructive
'''
testProp = {u'name':u'testProp', u'owner' : self.propOwner}
testChannels = [{u'name':u'pyChannel1', u'owner':self.channelOwner, u'properties':[testProp]}, \
{u'name':u'pyChannel2', u'owner':self.channelOwner}, \
{u'name':u'pyChannel3', u'owner':self.channelOwner}]
try:
self.clientProp.set(property=testProp)
testProp[u'value'] = 'original'
testChannels = [{u'name':u'pyChannel1', u'owner':self.channelOwner, u'properties':[testProp]}, \
{u'name':u'pyChannel2', u'owner':self.channelOwner}, \
{u'name':u'pyChannel3', u'owner':self.channelOwner}]

self.clientCh.set(channel=testChannels[0])

self.assertEqual(len(self.client.find(name=u'pyChannel*')), 1, \
Expand Down
2 changes: 1 addition & 1 deletion test/_testConf.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
def __loadConfig():
import os.path
import ConfigParser
dflt={'BaseURL':'https://localhost:9191/ChannelFinder',
dflt={'BaseURL':'https://localhost:8181/ChannelFinder',
'username' : 'cf-update',
'password' : '1234',
'owner' : 'cf-update',
Expand Down
2 changes: 1 addition & 1 deletion test/cf-property-manager-unittest.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import unittest
import CFPropertyManager
from channelfinder.cfPropertyManager import CFPropertyManager
import re
import os
class CFPropertyManagerTest(unittest.TestCase):
Expand Down