besapi 3.7.4__tar.gz → 3.7.7__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: besapi
3
- Version: 3.7.4
3
+ Version: 3.7.7
4
4
  Summary: Library for working with the BigFix REST API
5
5
  Home-page: https://github.com/jgstew/besapi
6
6
  Author: Matt Hansen, James Stewart
@@ -29,7 +29,7 @@ import requests
29
29
  from lxml import etree, objectify
30
30
  from pkg_resources import resource_filename
31
31
 
32
- __version__ = "3.7.4"
32
+ __version__ = "3.7.7"
33
33
 
34
34
  besapi_logger = logging.getLogger("besapi")
35
35
 
@@ -345,8 +345,11 @@ class BESConnection:
345
345
  besapi_logger.info("Query did not return any results")
346
346
  else:
347
347
  besapi_logger.error("%s\n%s", err2, rel_result.text)
348
+ result.append("ERROR: " + rel_result.text)
348
349
  raise
349
350
  else:
351
+ besapi_logger.error("%s\n%s", err, rel_result.text)
352
+ result.append("ERROR: " + rel_result.text)
350
353
  raise
351
354
  return result
352
355
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: besapi
3
- Version: 3.7.4
3
+ Version: 3.7.7
4
4
  Summary: Library for working with the BigFix REST API
5
5
  Home-page: https://github.com/jgstew/besapi
6
6
  Author: Matt Hansen, James Stewart
@@ -39,6 +39,13 @@ class BESCLInterface(Cmd):
39
39
 
40
40
  def __init__(self, **kwargs):
41
41
  Cmd.__init__(self, **kwargs)
42
+
43
+ # set an intro message
44
+ self.intro = (
45
+ f"\nWelcome to the BigFix REST API Interactive Python Module v{__version__}"
46
+ )
47
+
48
+ # sets the prompt look:
42
49
  self.prompt = "BigFix> "
43
50
 
44
51
  self.num_errors = 0
@@ -107,7 +107,9 @@ bigfix_cli.do_conf()
107
107
  # this should really only run if the config file is present:
108
108
  if bigfix_cli.bes_conn:
109
109
  # session relevance tests require functioning web reports server
110
- print(bigfix_cli.bes_conn.session_relevance_string("number of bes computers"))
110
+ assert (
111
+ int(bigfix_cli.bes_conn.session_relevance_string("number of bes computers")) > 0
112
+ )
111
113
  assert (
112
114
  "test session relevance string result"
113
115
  in bigfix_cli.bes_conn.session_relevance_string(
@@ -134,7 +136,7 @@ if bigfix_cli.bes_conn:
134
136
  var_name = "TestVarName"
135
137
  var_value = "TestVarValue " + str(random.randint(0, 9999))
136
138
 
137
- print(
139
+ assert var_value in str(
138
140
  bigfix_cli.bes_conn.set_dashboard_variable_value(
139
141
  dashboard_name, var_name, var_value
140
142
  )
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes