Commit Graph

78 Commits

Author SHA1 Message Date
Jeremiah Leary 7a3fcf9883 Updates for issue #434:
Adding rules to align declaration identifiers:

  1)  Updated documentation
  2)  Removed the following rules
      file_003, constant_003, attribute_003, signal_003, subtype_003, type_003 and variable_003
  3)  Added new rules:
      architecture_029, function_015, package_019, procedure_010 and process_037
  4)  Added tests for new rules
  5)  Updated classifiers to support new rules
2020-06-30 11:36:01 -05:00
Martin Dörfelt 99ce2000cf fixed review remarks
- Used a more appropriate method for extracting labels.
- Improved the error message of "prefix_rule".
2020-06-27 08:31:05 +02:00
Martin Dörfelt b90d94cbcf added rules for generate and process label prefixes 2020-06-25 21:42:27 +02:00
Jeremiah Leary de942890b3 Updates for issue #385:
The rule process_031 was attempting to align variables defined in function and procedures with variables outside functions and procedures in the process declarative region.

  1)  Updated tests to expose issue
  2)  Fixed to make tests pass

Additional issue found with handling indents on processes with just 'process is' when updating tests.

  1)  Fixed code to make tests pass
2020-05-09 09:12:19 -05:00
Jeremiah Leary cafe651a15 Updates for issue #379:
Rule process_019 was not honoring records.

  1)  Updated tests
  2)  Updated clock detection
  3)  Update rule process_019
2020-04-27 20:20:51 -05:00
Jeremiah C Leary 6b4a45791d Updates for issue #362
Changing utils.get_violation_linenumber to utils.get_violation_line_number.
2020-04-01 21:11:38 -05:00
Jeremiah C Leary e60c516548 Updates for Codacy and Codeclimate issues 2020-03-31 21:34:38 -05:00
Jeremiah C Leary 01746e70ea Merge branch 'master' into issue-362 2020-03-31 21:16:50 -05:00
Michał Kruszewski b6226ecb7d Set the default case to lowercase for all case rules. 2020-03-29 21:26:15 +02:00
Jeremiah C Leary 7d85a98db4 Updates for issue #362:
Interim commit to move all rules to new violation dictionary format.
2020-03-29 13:09:38 -05:00
Michał Kruszewski 0f0ec0f47c Refactor keyword alignment rules - part 2. 2020-03-17 11:22:25 +01:00
Michał Kruszewski 2f08a64bda Refactor keyword alignment rules. 2020-02-24 21:14:44 +01:00
Jeremiah C Leary 650a4b13b9 Updates for issue #314:
utils.extract_label will now extract a label from the beginning or end of a line.

It calls either utils.extract_begin_label or utils.extract_end_label.
2020-02-23 11:22:22 -06:00
Jeremiah C Leary 7d940306ec Updates for issue #314 and issue #333:
Issue #314:

Updated all label rules to use utils.extract_label or utils.extract_end_label:

  1) Added utils.extract_end_label
  2) Added more end label attributes to line.py
  3) Updated classifiers to set the new end label attributes
  4) Updated tests
  5) Updated rules to use utils.extract_label or utils.extract_end_label

Issue #333:

Fixed bug where nested generate labels were not updated correctly:

  1)  Added test case
  2)  Updated code
2020-02-23 10:51:44 -06:00
Jeremiah C Leary b32eb8ffe6 Updates for issue #335:
Updated process rules to use a dictionary for the violations list.

  1)  Updated code
  2)  Updated tests
2020-02-16 09:51:38 -06:00
Jeremiah C Leary e8f3f4ad71 Updates for issue #335
Switched self.dFix in process_018 to use dViolation.

  1) Added additional test case
  2) Updated code
  3) Updated existing test case
  4) Added function to test.utils to add the proper formatting of violations during the check.
2020-02-15 09:53:44 -06:00
Michał Kruszewski e3805c9d54 Replace extract_first_keyword calls with extract_words function. 2020-01-20 21:17:41 +01:00
Jeremiah C Leary 947a32a44a Added exception handling for invalid clock configurations. 2020-01-08 21:03:25 -06:00
Jeremiah C Leary f684b4b0a7 Updates for issue #319:
Added ability to configure either 'event or _edge for clock definitions:

  1)  Updated documentation
  2)  Added isClockDefinition to line object
  3)  Updated process classification to set isClockDefinition
  4)  Updated tests
  5)  Updated rule process_029
2020-01-06 22:18:07 -06:00
Jeremiah C Leary e7a91cef71 Fixing formatting issues flagged by Codacy. 2020-01-02 11:23:09 -06:00
Michał Kruszewski a35faba2b9 Fix case rules for process rules. 2019-12-31 12:41:08 +01:00
Jeremiah C Leary f0c474c695 Updates for issue #280:
The rule process_012 would add the *is* keyword to the end of the process sensitivity list without removing an *is* keyword if it existed on a different line.

  1)  Updated documentation
  2)  Updated tests
  3)  Updated process classifier
  4)  Added isProcessIs line attribute
  5)  Updated rule process_012 to remove the *is* keyword if is exists on a seperate line.
