Pedro Algarvio
06fa91bd33
Merge pull request #52972 from garethgreenaway/52817_unit_modules_test_telegram_telegrammoduletest_test_post_message
...
[2019.2.1] Fix to unit.modules.test_telegram
2019-05-15 08:50:12 +01:00
Gareth J. Greenaway
cea7131cf1
Removing global declaration.
2019-05-14 17:48:05 -07:00
Ch3LL
0a213ee046
Change package name for suse pkg tests
2019-05-14 14:38:40 -04:00
Shane Lee
21838a1f2c
Merge branch '2019.2.1' into fix_test_pip_state
2019-05-13 14:33:34 -06:00
Ch3LL
368c012f12
Revert "Make sure --run-expensive runtests.py arg works"
...
This reverts commit 56bf069079
.
2019-05-13 14:45:12 -04:00
Gareth J. Greenaway
5bf9a95267
Fixing lint.
2019-05-10 16:36:41 -07:00
twangboy
351d415b69
Return path to Python instead of None
2019-05-10 17:21:56 -06:00
Gareth J. Greenaway
4d3c46d193
fixing broken unit.modules.test_telegram test.
2019-05-10 16:21:07 -07:00
Megan Wilhite
9a27fb3f96
Merge branch '2019.2.1' into yaml_flow_style
2019-05-10 14:54:33 -04:00
Ch3LL
0d0e354627
Fix yamldumper test for both py2/py3
2019-05-10 14:52:58 -04:00
Shane Lee
ac27e6970f
Merge branch '2019.2.1' into fix_test_file
2019-05-09 14:34:14 -06:00
Ch3LL
20bc954483
Update docs for yamldumper test
2019-05-09 15:42:52 -04:00
Megan Wilhite
bf648e57a8
Update tests/unit/utils/test_yamldumper.py
...
Co-Authored-By: Wayne Werner <waynejwerner@gmail.com>
2019-05-09 15:39:12 -04:00
Ch3LL
70d578a1af
Set default_flow_style=None in yaml.dump calls
2019-05-09 15:18:32 -04:00
Daniel Wozniak
4437764891
Merge pull request #52943 from Ch3LL/fix_elastisearch
...
Fix elasticsearch state module: allow user to define empty aliases
2019-05-09 08:46:37 -07:00
Pedro Algarvio
a06d7cef0e
We need to call the decorator
2019-05-09 15:17:24 +01:00
Pedro Algarvio
77185af841
Partial revert since this is a class method
2019-05-09 14:41:43 +01:00
Pedro Algarvio
f5c5771dd9
Lint fixes
2019-05-09 14:40:17 +01:00
Pedro Algarvio
8e505fb91a
Move tests to existing test modules
2019-05-09 14:20:23 +01:00
Pedro Algarvio
46816092eb
tests/unit/config/__init__.py
-> tests/unit/config/test_config.py
...
No top level `__init__.py` should contain tests
2019-05-09 14:19:56 +01:00
Pedro Algarvio
33743fc4a0
Don't traceback when trying to close a closed socket
2019-05-09 14:14:34 +01:00
Pedro Algarvio
da2e147e54
Always cleanup the changed environ
2019-05-09 14:13:32 +01:00
Pedro Algarvio
087c74d907
No globals in tests, specially dictionaries!
2019-05-09 14:11:12 +01:00
Daniel A. Wozniak
5bb7869adc
fix linter
2019-05-09 14:03:05 +01:00
Megan Wilhite
451fb7e60f
Merge branch '2019.2.1' into fix_elastisearch
2019-05-08 16:15:41 -04:00
Ch3LL
ebff9b94e0
Fix elasticsearch state module: allow user to define empty aliases
2019-05-08 15:50:35 -04:00
Pedro Algarvio
a8f7b464f5
Test is not destructive.
...
Changes salt's testing config, which is what testing is all about, but
does not change the underlying OS.
2019-05-08 19:46:30 +01:00
Pedro Algarvio
62574ee197
Typo
2019-05-08 13:16:52 +01:00
Pedro Algarvio
e9f6a1228d
identical_signature_wrapper
adds __wrapped__
to function globals
2019-05-08 13:16:51 +01:00
Daniel A. Wozniak
6e0b61baa9
Less flaky mine tests
2019-05-08 13:16:51 +01:00
Daniel A. Wozniak
3709ed745e
msgpack returns string_types
2019-05-08 13:16:51 +01:00
Daniel A. Wozniak
a36b15e449
Add regression test
2019-05-08 13:16:51 +01:00
Daniel A. Wozniak
8fdb04df0d
SIGKILL is not alwasy available use a local variable
2019-05-08 13:16:50 +01:00
Daniel A. Wozniak
4d6b8da5a0
Fix linter
2019-05-08 13:16:50 +01:00
Daniel A. Wozniak
759bccc202
Fix test_doc on windows by using grep yay!
2019-05-08 13:16:49 +01:00
Daniel A. Wozniak
0ce086d13d
Fix remaining failures on ubuntu 1404 and add to PR tests
2019-05-08 13:16:49 +01:00
Daniel A. Wozniak
b0aa28760c
Fix missing class wart
2019-05-08 13:16:49 +01:00
Daniel A. Wozniak
21ecb742db
fix linter
2019-05-08 13:16:49 +01:00
Daniel A. Wozniak
62c0f9fdd9
Skip tests when no libcloud
2019-05-08 13:16:48 +01:00
Daniel A. Wozniak
1d92290304
Fix unused import
2019-05-08 13:16:48 +01:00
Daniel A. Wozniak
238fd0f071
Fix broken pip state
2019-05-08 13:16:48 +01:00
Daniel A. Wozniak
1eea9908e9
Fix linter
2019-05-08 13:16:47 +01:00
Daniel A. Wozniak
52ca668360
Skip tests when no libcloud
2019-05-08 13:16:47 +01:00
Daniel A. Wozniak
522599d261
Dont fail just because some random process died
2019-05-08 13:16:47 +01:00
Daniel A. Wozniak
34cef86e14
Ignore super not called
2019-05-08 13:16:46 +01:00
Daniel A. Wozniak
b7ace9c929
Fix linter
2019-05-08 13:16:46 +01:00
Daniel A. Wozniak
aceb6d3013
Skip libcloud unit tests when no libcloud
2019-05-08 13:16:46 +01:00
Ch3LL
2acb0f37bc
Make sure --run-expensive runtests.py arg works
2019-05-08 13:16:45 +01:00
twangboy
12d8d351cf
Stop w32time before and start after testing
2019-05-08 13:16:45 +01:00
twangboy
7f1c22ce3a
Skip tests that fail on Windows
2019-05-08 13:16:45 +01:00
Pedro Algarvio
381f5fea52
Limit and reduce the ammount of log records sent over the wire
2019-05-08 13:16:44 +01:00
Pedro Algarvio
8948b690b1
Include COVERAGE_FILE
as an env variable.
...
This will tell coverage where to save all coverage files.
2019-05-08 13:16:44 +01:00
Pedro Algarvio
0af561ef24
Each generated script is now prepared for code coverage
2019-05-08 13:16:44 +01:00
Pedro Algarvio
666ca9f7cd
Fix proxy minion startup issue on the test suite
2019-05-08 13:16:43 +01:00
Daniel A. Wozniak
e9e57cfb05
Syndic roster not in 2017.7.9
2019-05-08 13:16:42 +01:00
Daniel A. Wozniak
111c63a4dc
Create the roster even when not running ssh
2019-05-08 13:16:42 +01:00
Daniel A. Wozniak
11c02a0be3
Fix unit.test_loader.LoaderGlobalsTest.test_states
2019-05-08 13:16:42 +01:00
Daniel A. Wozniak
8694db10d7
Fix windows tests
2019-05-08 13:16:42 +01:00
Daniel A. Wozniak
82e9ac5b8f
Avoid race condition in even assertions
2019-05-08 13:16:42 +01:00
Daniel A. Wozniak
9443451d9a
Revert part of 927219c
since it is not a fix
2019-05-08 13:16:42 +01:00
Daniel A. Wozniak
5fee7620a5
Fix timeout logic
2019-05-08 13:16:41 +01:00
Daniel A. Wozniak
517650f87b
check timeout when queue empty
2019-05-08 13:16:41 +01:00
Daniel A. Wozniak
7c0a9af3d0
fix linter
2019-05-08 13:16:41 +01:00
Daniel A. Wozniak
961dc40c9b
Ignore missing variable in six module
2019-05-08 13:16:41 +01:00
Daniel A. Wozniak
0f5a7f0abf
Fix typo
2019-05-08 13:16:41 +01:00
Daniel A. Wozniak
6c8c4182dd
Do not limit event assert to first event
2019-05-08 13:16:41 +01:00
Daniel A. Wozniak
304229240e
Wait longer for ping reaction
...
Wait longer for the ping reaction in case there are multiple events on
the bus and/or high load on the system running tests
2019-05-08 13:16:40 +01:00
Wayne Werner
b6b4e955d2
Lint cleanup
2019-05-08 13:16:40 +01:00
Wayne Werner
0670614c6a
Add tests for wraps
...
During testing I also discovered that `_ignores_kwargs` was also missing
the @wraps decorator. Now it has it.
2019-05-08 13:16:39 +01:00
Pedro Algarvio
0e5bc67d4b
Lint fixes
2019-05-08 13:16:39 +01:00
Pedro Algarvio
72e8603046
Skip test if required cypto libs are not available
2019-05-08 13:16:38 +01:00
Pedro Algarvio
b2b0764dd4
Be aware of the different path separators
2019-05-08 13:16:38 +01:00
Pedro Algarvio
7e79b182b6
We need to make sure the virtualenv path entry is removed when searching
2019-05-08 13:16:38 +01:00
Pedro Algarvio
ff6d3c6dae
We don't need to be root to run these tests
2019-05-08 13:16:38 +01:00
Pedro Algarvio
f86a44e1fc
Use the real python executable path when running within a virtualenv
2019-05-08 13:16:37 +01:00
Pedro Algarvio
3d407e8a2e
Add a helper to return the path to the real pytohn executable
...
In case the test suite is running from within a virtualenv
2019-05-08 13:16:37 +01:00
Pedro Algarvio
ea9d2460f0
We must also provide venv_bin
when running within a virtualenv
2019-05-08 13:16:37 +01:00
Pedro Algarvio
31e91b03bb
Fix pip tests, in particular under windows
2019-05-08 13:16:37 +01:00
Pedro Algarvio
4a072fe191
These tests aren't destructive
2019-05-08 13:16:35 +01:00
Pedro Algarvio
361ef6e50f
Don't try to change ownership on non existing paths
2019-05-08 13:16:34 +01:00
Pedro Algarvio
7b173523d8
More insight(context) on failure reports
2019-05-08 13:16:34 +01:00
Pedro Algarvio
51114aa4ed
Watch out for too long shebang's
2019-05-08 13:16:34 +01:00
Pedro Algarvio
d97fe82815
The output is important to know why it failed.
2019-05-08 13:16:34 +01:00
Pedro Algarvio
c8de644cad
Fix lint issues under tests
2019-05-08 13:16:31 +01:00
Ch3LL
4945e35085
Fix pylint on 2017.7.9
2019-05-08 13:16:26 +01:00
Pedro Algarvio
036bf686c0
Rerun failed tests
2019-05-08 13:16:26 +01:00
Daniel A. Wozniak
899c80e723
Fix integration.client.test_kwarg test timeouts
2019-05-08 13:16:25 +01:00
Pedro Algarvio
30a5093591
Merge branch '2019.2.1' into fix_test_file
2019-05-08 11:40:45 +01:00
Gareth J. Greenaway
eee5a38db6
Merge branch '2019.2.1' into 52836_test_argspec_report_failing
2019-05-07 09:37:44 -07:00
Gareth J. Greenaway
dfff09bd1a
Merge branch '2019.2.1' into bp-52780
2019-05-07 08:48:03 -07:00
Gareth J. Greenaway
8fdc48c0bd
Removing create_autospec and having salt.utils.args.argspec_report run against the _test_spec function directly. Depending on the python version, create_autospec gives different results and cause the test to fail. The test is now more accurate at testing the arguments for the function.
2019-05-06 18:30:16 -07:00
Ch3LL
fc70884ca1
Reload matcher loader when ext_pillar_first set
2019-05-06 17:57:11 -04:00
Sean Brennan
c1eae841ca
Add test
2019-05-06 10:10:14 -04:00
Shane Lee
c08b10d79b
Merge branch '2019.2.1' into fix_test_file
2019-05-03 18:58:25 -06:00
Megan Wilhite
1ee8f37c77
Merge branch '2019.2.1' into zmq_filter_test
2019-05-02 10:35:53 -04:00
Pedro Algarvio
b68544ffbc
Merge pull request #52771 from twangboy/fix_test_gpg
...
Fix `test_gpg` tests on Windows
2019-05-02 14:30:17 +01:00
Ch3LL
cde29cb334
Fix boto_apigateway tests for PyYAML 5.1
2019-05-01 15:40:58 -04:00
Megan Wilhite
d74b6ee7b9
Merge branch '2019.2.1' into zmq_filter_test
2019-05-01 10:33:44 -04:00
twangboy
c7f45c241a
Pass encoding to stringutils.to_unicode
2019-04-30 16:29:03 -06:00
twangboy
340ee23a10
Pass encoding to _validate_str_list
2019-04-30 15:55:08 -06:00
Daniel Wozniak
35094653c9
Merge pull request #52769 from twangboy/fix_test_core
...
Remove domain grain from tests for Windows
2019-04-30 14:14:25 -07:00
Daniel Wozniak
32102749da
Fix linter warnings
2019-04-30 13:23:45 -07:00
twangboy
0049f85fbe
Remove domain grain from tests
2019-04-30 14:01:24 -06:00
twangboy
123b6075fe
Remove pchanges... again...
2019-04-30 13:53:43 -06:00
Ch3LL
e7c9d6ea22
increase timeout when gathering results
2019-04-30 15:53:39 -04:00
Ch3LL
784786d004
Add zmq_filter unit tests
2019-04-30 15:48:53 -04:00
twangboy
811b381714
Skip test_gen_thin_compression_fallback_py3
...
Skips this test on Windows running Python 2
This test is causing python to hard crash, thus killing the entire test
suite
Also simplifies the _get_thintar_prefix function
2019-04-29 16:56:26 -06:00
Shane Lee
04ad027732
Merge branch '2019.2.1' into ec2test
2019-04-29 09:39:52 -06:00
Daniel A. Wozniak
b770f965d3
Skip test requiring crypto when none available
2019-04-29 03:41:38 +00:00
tanlingyun2005
2c6867e36f
add test case to tests/unit/cli/test_batch.py
2019-04-26 23:44:22 +08:00
twangboy
915c780775
Fix issues with the win_file tests
...
Remove pchanges
Migrate to __utils__['dacl.check_perms']
2019-04-22 16:30:32 -06:00
Daniel Wozniak
af66facc27
Merge branch '2019.2.1' into 2019.2.1
2019-04-21 18:17:07 -07:00
Daniel A. Wozniak
859d088da8
Merge remote-tracking branch 'origin/cron_test_fix' into cron_test_fix
2019-04-22 00:11:37 +00:00
Daniel A. Wozniak
169c2d56aa
Chattr version py3 fix
2019-04-22 00:11:13 +00:00
Gareth J. Greenaway
7f7bb900dc
Merge branch '2019.2.1' into cron_test_fix
2019-04-21 15:44:27 -07:00
Daniel A. Wozniak
cf88c27353
Fix linter issues
2019-04-21 22:43:15 +00:00
Daniel A. Wozniak
0ea007de6f
Parse chattr version and fix test case
...
- Parse the system's chattr version from the chattr man page
- Fix integration.states.test_cron on centos 6
2019-04-21 22:19:45 +00:00
Daniel Wozniak
f7d823c8aa
Merge pull request #52601 from Ch3LL/cp-52415
...
Cherry-Pick #52415 into 2019.2.1
2019-04-21 12:33:03 -07:00
Pedro Algarvio
af4f2043bf
Merge pull request #52645 from dwoz/test_fixes
...
Fix salt.modules.publish and salt.states.x509 tests
2019-04-20 09:17:17 +01:00
Daniel A. Wozniak
9b6f9f94d0
Clean up cruft
2019-04-20 03:57:36 +00:00
Daniel A. Wozniak
c3971a5802
Fix salt.modules.publish and salt.states.x509 tests
...
The peers.conf addition for the x509 state tests broke the
salt.modules.publish tests. Move the configuration to the test master's
config. Also increase the publish call timeout in the x509 module to
make the x509 state tests reliable on all platforms.
2019-04-20 03:16:46 +00:00
Megan Wilhite
ecd6802b3f
Merge branch '2019.2.1' into cp-52415
2019-04-19 16:01:12 -04:00
Daniel A. Wozniak
c001022913
Fix linter
2019-04-19 16:22:52 +00:00
Daniel A. Wozniak
423f6f96b7
Fix vent assertion race condition
2019-04-19 16:16:01 +00:00
Daniel A. Wozniak
105784a0da
Remove unused method from pytest engine
2019-04-18 22:48:34 +00:00
Daniel Wozniak
77943e5f38
Merge pull request #52614 from Ch3LL/cp-test_network-2019.2.1
...
[2019.2.1] Update integration.modules.test_network.NetworkTest.test_network_ping…
2019-04-18 14:54:28 -07:00
twangboy
5a0464bdef
Bring 51661 into 2019.2.1
2019-04-18 14:15:44 -06:00
Pedro Algarvio
27c79d2a21
Update integration.modules.test_network.NetworkTest.test_network_ping test address
2019-04-18 15:44:36 -04:00
Ch3LL
fb3b75d9ae
Fix tests for pchanges backport into 2018.3
...
Conflicts:
- tests/unit/states/test_file.py
2019-04-18 11:02:46 -04:00
Erik Johnson
0f296bb7a7
Update kernelpkg test to reflect pchanges removal
2019-04-18 11:01:21 -04:00
Erik Johnson
885d6ff281
Update file.touch unit tests to reflect addition of changes in test mode
2019-04-18 11:01:16 -04:00
Erik Johnson
4bc5fd008e
Add integration tests for test mode onchanges/prereq
...
Conflicts:
- tests/unit/states/test_file.py
2019-04-18 11:00:59 -04:00
Erik Johnson
ed214c4cdb
Make it possible to use prereq with test and saltmod state mods
...
this requisite passes a __prerequired__ kwarg so these need to support
**kwargs for that reason.
This also changes the comment for salt.function in test mode because
it's inaccurate and doesn't make sense.
Conflicts:
- salt/states/test.py
2019-04-18 10:59:19 -04:00
Erik Johnson
ceb3f4d91f
Add repack_state_returns to TestCase
...
This allows for a state return dict to be repacked so that the top level
keys are the IDs, making it much easier to analyze and craft asserts
against the results.
2019-04-18 10:57:15 -04:00
Erik Johnson
982e693ef6
Add exception logging in flaky decorator
2019-04-18 10:57:11 -04:00
Erik Johnson
6db2beb6c0
Replace "pchanges" with "changes" to fix onchanges/prereq requisites
...
Since "pchanges" was never supported in the state compiler, and
"changes" is what these reqs always used, replacing "pchanges" with
"changes" will allow those requisites to work in test mode.
Conflicts:
- salt/states/file.py
- salt/states/linux_acl.py
- salt/utils/napalm.py
- tests/integration/modules/test_state.py
- tests/unit/states/test_file.py
2019-04-18 10:56:30 -04:00
Ch3LL
e09be8425b
Update test_schema to mirror the new ValidationErrors in 3.0.0
2019-04-17 15:45:05 -04:00
Daniel Wozniak
21d63656c1
Merge pull request #52526 from lomeroe/deserializer_opts_fix
...
Fix use of deserializer_opts in file.serialize
2019-04-17 07:08:51 -07:00
Daniel Wozniak
e522ffe08c
Merge pull request #52570 from DSRCorporation/bugs/revert_51963_2019.2
...
Simplify IPCClient and prevent corrupt messages (Turn 2) 2019.2
2019-04-17 07:03:01 -07:00
Daniel Wozniak
b17340615c
Merge pull request #52551 from garethgreenaway/52449_test_gce_random_failures
...
[2019.2] Marking the two tests in test_gce as flaky
2019-04-17 07:00:38 -07:00
Daniel Wozniak
9faa49cca4
Merge pull request #52490 from dwoz/issue_52134
...
Fix pillar include regression
2019-04-17 06:54:38 -07:00
Dmitry Kuzmenko
fabbcac8e6
A couple of race conditions fixes and a test update.
2019-04-17 02:00:22 +03:00
Ch3LL
87cf385e64
increase timeout on test_state for windows
2019-04-16 09:58:47 -04:00
Ch3LL
3442202bb4
Increase timeout for test_kwarg tests
2019-04-15 17:32:57 -04:00
Gareth J. Greenaway
28af717078
Marking the two tests in test_gce as flaky.
2019-04-15 09:22:58 -07:00
lomeroe
ea0520c8e3
update test for serialization opts
2019-04-14 10:49:50 -05:00
Ch3LL
795a7f67da
Fix windows tests - increase timeout
2019-04-12 21:32:33 -04:00
Ch3LL
c70772c5a0
Fix linux state tests- add new comment
2019-04-12 19:50:52 -04:00
Ch3LL
294156743a
Merge branch '2018.3' into '2019.2'
...
Conflicts:
- tests/unit/transport/test_ipc.py
2019-04-12 12:31:57 -04:00
Thomas S Hatch
dd7a4baa4f
Merge pull request #52046 from twangboy/use_reg_timezone
...
Use registry to get timezone
2019-04-12 09:58:55 -06:00
Daniel A. Wozniak
2ed650b91f
Merge remote-tracking branch 'saltstack/2019.2' into issue_52134
2019-04-12 03:52:06 +00:00
Daniel Wozniak
6eb2bce9be
Merge pull request #52334 from waynew/51879-fix-binary-pillar-return-error
...
51879 fix binary pillar return error
2019-04-11 20:45:16 -07:00
Daniel Wozniak
1b969c39cf
Merge pull request #52146 from twangboy/fix_test_symlink_2019.2
...
Add missing symlink test
2019-04-11 17:51:15 -07:00
Daniel Wozniak
7a1b8cad9e
Merge pull request #52341 from cbosdo/virt-state-fixes
...
virt.pool_running: fix pool start
2019-04-11 17:14:51 -07:00
Daniel Wozniak
6040282283
Merge pull request #52427 from garethgreenaway/52350_readd_and_gate_unicode_string_literal_support
...
[2019.2] Support for old yaml render
2019-04-11 17:06:36 -07:00
Daniel Wozniak
80d7aea13c
Merge pull request #52160 from cbosdo/virt-whitespace-fix
...
Virt whitespace fix
2019-04-11 17:04:24 -07:00
Daniel Wozniak
b551bbd2e1
Merge pull request #52008 from waynew/51832-re-allow-slash-includes
...
Allow `/` in pillar includes
2019-04-11 17:02:39 -07:00
Daniel Wozniak
7be04287de
Merge pull request #51913 from garethgreenaway/51818_fix_when_sk_is_empty
...
[2019.2] Fixes to utils/nacl.py
2019-04-11 16:56:56 -07:00
Daniel Wozniak
89f0bd8820
Merge branch '2019.2' into virt-state-fixes
2019-04-11 16:35:25 -07:00
Daniel Wozniak
ead856ee93
Merge branch '2019.2' into 51879-fix-binary-pillar-return-error
2019-04-11 16:33:20 -07:00
Daniel Wozniak
d6f0971eee
Merge pull request #52399 from waynew/52116-fix-host-present-fail
...
Bring host.present in line with Salt's test conventions
2019-04-11 16:32:27 -07:00
Daniel Wozniak
7c709cfb57
Merge pull request #52477 from bloomberg/win_cmd_2019
...
2019.2 backport #52472 modules.cmdmod: handle windows environ better
2019-04-11 16:13:33 -07:00
Gareth J. Greenaway
82f010ae29
Merge branch '2019.2' into 52350_readd_and_gate_unicode_string_literal_support
2019-04-11 15:56:35 -07:00
Daniel Wozniak
fd1f539c52
Merge branch '2019.2' into virt-whitespace-fix
2019-04-11 15:53:48 -07:00
Daniel Wozniak
8e1c882715
Merge branch '2019.2' into fix_test_symlink_2019.2
2019-04-11 15:52:39 -07:00
Daniel Wozniak
55d7488d18
Merge branch '2019.2' into 51818_fix_when_sk_is_empty
2019-04-11 15:41:09 -07:00
Daniel Wozniak
8440ae1b3d
Merge branch '2019.2' into 52116-fix-host-present-fail
2019-04-11 15:38:30 -07:00
Daniel Wozniak
dd002fdad8
Fix linter
2019-04-11 15:38:15 -07:00
Daniel Wozniak
4bb918524b
Merge pull request #52506 from bloomberg/2019_zmq_uri
...
2019.2: transport.zmq: fix bug introduced by b7df7e75cf
2019-04-11 14:12:50 -07:00
Megan Wilhite
ae81fee398
Merge branch '2019.2' into 52350_readd_and_gate_unicode_string_literal_support
2019-04-11 16:48:05 -04:00
Matt Phillips
b682ec5a19
transport.zmq: fix bug introduced by b7df7e75cf
...
this change was introduced to address evidently another bug where
somehow self.opts has no master_uri - but in the process it prioritized
using master_ip over master_uri even when master_uri _is_ there.
providing master_uri as a way of specifiying which msater you would like
to create a channel for is documented used elsewhere in the codebase in
multi-master scenarios (ie, event.send, saltutil.revoke_auth)
2019-04-11 13:58:19 -04:00
Matt Phillips
1e9dd7fd3f
transport.zmq: fix bug introduced by b7df7e75cf
...
this change was introduced to address evidently another bug where
somehow self.opts has no master_uri - but in the process it prioritized
using master_ip over master_uri even when master_uri _is_ there.
providing master_uri as a way of specifiying which msater you would like
to create a channel for is documented used elsewhere in the codebase in
multi-master scenarios (ie, event.send, saltutil.revoke_auth)
2019-04-11 13:56:13 -04:00
Shane Lee
fc8e970221
Merge branch '2018.3' into use_reg_timezone
2019-04-11 10:53:08 -06:00
Daniel A. Wozniak
b0af11f3d3
Run include tests when pillar source changes
2019-04-10 22:41:47 +00:00
Daniel A. Wozniak
307cec64e1
Fix pillar tests
2019-04-10 21:51:25 +00:00
Daniel A. Wozniak
1a33bde52c
import __future__.absolute_import
2019-04-10 21:20:22 +00:00
Daniel A. Wozniak
5dc5de9dab
Use file encoding and add docstring
2019-04-10 21:03:43 +00:00
Daniel A. Wozniak
c79f496021
Add pillar include tests
2019-04-10 20:55:46 +00:00
Daniel A. Wozniak
f45d29b222
Remove un-needed test
2019-04-10 19:16:14 +00:00
Daniel A. Wozniak
6d80789cf1
Fix ipc unit tests
2019-04-10 17:36:36 +00:00
Daniel Wozniak
2df74ca6d6
Merge pull request #52476 from bloomberg/win_cmd_2018
...
2018.3 backport #52472 modules.cmdmod: handle windows environ better
2019-04-10 10:30:19 -07:00
Daniel Wozniak
d699485dbc
Merge pull request #52393 from waynew/52087-mine-delete-test-enhancements
...
Use uncommon item in mine delete test
2019-04-10 10:18:14 -07:00
Matt Phillips
736a437520
2019.2 bacpkport: modules.cmdmod: handle windows environ better
...
python exposes an nt.environ for case insensitive environment behavior
that is native to windows; so it makes sense to use this instead of
os.environ to avoid enexpected behavior and failure.
further detail: https://bugs.python.org/issue28824
2019-04-10 10:33:37 -04:00
Matt Phillips
0e0c42e204
2018 backport: modules.cmdmod: handle windows environ better
...
python exposes an nt.environ for case insensitive environment behavior
that is native to windows; so it makes sense to use this instead of
os.environ to avoid enexpected behavior and failure.
further detail: https://bugs.python.org/issue28824
2019-04-10 09:56:35 -04:00
Wayne Werner
ee3115fa94
Allow leading dots and / as pillar separators
2019-04-09 18:11:44 -05:00
Gareth J. Greenaway
b2128e8559
Merge branch '2019.2' into 51818_fix_when_sk_is_empty
2019-04-09 12:39:34 -07:00
Gareth J. Greenaway
ac950b34c8
Merge branch '2019.2' into 51932_show_diff_when_test_True
2019-04-09 08:32:10 -07:00
Gareth J. Greenaway
b618d44759
Merge branch '2019.2' into 52350_readd_and_gate_unicode_string_literal_support
2019-04-08 14:55:37 -07:00
Gareth J. Greenaway
cb01a1b6bb
Merge branch '2019.2' into 51818_fix_when_sk_is_empty
2019-04-08 14:41:47 -07:00
Gareth J. Greenaway
1a1e333583
Merge branch '51818_fix_when_sk_is_empty' of github.com:garethgreenaway/salt into 51818_fix_when_sk_is_empty
2019-04-08 14:40:45 -07:00
Gareth J. Greenaway
dd2306921f
Adding tests for NACL changes.
2019-04-08 14:40:06 -07:00
Shane Lee
a429542e91
Merge branch '2019.2' into fix_test_symlink_2019.2
2019-04-08 13:37:18 -06:00
Daniel A. Wozniak
47203f7f79
Fix ipc unit tests
2019-04-08 17:17:20 +00:00
Cédric Bosdonnat
b297e7db20
virt: handle whitespaces in VM names
...
The disk creation code is now ready to handle whitespaces in virtual
machine name.
2019-04-08 15:31:13 +02:00
Cédric Bosdonnat
25b968151e
virt.pool_running: fix pool start
...
Building a libvirt pool starts it. When defining a new pool, we need to
let build start it or we will get libvirt errors.
2019-04-08 14:46:42 +02:00
Cédric Bosdonnat
30981d25b9
Remove unneeded kwargs in virt states
...
Avoid using kwargs to get the states parameters, perfer documented
named parameters with default value.
(cherry picked from commit c7c5d6ee88
)
2019-04-08 14:39:35 +02:00
Cédric Bosdonnat
0871c028c6
virt: allow defining the VM type and arch when creating it
...
Some hypervisors can handle several CPU architectures or have different
virtualization types. This is reflected in libvirt by the OS type (badly
named, indeed) and the arch value. Allow users to set them when creating
a VM using either virt.init or virt.running.
Signed-off-by: Cédric Bosdonnat <cbosdonnat@suse.com>
(cherry picked from commit 2463ebe5a8
)
2019-04-08 14:39:35 +02:00
Cédric Bosdonnat
1c65d25eb4
Updating running domains in virt.running
...
So far virt.running does nothing if the corresponding domain is already
defined. Use the new virt.update function to change the domain
configuration.
(cherry picked from commit 2a5f6ae5d6
)
2019-04-08 14:39:35 +02:00
Cédric Bosdonnat
13d7819c7f
Add missing virt states unit tests
...
So far only the virt.running state is unit tested. Add tests for the
other states. Deprecated virt states have been purposedly left untested.
(cherry picked from commit fc75872fb6
)
2019-04-08 14:39:34 +02:00
Cédric Bosdonnat
0681d865f6
virt.running support for all virt.init options
...
virt.running actually calls virt.init if the virtual machine doesn't
exist. Let the user define all the virt.init possible options in his
running states too.
(cherry picked from commit cb00a5f9b4
)
2019-04-08 14:39:34 +02:00
Cédric Bosdonnat
c6a444ba87
Add test case for virt.running
...
Test virt.running when the domain needs to be edited and started. This
will prevent regressions when improving virt.running to handle the new
virt.init parameters.
(cherry picked from commit 495db345a5
)
2019-04-08 14:39:34 +02:00
Cédric Bosdonnat
2db7a988b2
Let virt running state provide errors
...
As mentioned in issue 47972, applying the virt.running state doesn't
report any error if the libvirt create call actually failed.
This commit introduces proper handling of the libvirt errors to let
users see the libvirt error in case of failure.
Also add test cases for virt.running to prevent regression.
(cherry picked from commit 451e7da55b
)
2019-04-08 14:39:12 +02:00
Gareth J. Greenaway
0ce0c043b5
Merge branch '2019.2' into 51932_show_diff_when_test_True
2019-04-05 14:10:04 -07:00
Gareth J. Greenaway
38a9818fec
Merge branch '2019.2' into 52350_readd_and_gate_unicode_string_literal_support
2019-04-05 13:47:14 -07:00
Gareth J. Greenaway
401c253548
Merge branch '2019.2' into fix_test_symlink_2019.2
2019-04-05 13:42:39 -07:00
Gareth J. Greenaway
cce6200fac
Fixing lint
...
Fixing lint
2019-04-05 13:42:18 -07:00
Gareth J. Greenaway
16733da066
Merge branch '2019.2' into merge-2019.2
2019-04-05 13:38:40 -07:00
Gareth J. Greenaway
cd78485aab
Merge branch '2019.2' into issue_51869
2019-04-05 13:35:27 -07:00
Gareth J. Greenaway
f848aa474d
Adding support back in with, a gated configuration option, for the old YAML Loader.
2019-04-05 11:31:03 -07:00
Ch3LL
fe13214bd1
Merge branch '2018.3' into '2019.2'
...
No conflicts.
2019-04-04 09:35:08 -04:00
Daniel Wozniak
b6028b907b
Merge pull request #52403 from bdrung/fix-test-conditions
...
Fix test conditions
2019-04-03 10:07:53 -07:00
Daniel Wozniak
c7cb00923e
Merge branch '2019.2' into fix_test_symlink_2019.2
2019-04-03 10:06:27 -07:00
Daniel Wozniak
e5a755d45d
Merge pull request #52250 from twangboy/fix_grains
...
Fix the domain grain on Windows
2019-04-03 09:28:54 -07:00
Benjamin Drung
e74f78fca6
Skip ExtendTestCase if templates directory is missing
...
The release tarball does not contain the `templates` directory.
Therefore `ExtendTestCase` will fail:
```
======================================================================
ERROR: test_run (unit.utils.test_extend.ExtendTestCase)
[CPU:0.0%|MEM:53.9%]
----------------------------------------------------------------------
Traceback (most recent call last):
File "tests/unit/utils/test_extend.py", line 40, in test_run
out = salt.utils.extend.run('test', 'test', 'this description', integration.CODE_DIR, False)
File "salt/utils/extend.py", line 242, in run
MODULE_OPTIONS = _fetch_templates(os.path.join(salt_dir, 'templates'))
File "salt/utils/extend.py", line 76, in _fetch_templates
for item in os.listdir(src):
FileNotFoundError: [Errno 2] No such file or directory: ' templates'
```
Signed-off-by: Benjamin Drung <benjamin.drung@cloud.ionos.com>
2019-04-03 16:33:07 +02:00
Benjamin Drung
0473683ace
Skip SampleConfTest if sample conf directories are missing
...
The release tarball does not contain `conf/cloud.profiles.d`,
`conf/cloud.providers.d`, and `conf/cloud.maps.d`. Therefore the test
cases will fail:
```
======================================================================
ERROR: test_conf_cloud_maps_d_files_are_commented (unit.test_config.SampleConfTest)
[CPU:0.0%|MEM:53.9%]
----------------------------------------------------------------------
Traceback (most recent call last):
File "tests/unit/test_config.py", line 236, in test_conf_cloud_maps_d_files_are_commented
cloud_sample_files = os.listdir(SAMPLE_CONF_DIR + 'cloud.maps.d/')
FileNotFoundError: [Errno 2] No such file or directory: 'conf/cloud.maps.d/'
======================================================================
ERROR: test_conf_cloud_profiles_d_files_are_commented (unit.test_config.SampleConfTest)
[CPU:0.0%|MEM:53.9%]
----------------------------------------------------------------------
Traceback (most recent call last):
File "tests/unit/test_config.py", line 200, in test_conf_cloud_profiles_d_files_are_commented
cloud_sample_files = os.listdir(SAMPLE_CONF_DIR + 'cloud.profiles.d/')
FileNotFoundError: [Errno 2] No such file or directory: 'conf/cloud.profiles.d/'
======================================================================
ERROR: test_conf_cloud_providers_d_files_are_commented (unit.test_config.SampleConfTest)
[CPU:0.0%|MEM:53.9%]
----------------------------------------------------------------------
Traceback (most recent call last):
File "tests/unit/test_config.py", line 218, in test_conf_cloud_providers_d_files_are_commented
cloud_sample_files = os.listdir(SAMPLE_CONF_DIR + 'cloud.providers.d/')
FileNotFoundError: [Errno 2] No such file or directory: 'conf/cloud.providers.d/'
```
Signed-off-by: Benjamin Drung <benjamin.drung@cloud.ionos.com>
2019-04-03 16:32:58 +02:00
rsmekala
211b169ce9
Ported relevant fixes from unit.modules.test_junos from develop to 2019.2
2019-04-03 11:18:53 +05:30
Justin Findlay
2f49231233
modules.network: update unit test
2019-04-02 20:45:52 -07:00
Wayne Werner
9d1b2a0217
Only return None on host.present changes when test
...
Previously, when using `test=True`, `host.present` would return
`None` always. In Salt we return `True` when there are (or would be)
changes, `False` when there are no changes, and `None` when there
*would* have been changes.
This brings `host.present` in-line with that convention.
2019-04-02 19:10:36 -05:00
Daniel A. Wozniak
855f31a1aa
Remove un-used file
2019-04-02 14:29:53 -07:00
Daniel A. Wozniak
affd9b88b8
Fix setup/teardown methods
2019-04-02 21:12:11 +00:00
Daniel A. Wozniak
215bf931f2
Refresh after modifying tmp pillars
2019-04-02 21:08:00 +00:00
Gareth J. Greenaway
28e76b1fb2
Merge branch '2018.3' into merge-2019.2
...
Conflicts:
- tests/unit/grains/test_core.py
2019-04-02 14:05:55 -07:00
Daniel A. Wozniak
95c3aba426
Add config for listener
2019-04-02 20:24:55 +00:00
Daniel A. Wozniak
5d231f4c09
remove unused import
2019-04-02 19:50:55 +00:00
Daniel A. Wozniak
8c1b1dbd92
Use tmp pillar for signing policies
2019-04-02 19:48:52 +00:00
Wayne Werner
e3f5be36bb
Use uncommon item in mine delete test
...
Rather than using `grains.items`, `test.arg` is less common, and
specifiying a value that isn't currently used anywhere else should
eliminate any chance of race condition for this test.
2019-04-02 13:14:49 -05:00
Daniel A. Wozniak
a0e245800d
fix unused import
2019-04-02 17:49:26 +00:00
Daniel A. Wozniak
7f5f7ddfd4
Fix requisite path
2019-04-02 17:49:25 +00:00
Daniel A. Wozniak
56304983d0
Fix signing policies path
2019-04-02 17:49:25 +00:00
Daniel A. Wozniak
0bd08261be
Fix issue #51869 and add cert signing test
2019-04-02 17:49:20 +00:00
Daniel Wozniak
10d041b63e
Merge pull request #52344 from twangboy/os_release_embedded
...
Fall back to old way of getting osrelease grain if new way fails
2019-03-28 11:06:47 -07:00
Wayne Werner
2aa971d2e5
lint cleanup
2019-03-28 12:41:16 -05:00
Shane Lee
d0987e626c
Merge branch '2018.3' into use_reg_timezone
2019-03-28 10:12:25 -06:00
Shane Lee
3eae05aa9a
Merge branch '2019.2' into fix_test_symlink_2019.2
2019-03-28 10:08:58 -06:00
Shane Lee
a77ec81e6f
Merge branch '2018.3' into fix_grains
2019-03-28 09:59:09 -06:00
Ch3LL
63962b547a
Merge branch '2018.3' into '2019.2'
...
Conflicts:
- salt/states/linux_acl.py
- salt/transport/ipc.py
2019-03-28 11:10:45 -04:00
Gareth J. Greenaway
8461608438
Updating the incron module, state module and tests to remove use of comments.
2019-03-27 16:53:28 -07:00
twangboy
74ab4d3792
Use old way to get osrelease if new way fails
2019-03-27 17:03:13 -06:00
Daniel Wozniak
7040643a82
Merge pull request #52172 from garethgreenaway/51959_fix_acl_present_output
...
[2018.3] Changes to linux_acl state.
2019-03-27 15:51:52 -07:00
Daniel Wozniak
7b2b5217bf
Merge pull request #51963 from DSRCorporation/bugs/49147_ipc_subscriber
...
Allow multiple instances of IPCMessageSubscriber in one process
2019-03-27 15:48:55 -07:00
Shane Lee
87bb513d63
Fix failing symlink test ( #52145 )
2019-03-27 14:58:57 -06:00
Dmitry Kuzmenko
cc46e9c498
Merge branch '2018.3' into bugs/49147_ipc_subscriber
2019-03-27 23:37:31 +03:00
Dmitry Kuzmenko
23733bde5a
Regression test for parallel IPCMessageSubscriber support
2019-03-27 23:33:10 +03:00
twangboy
a5fa99a5c2
Add missing **kwargs
2019-03-27 11:33:32 -06:00
twangboy
7e88d0478a
Add the ability to pass a timeout to beacons
...
Update the tests to pass a longer timeout of 300 seconds, the default is
30
2019-03-27 11:33:32 -06:00
Wayne Werner
28c29459c8
keep_pillar not needed
2019-03-26 20:09:22 -05:00
Wayne Werner
f2aebf9cb5
Assume file contents are binary
...
Try to encode as unicode, but if not, just fall back to binary.
That's probably what the data was in the first place.
2019-03-26 19:41:47 -05:00
Wayne Werner
2b8c782891
Test gpg render with replace newlines
2019-03-26 19:41:40 -05:00
Wayne Werner
c4b385b92a
Allow binary pillar data
...
There's no real reason that pillars can't/shouldn't be able to
contain binary data. This gives us the ability to say that it's OK.
2019-03-26 19:41:33 -05:00
Wayne Werner
604b671ef9
Return binary data from gpg renderer
...
If we receive binary data, we should respond with binary data.
2019-03-26 19:41:26 -05:00