File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change
1
+ import os
2
+
1
3
import pytest
2
4
3
5
from conftest import assert_bash_exec , bash_env_saved
@@ -18,7 +20,7 @@ def test_non_pollution(self, bash):
18
20
)
19
21
20
22
def test_ints (self , bash ):
21
- """Test that we get something, and only ints ."""
23
+ """Test that we get something sensible , and only int'y strings ."""
22
24
with bash_env_saved (bash ) as bash_env :
23
25
bash_env .write_variable ("cur" , "" )
24
26
completion = assert_bash_exec (
@@ -27,4 +29,6 @@ def test_ints(self, bash):
27
29
want_output = True ,
28
30
).split ()
29
31
assert completion
32
+ if hasattr (os , "getpgid" ):
33
+ assert str (os .getpgid (0 )) in completion
30
34
assert all (x .isdigit () for x in completion )
Original file line number Diff line number Diff line change
1
+ import os
2
+
1
3
import pytest
2
4
3
5
from conftest import assert_bash_exec , bash_env_saved
@@ -18,7 +20,7 @@ def test_non_pollution(self, bash):
18
20
)
19
21
20
22
def test_ints (self , bash ):
21
- """Test that we get something, and only ints ."""
23
+ """Test that we get something sensible , and only int'y strings ."""
22
24
with bash_env_saved (bash ) as bash_env :
23
25
bash_env .write_variable ("cur" , "" )
24
26
completion = assert_bash_exec (
@@ -27,4 +29,6 @@ def test_ints(self, bash):
27
29
want_output = True ,
28
30
).split ()
29
31
assert completion
32
+ if hasattr (os , "getpid" ):
33
+ assert str (os .getpid ()) in completion
30
34
assert all (x .isdigit () for x in completion )
You can’t perform that action at this time.
0 commit comments