2019-12-05 09:52:59 -06:00
Jeremiah C Leary a918976c22 Updates for issue #278:
Added subphases to allow rules within a phase to be executed in the proper order.

  1)  Updated documentation
  2)  Added subphases to rule_list.fix() method
2019-11-27 07:44:27 -06:00
Jeremiah C Leary a374867c40 Refactoring fix.upper_case and fix.lower_case to remove unneccessary input. 2019-10-16 21:36:30 -05:00
Jeremiah C Leary f866d1d89b Updates for Codacy issues. 2019-10-15 18:40:43 -05:00
Michał Kruszewski 9f1389c8e8 Fix printing solution for case rules. 2019-10-15 15:57:01 +02:00
Jeremiah C Leary 23bc434ff6 Updates for issue #257:
Process labels not on the same line as the process must be moved to the same line as the process keyword.

  1)  Updated documentation
  2)  Added tests
  3)  Added rule process_032
2019-10-13 11:16:29 -05:00
Michał Kruszewski c962881e7a Make _extract abstract method for case_rule class. 2019-10-07 20:30:27 +02:00
Michał Kruszewski 694625b024 Make case rule 014 use case_rule as a base. 2019-10-07 16:13:27 +02:00
Michał Kruszewski 3b7e423dae Make process rule 008 use case_rule as a base. 2019-10-07 14:58:08 +02:00
Michał Kruszewski b2b5e822d5 Remove uppercase_end_label rule. 2019-10-07 14:08:48 +02:00
Jeremiah C Leary 8acd9604c0 Updates for issue #232:
Updated process_030 to specifically look for a single signal every line of a sensitivity list.

  1)  Updated tests
  2)  Updated rule
2019-06-08 15:22:15 -05:00
Jeremiah C Leary 11123430a8 Updates for issue #232
Fixing typo in solution.
2019-06-08 11:32:09 -05:00
Jeremiah C Leary 016f65d6b0 Updates for issue #226
Refactoring the following rules for code coverage:

   architecture_024
   instantiation_010
   port_011
   process_018
   process_031
   sequential_004
2019-04-10 20:21:11 -05:00
Jeremiah C Leary 175621833c Updates for issue #226
Refactoring code tags logic to improve code coverage.
2019-04-05 07:57:24 -05:00
Jeremiah C Leary f42e698c31 Updates for issue #219
Changed utilities to utils.
2019-03-23 07:43:53 -05:00
Jeremiah C Leary 5e5a7b46d4 Refactoring process_019 and generate_012 for codeclimate. 2019-03-19 21:16:43 -05:00
Jeremiah C Leary 6a04dae1c3 Updates for issue #181
1)  Adding vsg off checking to rules which override the base rule class analysis method.
2019-03-10 11:50:46 -05:00
Jeremiah C Leary 5ff634025c Updates for issue #181
Refactoring more rules to support implementing in file tags.
2019-03-09 16:42:31 -06:00
Jeremiah C Leary 2fd456aec3 Updates for issue #181
Refactoring rules to support implementing in file tags.
2019-03-09 15:38:39 -06:00
Jeremiah C Leary 48563434cd Updates to address codeclimate issues. 2019-03-02 09:29:53 -06:00
Jeremiah C Leary 15d39274c3 Updates for issue #206
1)  Fixing Codacy issues
2019-02-24 09:42:29 -06:00
Clifton Somers aca8cce884 successfully implemented process label fixingw 2019-02-16 14:04:23 -06:00
Jeremiah C Leary 9a68c25937 Fixing issues identified by Codacy. 2018-12-18 08:43:16 -06:00
Jeremiah C Leary 59d097ed73 Updates for issue #192
Worked out all the issues with the new rule.

  1)  Updated documentation
  2)  Updated check and fix classes to support new rule
  3)  Updated tests
  4)  Updated rule to work correctly
2018-12-17 19:31:43 -06:00
Jeremiah C Leary 97450b89b6 Updates for issue #192
1)  Moved whitespace_012 to process_031
  2)  Added checks for alignment of colons
  3)  Added documentation
2018-12-16 10:49:27 -06:00
Jeremiah C Leary 43e0259612 Updates for issue #154
Added process_030 to detect a single signal on a single line of a process sensitivity list, minus the last line.

  1)  Added test
  2)  Added rule
  3)  Added documentation
2018-12-06 17:44:32 -06:00
Jeremiah C Leary 2ac0e8ee8e Updates for issue #184
Added support for processs without sensitivity lists.
2018-12-01 10:09:17 -06:00
Ryan Fitzsimon 79456cf1a2 Use explicit relative imports
Implicit relative imports are not supported in Python 3 (see pep-0404).

Using explicit relative imports also helps avoid name clashes.
2018-08-31 11:24:13 +10:00
Jeremiah C Leary 742a808003 Updates for issue #152
1)  Made process_029 less greedy when searching for rising_edge and falling_edge
2018-07-30 21:50:21 -05:00