Tim Smith
403647c3e4
Fix typos identified by cspell
...
Just a pile of misc typos
Signed-off-by: Tim Smith <tsmith@chef.io>
2021-08-30 16:49:46 -07:00
Nikita Mathur
69b15b6e64
Fix range usage in filter table
...
Signed-off-by: Nikita Mathur <nikita.mathur@chef.io>
2021-07-14 14:27:03 +05:30
Clinton Wolfe
02e8e9cc9c
Ran chefstyle -a
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2021-05-09 23:59:04 -04:00
Clinton Wolfe
774b5944fb
Detect install type via install path ( #4856 )
...
Detect install type via install path
2020-02-10 15:36:04 -05:00
Clinton Wolfe
73b3336e30
Test feedback
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2020-02-10 15:12:32 -05:00
Clinton Wolfe
f52b195d7d
...
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2020-02-05 12:21:14 -05:00
Clinton Wolfe
f8d99eabb9
Move path_exist test code into test file
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2020-02-05 12:15:48 -05:00
Clinton Wolfe
37455bdd11
Parallelize unit tests
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2020-01-29 16:15:58 -05:00
Clinton Wolfe
3419c84233
Make predicates private to reduce namespace pollution; added dockerenv check for docker mode
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2020-01-29 11:28:52 -05:00
Clinton Wolfe
357cf051b1
PR feedback part 1
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2020-01-28 11:06:12 -05:00
Clinton Wolfe
76a9c3e590
Install-path based install context detection
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2020-01-27 13:29:37 -05:00
Miah Johnson
0d57612103
Update references to use new namespace
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2020-01-07 15:12:42 -08:00
Landy Chan
9e38bec396
Added wildcard and dot-prefixed identifier support. Combined regex identifier into standard identifier
...
Signed-off-by: Landy Chan <landychan92@gmail.com>
2019-10-30 16:39:38 -07:00
Landy Chan
e60179b91f
Added regex identifier
2019-10-30 13:51:20 -07:00
Ryan Davis
07dc5e3192
First pass at cleaning deprecations for old minitest/spec-style tests.
...
3 files left to go, and they're behaving oddly so I'm leaving them out
in this pass. Looks like 21 deprecations left.
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-10-03 13:45:19 -07:00
Clinton Wolfe
f4b9bc4b0b
rework filtertable call and add rubocop exception
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2019-07-11 15:04:38 -04:00
Miah Johnson
a4f4fe5231
chefstyle -a; https://github.com/chef/chefstyle/pull/74
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-07-08 17:22:50 -07:00
Miah Johnson
e46018a517
chefstyle -a cleanup
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-06-11 18:52:38 -07:00
Ryan Davis
a5309ea392
blindly applied chefstyle -a
...
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-06-11 18:52:03 -07:00
Miah Johnson
2a1b1d8e88
Remove all leading newlines.
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-31 11:43:44 -07:00
Ryan Davis
be125598c8
Additional whitespace cleanup.
...
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-05-29 17:58:02 -07:00
Ryan Davis
9ec91484fc
Get all non-resource tests fixed again.
...
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-05-29 17:58:02 -07:00
Ryan Davis
adaf2bc364
Removed aws resource requiring from test/helper and inspec/resource.
...
This speeds up parallel unit test runs from a very consistent 2:49 to
a very consistent 1:53, or a 33% reduction.
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-05-29 17:58:02 -07:00
Miah Johnson
6c19e81a06
Remove authors tags from source files.
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-28 12:47:39 -07:00
Miah Johnson
2215bb0570
Update all require
s pointing to util/
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-28 11:30:16 -07:00
Ryan Davis
f36a7c8061
No tabs.
...
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-05-25 03:40:36 -07:00
Ryan Davis
9c6965b2ed
Minor require cleanup for telemetry.
...
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-05-20 13:09:38 -07:00
Miah Johnson
11b8da3283
Merge branch 'master' into mj/encoding
2019-05-08 12:59:55 -07:00
Miah Johnson
1edfeae5f4
Merge pull request #4025 from inspec/mj/3849
...
Enable user telemetry opt-in / opt-out on cli
2019-05-08 12:56:29 -07:00
Clinton Wolfe
b3e5788d2a
Merge pull request #4036 from inspec/mj/dst
...
Add missing tests for DataSeries#enabled? #disable
2019-05-08 15:49:19 -04:00
Miah Johnson
5a0913e3f6
Add missing tests for DataSeries#enabled? #disable
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-08 00:44:51 -07:00
Miah Johnson
d000f20f34
Update Collector#reset to clear telemetry_toggled_off
...
Updated the name of #reset -> #reset! as we are modifying state of a
singeton.
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-08 00:36:45 -07:00
Miah Johnson
871b0e9a38
Ensure telemetry can be disabled
...
The #disable_telemetry method now toggles @telemetry_toggle_off.
The @telemetry_toggle_off is defaulted to false
The #telemetry_enabled? method now checks @telemetry_toggle_off
and we generally check the configuration. We do not flip
@telemetry_toggle_off based on the content of the configuration.
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-08 00:30:24 -07:00
Miah Johnson
640d122327
Update Inspec::Config.mock in collector global methods
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-07 22:37:43 -07:00
Miah Johnson
0b9833dd96
condense true/false enabled tests
...
Because of the way the test system loads I cannot guarantee that
`Inspec::Config.cached` won't be nil. I have to always pass in a mock
config object with our setting.
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-07 19:06:38 -07:00
Miah Johnson
659b4b373a
Remove # encoding: utf8
magic comments
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-07 16:06:23 -07:00
Miah Johnson
b51ad8acb8
When telemetry is disabled Inspec.record_telemetry_data doesn't record
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-03 16:13:45 -07:00
Miah Johnson
ac2d782266
Pass in mock config object to tests and validate telemetry_enabled?
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-05-03 16:07:24 -07:00
Ryan Davis
476c6878b3
Modernize use of Minitest.
...
+ Turn off verbosity in Rakefile by default. Use `rake V=1` to turn back on.
+ MiniTest -> Minitest everywhere.
+ MiniTest::Unit::TestCase -> Minitest::Test everywhere.
+ Updated minitest doco urls to official and up-to-date site.
+ Normalize requires. Only needs "minitest/autorun" and "minitest/pride".
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-05-03 15:01:57 -07:00
Clinton Wolfe
1552dc0210
Merge branch 'cw/use-deprecation-everywhere-3-port' of github.com:inspec/inspec into cw/use-deprecation-everywhere-4-port
2019-04-16 17:42:45 -04:00
Jerry Aldrich
40031a9b83
Use deprecation facility throughout code
...
This converts all current deprecation warnings/TODOs to use the
`Inspec.deprecate()` deprecation facility.
This also modifies `Inspec.deprecate()` to only require 1 argument.
Signed-off-by: Jerry Aldrich <jerryaldrichiii@gmail.com>
2019-04-11 19:15:01 -04:00
Miah Johnson
5adf33469a
improve testing for DataSeries#to_h and DataSeries#to_json
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-04-11 12:22:29 -07:00
Miah Johnson
55ea2d984c
Not sure how to make this not dependant on list_data_series to prove its
...
functionality.
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-04-11 12:17:59 -07:00
Miah Johnson
3c6db15124
improve tests for Collector#list_data_series
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-04-11 11:47:42 -07:00
Miah Johnson
ac78feb090
Remove list_data_series_by_name
.
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-04-11 00:41:09 -07:00
Miah Johnson
56a5c80bf5
Rebuild the core telemetry interface.
...
Signed-off-by: Miah Johnson <miah@chia-pet.org>
2019-04-09 16:58:40 -07:00
Clinton Wolfe
d31a13efc6
Two more test files needed mock updates
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2019-02-01 14:24:26 -05:00
Jerry Aldrich
f5ec7c9c65
Fix style/RuboCop on cw/deprecation-facility
...
Signed-off-by: Jerry Aldrich <jerryaldrichiii@gmail.com>
2019-01-14 13:57:59 -08:00
Clinton Wolfe
b2bb8c062b
Last polish on the unit tests, all pass
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2019-01-10 23:54:50 -08:00
Clinton Wolfe
642d8d61b6
Funcitonal tests pass; some unit tests fail
...
Signed-off-by: Clinton Wolfe <clintoncwolfe@gmail.com>
2019-01-10 23:54:50 -08:00