Skip to content

Commit 53f672b

Browse files
committed
Redoing the plugin fixtures for testing
1 parent 03bf7e2 commit 53f672b

File tree

27 files changed

+179
-42
lines changed

27 files changed

+179
-42
lines changed

β€Žtests/fixtures/pluginsystem/install_plugins.pyβ€Ž

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,18 @@
33

44

55
plugin_paths = [
6-
"plugins/tmuxp_plugin_one",
7-
"plugins/tmuxp_plugin_two"
6+
"plugins/tmuxp_plugin_interface",
7+
"plugins/tmuxp_test_plugin_bwb",
8+
"plugins/tmuxp_test_plugin_bs",
9+
"plugins/tmuxp_test_plugin_r",
10+
"plugins/tmuxp_test_plugin_owc",
11+
"plugins/tmuxp_test_plugin_awf",
812
]
913

1014

1115
def install(package):
1216
subprocess.check_call([sys.executable, "-m", "pip", "install", package])
13-
17+
1418

1519
def install_plugins():
1620
for plugin in plugin_paths:
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
from setuptools import setup
22

33
setup(
4-
name='tmuxp-plugin-one',
4+
name='tmuxp_plugin_interface',
55
version='0.0.1',
66
author='Joseph Flinn',
77
author_email='joseph.s.flinn@gmail.com',
88
packages=setuptools.find_packages(),
9-
description='A tmuxp plugin to test the plugin system',
9+
description='A tmuxp plugin class interface',
1010
)
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
class TestPluginTwo:
1+
class TmuxpPluginInterface:
22
def __init__(self):
3-
self.message = f'[+] This is the Tmuxp Test Plugin'
3+
pass
44

55
def before_workspace_builder(self, session):
66
pass
@@ -12,8 +12,7 @@ def reattach(self, session):
1212
pass
1313

1414
def on_window_create(self, window):
15-
if window.name == 'editor':
16-
pass
15+
pass
1716

1817
def after_window_finished(self, window):
19-
pass
18+
pass

β€Žtests/fixtures/pluginsystem/plugins/tmuxp_plugin_one/tmuxp_plugin_one/plugin.pyβ€Ž

Lines changed: 0 additions & 19 deletions
This file was deleted.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
from setuptools import setup
2+
3+
setup(
4+
name='tmuxp_test_plugin_awf',
5+
version='0.0.1',
6+
author='Joseph Flinn',
7+
author_email='joseph.s.flinn@gmail.com',
8+
packages=setuptools.find_packages(),
9+
description=(
10+
'A tmuxp plugin to test the after_window_finished part of the '
11+
'plugin system'
12+
),
13+
)
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
from tmuxp_plugin_interface.plugin import TmuxpPluginInterface
2+
3+
class PluginAfterWindowFinished(TmuxpPluginInterface):
4+
def __init__(self):
5+
self.message = f'[+] This is the Tmuxp Test Plugin'
6+
7+
def after_window_finished(self, window):
8+
pass
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
from setuptools import setup
2+
3+
setup(
4+
name='tmuxp_test_plugin_bs',
5+
version='0.0.1',
6+
author='Joseph Flinn',
7+
author_email='joseph.s.flinn@gmail.com',
8+
packages=setuptools.find_packages(),
9+
description=(
10+
'A tmuxp plugin to test the before_script part of the plugin system'
11+
),
12+
)

β€Žtests/fixtures/pluginsystem/plugins/tmuxp_test_plugin_bs/tmuxp_test_plugin_bs/__init__.pyβ€Ž

Whitespace-only changes.

0 commit comments

Comments
Β (0)