foreman_discovery 15.0.2 → 15.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/foreman_discovery/version.rb +1 -1
- data/locale/ca/foreman_discovery.edit.po +158 -69
- data/locale/de/foreman_discovery.edit.po +157 -67
- data/locale/en_GB/foreman_discovery.edit.po +158 -69
- data/locale/es/foreman_discovery.edit.po +158 -69
- data/locale/foreman_discovery.pot +2 -2
- data/locale/fr/foreman_discovery.edit.po +157 -67
- data/locale/gl/foreman_discovery.edit.po +158 -69
- data/locale/it/foreman_discovery.edit.po +158 -69
- data/locale/ja/foreman_discovery.edit.po +158 -71
- data/locale/ko/foreman_discovery.edit.po +157 -69
- data/locale/pt_BR/foreman_discovery.edit.po +158 -69
- data/locale/ru/foreman_discovery.edit.po +159 -72
- data/locale/sv_SE/foreman_discovery.edit.po +158 -69
- data/locale/zh_CN/foreman_discovery.edit.po +158 -71
- data/locale/zh_TW/foreman_discovery.edit.po +158 -71
- data/test/integration/discovered_hosts_test.rb +5 -11
- data/test/unit/discovery_attribute_set_test.rb +12 -10
- metadata +3 -2
@@ -9,6 +9,7 @@ class DiscoveredHostsTest < IntegrationTestWithJavascript
|
|
9
9
|
assert discovered_notification_blueprint
|
10
10
|
discovered_host.save!
|
11
11
|
visit discovered_hosts_path
|
12
|
+
page.evaluate_script("document.getElementById('fixedPropertiesSelector-#{discovered_host.id}').classList.remove('fade')")
|
12
13
|
end
|
13
14
|
|
14
15
|
teardown do
|
@@ -64,15 +65,14 @@ class DiscoveredHostsTest < IntegrationTestWithJavascript
|
|
64
65
|
|
65
66
|
test 'and forwards to editing it' do
|
66
67
|
create_host
|
67
|
-
|
68
|
-
current_path
|
68
|
+
assert_current_path edit_discovered_host_path(id: discovered_host), ignore_query: true
|
69
69
|
end
|
70
70
|
|
71
71
|
context 'with a Hostgroup selected' do
|
72
72
|
let(:discovery_hostgroup) { Hostgroup.first }
|
73
73
|
|
74
74
|
test 'it passes it on' do
|
75
|
-
|
75
|
+
select2(discovery_hostgroup.name, from: 'host_hostgroup_id')
|
76
76
|
create_host
|
77
77
|
assert_param discovery_hostgroup.id.to_s,
|
78
78
|
'host.hostgroup_id'
|
@@ -83,7 +83,7 @@ class DiscoveredHostsTest < IntegrationTestWithJavascript
|
|
83
83
|
let(:discovery_location) { Location.first }
|
84
84
|
|
85
85
|
test 'it passes it on' do
|
86
|
-
|
86
|
+
select2(discovery_location.name, from: 'host_location_id')
|
87
87
|
create_host
|
88
88
|
assert_param discovery_location.id.to_s,
|
89
89
|
'host.location_id'
|
@@ -94,7 +94,7 @@ class DiscoveredHostsTest < IntegrationTestWithJavascript
|
|
94
94
|
let(:discovery_organization) { Organization.first }
|
95
95
|
|
96
96
|
test 'it passes it on' do
|
97
|
-
|
97
|
+
select2(discovery_organization.name, from: 'host_organization_id')
|
98
98
|
create_host
|
99
99
|
assert_param discovery_organization.id.to_s,
|
100
100
|
'host.organization_id'
|
@@ -147,12 +147,6 @@ class DiscoveredHostsTest < IntegrationTestWithJavascript
|
|
147
147
|
page.find("#host_ids_#{id}").click
|
148
148
|
end
|
149
149
|
|
150
|
-
def select_from(element_id, id)
|
151
|
-
page.find_by_id(element_id, visible: false)
|
152
|
-
.find("option[value='#{id}']", visible: false)
|
153
|
-
.select_option
|
154
|
-
end
|
155
|
-
|
156
150
|
def create_host
|
157
151
|
page.find("#fixedPropertiesSelector-#{discovered_host.id}")
|
158
152
|
.find_button('Create Host').click
|
@@ -41,15 +41,17 @@ class DiscoveryAttributeSetTest < ActiveSupport::TestCase
|
|
41
41
|
end
|
42
42
|
|
43
43
|
test "can search discovered hosts by disks_size" do
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
44
|
+
begin
|
45
|
+
excluded = Setting[:excluded_facts]
|
46
|
+
Setting[:excluded_facts] = ["test"]
|
47
|
+
host = discover_host_from_facts(@facts)
|
48
|
+
disks_size = (host.facts_hash['blockdevice_sda_size'].to_f / 1024 / 1024).ceil
|
49
|
+
results = Host::Discovered.unscoped.search_for("disks_size = #{disks_size}")
|
50
|
+
assert_equal 1, results.count
|
51
|
+
results = Host::Discovered.unscoped.search_for("disks_size > #{disks_size}")
|
52
|
+
assert_equal 0, results.count
|
53
|
+
ensure
|
54
|
+
Setting[:excluded_facts] = excluded
|
55
|
+
end
|
54
56
|
end
|
55
57
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreman_discovery
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 15.0
|
4
|
+
version: 15.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Aditi Puntambekar
|
@@ -45,6 +45,7 @@ authors:
|
|
45
45
|
- odovzhenko
|
46
46
|
- Ohad Levy
|
47
47
|
- Ondrej Prazak
|
48
|
+
- Ondřej Ezr
|
48
49
|
- Ori Rabin
|
49
50
|
- orrabin
|
50
51
|
- Partha Aji
|
@@ -68,7 +69,7 @@ authors:
|
|
68
69
|
autorequire:
|
69
70
|
bindir: bin
|
70
71
|
cert_chain: []
|
71
|
-
date: 2019-08-
|
72
|
+
date: 2019-08-09 00:00:00.000000000 Z
|
72
73
|
dependencies: []
|
73
74
|
description: MaaS Discovery Plugin engine for Foreman
|
74
75
|
email: gsutclif@redhat.com
|