Commit Graph

643 Commits

Author SHA1 Message Date
Daniel W. Anner
3d0803957d
PR CI Testing (#1472)
* Pytest Optimizations (#1465)

* Adding function to determin file changes from upstream via git

* updated test env function to properly skip when files are empty

* updating to use generated slug list

* fixing if statement

* added known slugs functionality to improve runtime

* updating slugs for using git repo

* adding final changes

* updating library url to be correct

* Update master-slugs.yml

* commit to force pr merge (#1466)

* Pytest pr (#1467)

* commit to force pr merge

* commit to force pr merge

* Update master-slugs.yml

* Regenerate master slug list after successful PR merge

* Update master-slugs.yml

* fianl changes to new master slug workflow (#1468)

* Final pr test (#1469)

* fianl changes to new master slug workflow

* trying new branch push

* changing to myself (#1470)

* testing permission on github_token

* testing permission on github_token

---------

Co-authored-by: NetBox Bot <info@netboxlabs.com>
2023-07-19 10:24:20 -04:00
Daniel W. Anner
d0cb58d96e
Adding Tests: Device Power (#1463)
* broke component validation out to its own function. Adding logic for validating device power input.

* Added console-port poe true for adapters. Updating devices to add proper power sources.

* Adding switches to allow for tests to properly determine POE status.

* Fixing files with missing power definitions.
2023-07-17 15:23:56 -04:00
Daniel W. Anner
4ac4c79ab1
Updating comments and error messages for better readability and validation (#1457) 2023-07-14 15:38:14 -04:00
Daniel W. Anner
c95b166139
Implementing Test Updates (Slugs & File Names) (#1454)
* breaking out tests for easier usage

* refactoring codebase

* Added verification for properly formatted slug and fixed definitions that were incorrect

* Adding new test case to ensure the file name matches either the slug or the part_number

* fixed file names to match proper formatting
2023-07-12 20:00:44 -04:00
aurelienbyi
ad8ad1589e
directory separator appropriate for exec env (#1250)
Co-authored-by: aurelien.bailly <aurelien.bailly@destiny.eu>
2023-04-01 15:44:41 -04:00
J vanBemmel
3bf511ece6
Nokia add images new location (#1233)
* Re-add front/rear images following new location & filename conventions

* Renamed following exact match slug convention

* Debug test failing

* Different log msg

* More debug

* Filter on startswith(slug)

* Debug

* Quotes

* Updated filter

* Match on string part
2023-03-27 15:06:48 -04:00
Daniel W. Anner
f78c90d38b
Adding elevation images folder and test logic (#1225)
* Added new test code for elevation images. Added elevation folder.

* Also adding first file with image definitions
2023-03-24 16:50:47 -04:00
Jonathan Senecal
1a4447a075
Fix float validation using decimal.Decimal (#1073)
* Fix float validation using decimal.Decimal

* Force string repr of the float when loading yaml

---------

Co-authored-by: Jonathan Senecal <jonathan.senecal@metrooptic.com>
2023-01-31 09:42:16 -05:00
Andrew Imeson
66c75604d6
Fix pre-commit and update CI (#875) 2022-08-10 22:29:59 -04:00
Michael Klose
d8ce2765c4
Extend tests to check for null/empty values (#687)
Fixes #686
2022-02-25 10:23:46 -05:00
jeremystretch
c1f6cecb21 Combine validation and duplication tests for efficiency 2022-02-18 14:47:13 -05:00
Jeremy Stretch
8ca95dacef
Module types (#659)
* Extend tests to support moule types

* Add Juniper EX9200-32XS module type

* Fix YAML formatting
2022-02-11 16:22:59 -05:00
Michael Klose
24a9875c29
Add missing types to schema.json (#637) 2022-01-27 20:20:23 -05:00
Kristin Davidson
5a494d0487
Update Ubiquiti USW-Aggregation and UDM-Pro (#622)
* Update Ubiquiti USW-Aggregation switch to 8 ports instead of 10
* Update UDM-Pro model name to be the full name, add part number, airflow, and make it not full-depth
* Include UniFi brand name in UDM-Pro model name
* Add airflow field to device type schema
2022-01-24 13:42:40 -05:00
David Mc Ken
ae0e7d6c6d
Add ubnt af 5xhd (#627)
* Create AF-5XHD.yml
* Added bridge to schema tests
2022-01-24 08:52:41 -05:00
Michael Klose
879be46758
Fix #616 Unknown properties are ignored during schema validation (#621)
* Fix Unknown properties are ignored during schema validation #616
* Fix misspelled properties in files
2022-01-06 13:37:24 -05:00
jeremystretch
14217f3be4 Closes #614: Add support for module bays and inventory items 2021-12-30 13:51:30 -05:00
jeremystretch
dfc7ba6df5 Closes #613: Add support for component labels 2021-12-30 13:41:40 -05:00
Michael Klose
fd6fc1f7bb
Rename optic type 128gfc-sfp28 to 128gfc-qsfp28 (#600) 2021-12-17 11:31:56 -05:00
Flo
5fe42cf3c9
Update schema.json (#562) 2021-11-13 13:29:18 -05:00
Flo
53173620c2
Update schema.json (#556) 2021-11-11 20:20:50 -05:00
Scott Crace
485027a3b5
Adding Dell PowerEdge MX7000 device type (#440)
* Adding Dell PowerEdge MX7000 device type
* Add c21/c22 to schema

Co-authored-by: Scott Crace <scrace@momentumbusiness.com>
2021-08-25 17:18:51 -04:00
Gauthier
0b814f2088
Ubiquiti er es usg (#384) 2021-05-11 16:10:54 -04:00
Ryan Merolle
7b303a5ace
YAML Formatting & Validation (#347)
* leverage yamllint in GitHub actions 

* add pre-commits

* validation updates

* Update README.md

* Update CONTRIBUTING.md
2021-02-27 07:25:47 -05:00
Ryan Merolle
b72a71d0e4
update scheema.json to match netbox choices (#300) 2020-12-31 09:34:29 -05:00
Daniel Sheppard
f9704f0736
Add duplicate component test 2020-11-24 13:10:31 -06:00
Daniel Sheppard
c9f6a02e4a
Update test_definitions.py 2020-11-24 12:25:06 -06:00
Daniel Sheppard
8db3fe1dcd
Update test_dupes.py 2020-11-24 12:22:23 -06:00
Nick Kuzmik
e5c4414f8a Per #175, check for duplicate devices. I am comparing slugs, and found a duplicate Generic device already. 2020-07-17 12:38:58 -04:00
Ryan Merolle
97f48ec440
update json schema to netbox-community/netbox#4784 (#167) 2020-07-05 13:30:25 -04:00
Ryan Merolle
4a8f433f88
Add NEMA L14 & L20 (#136)
Adds to validation / schema.json:
- NEMA L14-20P
- NEMA L14-30P
- NEMA L21-20P
- NEMA L21-30P
- NEMA L14-20R
- NEMA L14-30R
- NEMA L21-20R
- NEMA L21-30R
2020-05-20 11:39:06 -04:00
Jeremy Stretch
3370771aec Add MRJ21 port type (NetBox #4284) 2020-03-03 10:24:34 -05:00
Ken Partridge
915ce60c2a Added serial console_port type rj-11 for a POTS modem connection in console-port / tests/schema.json 2020-02-19 10:57:26 -08:00
ryanmerolle
5965a596ab California Style Connectors added 2020-01-03 14:43:57 -05:00
ryanmerolle
68cfb19287 schema update to handle rj12 serial on some PDUs 2020-01-03 13:35:51 -05:00
Jeremy Stretch
05fa6e535a Closes #26: Validate slug charset 2019-12-30 10:18:13 -05:00
Jeremy Stretch
1c98c069b8 Closes #27: Check that definition files end with a blank line 2019-12-30 10:11:25 -05:00
Jeremy Stretch
912b0187d7 Match all files but validate extensions 2019-12-26 15:36:28 -05:00
Jeremy Stretch
2365e49146 Add missing subdevice_role attribute to schema 2019-12-19 13:41:43 -05:00
Jeremy Stretch
4dcaf14b4e Change vendors/ to device-types/ 2019-12-19 13:23:05 -05:00
Jeremy Stretch
3e36dc4c4c Add a simple environment test for sanity checking 2019-12-19 11:14:33 -05:00
Jeremy Stretch
268d8cc43c Employ more elegant error reporting in tests 2019-12-19 11:08:51 -05:00
Jeremy Stretch
f15ec47c6c Introduced unit tests for definition files 2019-12-19 10:22:26 -05:00