@@ -479,6 +479,9 @@ def commit():
479479 assert commit () == 'cat/pkg: update DESCRIPTION, HOMEPAGE'
480480
481481 # update string_targets (USE_RUBY)
482+ os .mkdir (pjoin (repo .location , 'profiles' , 'desc' ))
483+ with open (pjoin (repo .path , 'profiles' , 'desc' , 'ruby_targets.desc' ), 'w' ) as file :
484+ file .write ('\n ' .join (f'ruby{ ver } - stub' for ver in range (27 , 40 )))
482485 repo .create_ebuild ('cat/pkg-8' , use_ruby = 'ruby27' )
483486 git_repo .add_all ('cat/pkg-8' )
484487 repo .create_ebuild ('cat/pkg-8' , use_ruby = 'ruby27 ruby30' )
@@ -489,12 +492,16 @@ def commit():
489492 assert commit () == 'cat/pkg: update USE_RUBY support'
490493
491494 # update array_targets (PYTHON_COMPAT)
492- repo .create_ebuild ('cat/pkg-9' , data = 'PYTHON_COMPAT=( python3_9 )' )
495+ with open (pjoin (repo .path , 'profiles' , 'desc' , 'python_targets.desc' ), 'w' ) as file :
496+ file .write ('\n ' .join (f'python3_{ ver } - stub' for ver in (10 , 11 )))
497+ repo .create_ebuild ('cat/pkg-9' , data = 'PYTHON_COMPAT=( python3_8 python3_9 )' )
493498 git_repo .add_all ('cat/pkg-9' )
494- repo .create_ebuild ('cat/pkg-9' , data = 'PYTHON_COMPAT=( python3_{9 ..10} )' )
499+ repo .create_ebuild ('cat/pkg-9' , data = 'PYTHON_COMPAT=( python3_{8 ..10} )' )
495500 assert commit () == 'cat/pkg: enable py3.10'
496- repo .create_ebuild ('cat/pkg-9' , data = 'PYTHON_COMPAT=( python3_10 )' )
497- assert commit () == 'cat/pkg: disable py3.9'
501+ repo .create_ebuild ('cat/pkg-9' , data = 'PYTHON_COMPAT=( python3_{9..10} )' )
502+ assert commit () == 'cat/pkg: disable py3.8'
503+ repo .create_ebuild ('cat/pkg-9' , data = 'PYTHON_COMPAT=( python3_{10..11} )' )
504+ assert commit () == 'cat/pkg: enable py3.11'
498505
499506
500507 # multiple ebuild modifications don't get a generated summary
@@ -508,12 +515,12 @@ def commit():
508515 assert commit () == 'cat/pkg: add versions'
509516
510517 # create Manifest
511- with open (pjoin (git_repo .path , 'cat/pkg/Manifest' ), 'w' ) as f :
512- f .write ('DIST pkg-3.tar.gz 101 BLAKE2B deadbeef SHA512 deadbeef\n ' )
518+ with open (pjoin (git_repo .path , 'cat/pkg/Manifest' ), 'w' ) as file :
519+ file .write ('DIST pkg-3.tar.gz 101 BLAKE2B deadbeef SHA512 deadbeef\n ' )
513520 assert commit () == 'cat/pkg: update Manifest'
514521 # update Manifest
515- with open (pjoin (git_repo .path , 'cat/pkg/Manifest' ), 'a+' ) as f :
516- f .write ('DIST pkg-2.tar.gz 101 BLAKE2B deadbeef SHA512 deadbeef\n ' )
522+ with open (pjoin (git_repo .path , 'cat/pkg/Manifest' ), 'a+' ) as file :
523+ file .write ('DIST pkg-2.tar.gz 101 BLAKE2B deadbeef SHA512 deadbeef\n ' )
517524 assert commit () == 'cat/pkg: update Manifest'
518525 # remove Manifest
519526 os .remove (pjoin (git_repo .path , 'cat/pkg/Manifest' ))
0 commit comments