Skip to content

Commit

Permalink
Fix default setting for clean_logs (#38)
Browse files Browse the repository at this point in the history
* Make default None for clean_logs

* Update CHANGELOG

* Bump version to 1.0.0-rc.3

* Update condition
  • Loading branch information
yashpatel6 authored May 30, 2023
1 parent 3e9a326 commit 03b239b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,12 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm

---

## [1.0.0-rc.3] - 2023-05-25
### Fixed
- Properly set default value of `clean_logs` according to case and global settings

---

## [1.0.0-rc.2] - 2023-03-09
### Added
- Case name to output directory path to avoid over-writing
Expand Down
4 changes: 2 additions & 2 deletions nftest/NFTestCase.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def __init__(self, name:str=None, message:str=None, nf_script:str=None,
nf_configs:List[str]=None, profiles:List[str]=None, params_file:str=None,
output_directory_param_name:str='output_dir',
asserts:List[NFTestAssert]=None, temp_dir:str=None,
remove_temp:bool=None, clean_logs:bool=True,
remove_temp:bool=None, clean_logs:bool=None,
skip:bool=False, verbose:bool=False):
""" Constructor """
self._env = NFTestENV()
Expand Down Expand Up @@ -136,7 +136,7 @@ def combine_global(self, _global:NFTestGlobal) -> None:
if not self.temp_dir:
self.temp_dir = _global.temp_dir

if not self.clean_logs:
if self.clean_logs is None:
self.clean_logs = _global.clean_logs

def print_prolog(self):
Expand Down
2 changes: 1 addition & 1 deletion nftest/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
""" nftest module """

__version__ = '1.0.0-rc.2'
__version__ = '1.0.0-rc.3'

0 comments on commit 03b239b

Please sign in to comment.