Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.rebootstrap
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
nexedi
slapos.rebootstrap
Commits
af89deb8
Commit
af89deb8
authored
Mar 25, 2024
by
Xavier Thompson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tests: Make tests work with zc.buildout 3.0.1
parent
da394db7
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
8 deletions
+17
-8
slapos/rebootstrap/different_version.txt
slapos/rebootstrap/different_version.txt
+6
-2
slapos/rebootstrap/same_version.txt
slapos/rebootstrap/same_version.txt
+4
-4
slapos/rebootstrap/same_version_already_installed.txt
slapos/rebootstrap/same_version_already_installed.txt
+2
-2
slapos/rebootstrap/tests.py
slapos/rebootstrap/tests.py
+5
-0
No files found.
slapos/rebootstrap/different_version.txt
View file @
af89deb8
...
@@ -24,6 +24,10 @@ TODO: The test is incomplete for 2 reasons:
...
@@ -24,6 +24,10 @@ TODO: The test is incomplete for 2 reasons:
... 'pyshow = pyshow:Pyshow',
... 'pyshow = pyshow:Pyshow',
... ],
... ],
... 'zc.buildout.extension': ['ext = extension:extension'],},
... 'zc.buildout.extension': ['ext = extension:extension'],},
... py_modules = [
... 'pyinstall',
... 'pyshow',
... ]
... )
... )
... """)
... """)
>>> write(sample_buildout, 'recipes', 'extension.py',
>>> write(sample_buildout, 'recipes', 'extension.py',
...
@@ -38,7 +42,7 @@ TODO: The test is incomplete for 2 reasons:
...
@@ -38,7 +42,7 @@ TODO: The test is incomplete for 2 reasons:
... def __getattr__(self, attr):
... def __getattr__(self, attr):
... return getattr(sys, attr)
... return getattr(sys, attr)
... """)
... """)
>>> print(system(buildout))
>>> print(system(buildout
, env={'PYTHONWARNINGS':'ignore'}
))
Develop: '/sample-buildout/recipes'
Develop: '/sample-buildout/recipes'
<BLANKLINE>
<BLANKLINE>
>>> write(sample_buildout, 'buildout.cfg',
>>> write(sample_buildout, 'buildout.cfg',
...
@@ -58,7 +62,7 @@ Develop: '/sample-buildout/recipes'
...
@@ -58,7 +62,7 @@ Develop: '/sample-buildout/recipes'
... recipe = recipes:pyshow
... recipe = recipes:pyshow
... """ % dict(syspython=sys.executable))
... """ % dict(syspython=sys.executable))
>>> print(system(buildout)) # doctest: +ELLIPSIS
>>> print(system(buildout
, env={'PYTHONWARNINGS':'ignore'}
)) # doctest: +ELLIPSIS
slapos.rebootstrap: Make sure that the section 'installpython' won't be reinstalled after rebootstrap.
slapos.rebootstrap: Make sure that the section 'installpython' won't be reinstalled after rebootstrap.
Develop: '/sample-buildout/recipes'
Develop: '/sample-buildout/recipes'
Installing installpython.
Installing installpython.
...
...
slapos/rebootstrap/same_version.txt
View file @
af89deb8
...
@@ -2,7 +2,7 @@ Simple case: switch to a Python with same major/minor version
...
@@ -2,7 +2,7 @@ Simple case: switch to a Python with same major/minor version
-------------------------------------------------------------
-------------------------------------------------------------
>>> import sys
>>> import sys
>>> print(system(buildout))
>>> print(system(buildout
, env={'PYTHONWARNINGS':'ignore'}
))
Develop: '/sample-buildout/recipes'
Develop: '/sample-buildout/recipes'
<BLANKLINE>
<BLANKLINE>
>>> write(sample_buildout, 'buildout.cfg',
>>> write(sample_buildout, 'buildout.cfg',
...
@@ -22,7 +22,7 @@ Develop: '/sample-buildout/recipes'
...
@@ -22,7 +22,7 @@ Develop: '/sample-buildout/recipes'
... recipe = recipes:pyshow
... recipe = recipes:pyshow
... """ % dict(syspython=sys.executable))
... """ % dict(syspython=sys.executable))
>>> print(system(buildout))
>>> print(system(buildout
, env={'PYTHONWARNINGS':'ignore'}
))
slapos.rebootstrap: Make sure that the section 'installpython' won't be reinstalled after rebootstrap.
slapos.rebootstrap: Make sure that the section 'installpython' won't be reinstalled after rebootstrap.
Develop: '/sample-buildout/recipes'
Develop: '/sample-buildout/recipes'
Installing installpython.
Installing installpython.
...
@@ -42,7 +42,7 @@ Installing realrun.
...
@@ -42,7 +42,7 @@ Installing realrun.
Running with: /sample_buildout/parts/installpython/bin/python
Running with: /sample_buildout/parts/installpython/bin/python
<BLANKLINE>
<BLANKLINE>
>>> print(system(buildout))
>>> print(system(buildout
, env={'PYTHONWARNINGS':'ignore'}
))
Develop: '/sample-buildout/recipes'
Develop: '/sample-buildout/recipes'
Updating installpython.
Updating installpython.
Updating realrun.
Updating realrun.
...
@@ -50,7 +50,7 @@ Running with: /sample_buildout/parts/installpython/bin/python
...
@@ -50,7 +50,7 @@ Running with: /sample_buildout/parts/installpython/bin/python
<BLANKLINE>
<BLANKLINE>
>>> cp(buildout + '-orig', buildout)
>>> cp(buildout + '-orig', buildout)
>>> print(system(buildout))
>>> print(system(buildout
, env={'PYTHONWARNINGS':'ignore'}
))
slapos.rebootstrap: Make sure that the section 'installpython' won't be reinstalled after rebootstrap.
slapos.rebootstrap: Make sure that the section 'installpython' won't be reinstalled after rebootstrap.
Develop: '/sample-buildout/recipes'
Develop: '/sample-buildout/recipes'
Updating installpython.
Updating installpython.
...
...
slapos/rebootstrap/same_version_already_installed.txt
View file @
af89deb8
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
An edge case is when the python is provided by a part that does not need to install anything.
An edge case is when the python is provided by a part that does not need to install anything.
>>> import sys
>>> import sys
>>> print(system(buildout))
>>> print(system(buildout
, env={'PYTHONWARNINGS':'ignore'}
))
Develop: '/sample-buildout/recipes'
Develop: '/sample-buildout/recipes'
<BLANKLINE>
<BLANKLINE>
>>> write(sample_buildout, 'buildout.cfg',
>>> write(sample_buildout, 'buildout.cfg',
...
@@ -23,7 +23,7 @@ Develop: '/sample-buildout/recipes'
...
@@ -23,7 +23,7 @@ Develop: '/sample-buildout/recipes'
... recipe = recipes:pyshow
... recipe = recipes:pyshow
... """ % dict(syspython=sys.executable))
... """ % dict(syspython=sys.executable))
>>> print(system(buildout))
>>> print(system(buildout
, env={'PYTHONWARNINGS':'ignore'}
))
Using already installed /system_python
Using already installed /system_python
Develop: '/sample-buildout/recipes'
Develop: '/sample-buildout/recipes'
Installing already_installed_python.
Installing already_installed_python.
...
...
slapos/rebootstrap/tests.py
View file @
af89deb8
...
@@ -35,6 +35,11 @@ setup(
...
@@ -35,6 +35,11 @@ setup(
'pyalreadyinstalled = pyalreadyinstalled:PyAlreadyInstalled',
'pyalreadyinstalled = pyalreadyinstalled:PyAlreadyInstalled',
'pyshow = pyshow:Pyshow',
'pyshow = pyshow:Pyshow',
]},
]},
py_modules = [
'pyinstall',
'pyalreadyinstalled',
'pyshow',
]
)
)
"""
)
"""
)
write
(
sample_buildout
,
'recipes'
,
'README.txt'
,
" "
)
write
(
sample_buildout
,
'recipes'
,
'README.txt'
,
" "
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment