summaryrefslogtreecommitdiffstats
path: root/src/go/collectors/go.d.plugin/modules/pihole/testdata
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/go/collectors/go.d.plugin/modules/pihole/testdata/config.json21
-rw-r--r--src/go/collectors/go.d.plugin/modules/pihole/testdata/config.yaml18
-rw-r--r--src/go/collectors/go.d.plugin/modules/pihole/testdata/getForwardDestinations.json7
-rw-r--r--src/go/collectors/go.d.plugin/modules/pihole/testdata/getQueryTypes.json11
-rw-r--r--src/go/collectors/go.d.plugin/modules/pihole/testdata/setupVars.conf11
-rw-r--r--src/go/collectors/go.d.plugin/modules/pihole/testdata/summaryRaw.json27
6 files changed, 95 insertions, 0 deletions
diff --git a/src/go/collectors/go.d.plugin/modules/pihole/testdata/config.json b/src/go/collectors/go.d.plugin/modules/pihole/testdata/config.json
new file mode 100644
index 000000000..2d82443b0
--- /dev/null
+++ b/src/go/collectors/go.d.plugin/modules/pihole/testdata/config.json
@@ -0,0 +1,21 @@
+{
+ "update_every": 123,
+ "url": "ok",
+ "body": "ok",
+ "method": "ok",
+ "headers": {
+ "ok": "ok"
+ },
+ "username": "ok",
+ "password": "ok",
+ "proxy_url": "ok",
+ "proxy_username": "ok",
+ "proxy_password": "ok",
+ "timeout": 123.123,
+ "not_follow_redirects": true,
+ "tls_ca": "ok",
+ "tls_cert": "ok",
+ "tls_key": "ok",
+ "tls_skip_verify": true,
+ "setup_vars_path": "ok"
+}
diff --git a/src/go/collectors/go.d.plugin/modules/pihole/testdata/config.yaml b/src/go/collectors/go.d.plugin/modules/pihole/testdata/config.yaml
new file mode 100644
index 000000000..a9361246a
--- /dev/null
+++ b/src/go/collectors/go.d.plugin/modules/pihole/testdata/config.yaml
@@ -0,0 +1,18 @@
+update_every: 123
+url: "ok"
+body: "ok"
+method: "ok"
+headers:
+ ok: "ok"
+username: "ok"
+password: "ok"
+proxy_url: "ok"
+proxy_username: "ok"
+proxy_password: "ok"
+timeout: 123.123
+not_follow_redirects: yes
+tls_ca: "ok"
+tls_cert: "ok"
+tls_key: "ok"
+tls_skip_verify: yes
+setup_vars_path: "ok"
diff --git a/src/go/collectors/go.d.plugin/modules/pihole/testdata/getForwardDestinations.json b/src/go/collectors/go.d.plugin/modules/pihole/testdata/getForwardDestinations.json
new file mode 100644
index 000000000..3bfc646d0
--- /dev/null
+++ b/src/go/collectors/go.d.plugin/modules/pihole/testdata/getForwardDestinations.json
@@ -0,0 +1,7 @@
+{
+ "forward_destinations": {
+ "blocked|blocked": 2.2,
+ "cached|cached": 88.4,
+ "other|other": 9.4
+ }
+} \ No newline at end of file
diff --git a/src/go/collectors/go.d.plugin/modules/pihole/testdata/getQueryTypes.json b/src/go/collectors/go.d.plugin/modules/pihole/testdata/getQueryTypes.json
new file mode 100644
index 000000000..cf7f19f95
--- /dev/null
+++ b/src/go/collectors/go.d.plugin/modules/pihole/testdata/getQueryTypes.json
@@ -0,0 +1,11 @@
+{
+ "querytypes": {
+ "A (IPv4)": 12.29,
+ "AAAA (IPv6)": 12.29,
+ "ANY": 1,
+ "SRV": 1,
+ "SOA": 1,
+ "PTR": 71.43,
+ "TXT": 1
+ }
+} \ No newline at end of file
diff --git a/src/go/collectors/go.d.plugin/modules/pihole/testdata/setupVars.conf b/src/go/collectors/go.d.plugin/modules/pihole/testdata/setupVars.conf
new file mode 100644
index 000000000..97f260297
--- /dev/null
+++ b/src/go/collectors/go.d.plugin/modules/pihole/testdata/setupVars.conf
@@ -0,0 +1,11 @@
+WEBPASSWORD=1ebd33f882f9aa5fac26a7cb74704742f91100228eb322e41b7bd6e6aeb8f74b
+BLOCKING_ENABLED=true
+PIHOLE_INTERFACE=enp0s9
+IPV4_ADDRESS=192.168.88.228/24
+IPV6_ADDRESS=
+PIHOLE_DNS_1=208.67.222.222
+PIHOLE_DNS_2=208.67.220.220
+QUERY_LOGGING=true
+INSTALL_WEB_SERVER=true
+INSTALL_WEB_INTERFACE=true
+LIGHTTPD_ENABLED=true \ No newline at end of file
diff --git a/src/go/collectors/go.d.plugin/modules/pihole/testdata/summaryRaw.json b/src/go/collectors/go.d.plugin/modules/pihole/testdata/summaryRaw.json
new file mode 100644
index 000000000..8a4e59c16
--- /dev/null
+++ b/src/go/collectors/go.d.plugin/modules/pihole/testdata/summaryRaw.json
@@ -0,0 +1,27 @@
+{
+ "domains_being_blocked": 1,
+ "dns_queries_today": 1,
+ "ads_blocked_today": 1,
+ "ads_percentage_today": 1,
+ "unique_domains": 1,
+ "queries_forwarded": 1,
+ "queries_cached": 1,
+ "clients_ever_seen": 1,
+ "unique_clients": 1,
+ "dns_queries_all_types": 1,
+ "reply_NODATA": 1,
+ "reply_NXDOMAIN": 1,
+ "reply_CNAME": 1,
+ "reply_IP": 1,
+ "privacy_level": 1,
+ "status": "enabled",
+ "gravity_last_updated": {
+ "file_exists": true,
+ "absolute": 1560443834,
+ "relative": {
+ "days": "3",
+ "hours": "06",
+ "minutes": "05"
+ }
+ }
+} \ No newline at end of file