Skip to content

Commit

Permalink
remove timezone updates within tests - should be done by tester befor…
Browse files Browse the repository at this point in the history
…e running tests
  • Loading branch information
kellyjonbrazil committed Apr 28, 2024
1 parent 2dcf0e2 commit d5398c7
Show file tree
Hide file tree
Showing 16 changed files with 0 additions and 113 deletions.
7 changes: 0 additions & 7 deletions tests/test_date.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.date

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_dig.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.dig

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_dir.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.dir

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_jc_utils.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,7 @@
import os
import sys
import time
import unittest
import jc.utils

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_last.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.last

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_ls.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.ls

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
8 changes: 0 additions & 8 deletions tests/test_ls_s.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,11 @@
import os
import sys
import time
import json
import unittest
from jc.exceptions import ParseError
import jc.parsers.ls_s

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


# To create streaming output use:
# $ cat ls-al.out | jc --ls-s | jello -c > ls-al-streaming.json

Expand Down
7 changes: 0 additions & 7 deletions tests/test_rpm_qai.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import unittest
import json
import jc.parsers.rpm_qi

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_rsync_s.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.rsync_s

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


# To create streaming output use:
# $ cat rsync.out | jc --rsync-s | jello -c > rsync-streaming.json
Expand Down
7 changes: 0 additions & 7 deletions tests/test_stat.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.stat

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_stat_s.py
Original file line number Diff line number Diff line change
@@ -1,18 +1,11 @@
import os
import sys
import time
import json
import unittest
from jc.exceptions import ParseError
import jc.parsers.stat_s

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


# To create streaming output use:
# $ cat stat.out | jc --stat-s | jello -c > stat-streaming.json
Expand Down
7 changes: 0 additions & 7 deletions tests/test_systeminfo.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import json
import os
import sys
import time
import unittest
import jc.parsers.systeminfo

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):
test_files = [
Expand Down
7 changes: 0 additions & 7 deletions tests/test_upower.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.upower

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
# if not sys.platform.startswith('win32'):
# os.environ['TZ'] = 'America/Los_Angeles'
# time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_vmstat.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.vmstat

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down
7 changes: 0 additions & 7 deletions tests/test_vmstat_s.py
Original file line number Diff line number Diff line change
@@ -1,18 +1,11 @@
import os
import sys
import time
import json
import unittest
from jc.exceptions import ParseError
import jc.parsers.vmstat_s

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


# To create streaming output use:
# $ cat vmstat.out | jc --vmstat-s | jello -c > vmstat-streaming.json
Expand Down
7 changes: 0 additions & 7 deletions tests/test_who.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
import os
import sys
import time
import json
import unittest
import jc.parsers.who

THIS_DIR = os.path.dirname(os.path.abspath(__file__))

# Set the timezone on POSIX systems. Need to manually set for Windows tests
if not sys.platform.startswith('win32'):
os.environ['TZ'] = 'America/Los_Angeles'
time.tzset()


class MyTests(unittest.TestCase):

Expand Down

0 comments on commit d5398c7

Please sign in to comment.