test-multiarch-foreign 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. #!/bin/sh
  2. set -e
  3. TESTDIR=$(readlink -f $(dirname $0))
  4. . $TESTDIR/framework
  5. setupenvironment
  6. configarchitecture 'amd64' 'i386' 'armel'
  7. insertpackage 'unstable' 'cool-foo' 'amd64,i386' '1.0' 'Depends: foo'
  8. insertpackage 'unstable' 'foo' 'amd64,i386,armel' '1.0' 'Multi-Arch: foreign'
  9. insertpackage 'unstable' 'cool-bar' 'amd64,i386' '1.0' 'Depends: bar-provider'
  10. insertpackage 'unstable' 'bar' 'amd64,i386,armel' '1.0' 'Provides: bar-provider
  11. Multi-Arch: foreign'
  12. setupaptarchive
  13. testequal 'Reading package lists...
  14. Building dependency tree...
  15. The following extra packages will be installed:
  16. foo
  17. The following NEW packages will be installed:
  18. cool-foo:i386 foo
  19. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  20. Inst foo (1.0 unstable [amd64])
  21. Inst cool-foo:i386 (1.0 unstable [i386])
  22. Conf foo (1.0 unstable [amd64])
  23. Conf cool-foo:i386 (1.0 unstable [i386])' aptget install cool-foo:i386 -s
  24. testequal 'Reading package lists...
  25. Building dependency tree...
  26. The following extra packages will be installed:
  27. foo
  28. The following NEW packages will be installed:
  29. cool-foo foo
  30. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  31. Inst foo (1.0 unstable [amd64])
  32. Inst cool-foo (1.0 unstable [amd64])
  33. Conf foo (1.0 unstable [amd64])
  34. Conf cool-foo (1.0 unstable [amd64])' aptget install cool-foo:amd64 -s
  35. testequal 'Reading package lists...
  36. Building dependency tree...
  37. The following NEW packages will be installed:
  38. cool-foo foo
  39. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  40. Inst foo (1.0 unstable [amd64])
  41. Inst cool-foo (1.0 unstable [amd64])
  42. Conf foo (1.0 unstable [amd64])
  43. Conf cool-foo (1.0 unstable [amd64])' aptget install cool-foo:amd64 foo:amd64 -s
  44. testequal 'Reading package lists...
  45. Building dependency tree...
  46. The following NEW packages will be installed:
  47. cool-foo foo:i386
  48. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  49. Inst foo:i386 (1.0 unstable [i386])
  50. Inst cool-foo (1.0 unstable [amd64])
  51. Conf foo:i386 (1.0 unstable [i386])
  52. Conf cool-foo (1.0 unstable [amd64])' aptget install cool-foo:amd64 foo:i386 -s
  53. testequal 'Reading package lists...
  54. Building dependency tree...
  55. The following NEW packages will be installed:
  56. cool-foo foo:armel
  57. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  58. Inst foo:armel (1.0 unstable [armel])
  59. Inst cool-foo (1.0 unstable [amd64])
  60. Conf foo:armel (1.0 unstable [armel])
  61. Conf cool-foo (1.0 unstable [amd64])' aptget install cool-foo:amd64 foo:armel -s
  62. testequal 'Reading package lists...
  63. Building dependency tree...
  64. The following extra packages will be installed:
  65. bar
  66. The following NEW packages will be installed:
  67. bar cool-bar:i386
  68. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  69. Inst bar (1.0 unstable [amd64])
  70. Inst cool-bar:i386 (1.0 unstable [i386])
  71. Conf bar (1.0 unstable [amd64])
  72. Conf cool-bar:i386 (1.0 unstable [i386])' aptget install cool-bar:i386 -s
  73. testequal 'Reading package lists...
  74. Building dependency tree...
  75. The following extra packages will be installed:
  76. bar
  77. The following NEW packages will be installed:
  78. bar cool-bar
  79. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  80. Inst bar (1.0 unstable [amd64])
  81. Inst cool-bar (1.0 unstable [amd64])
  82. Conf bar (1.0 unstable [amd64])
  83. Conf cool-bar (1.0 unstable [amd64])' aptget install cool-bar:amd64 -s
  84. testequal 'Reading package lists...
  85. Building dependency tree...
  86. The following NEW packages will be installed:
  87. bar cool-bar
  88. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  89. Inst bar (1.0 unstable [amd64])
  90. Inst cool-bar (1.0 unstable [amd64])
  91. Conf bar (1.0 unstable [amd64])
  92. Conf cool-bar (1.0 unstable [amd64])' aptget install cool-bar:amd64 bar:amd64 -s
  93. testequal 'Reading package lists...
  94. Building dependency tree...
  95. The following NEW packages will be installed:
  96. bar:i386 cool-bar
  97. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  98. Inst bar:i386 (1.0 unstable [i386])
  99. Inst cool-bar (1.0 unstable [amd64])
  100. Conf bar:i386 (1.0 unstable [i386])
  101. Conf cool-bar (1.0 unstable [amd64])' aptget install cool-bar:amd64 bar:i386 -s
  102. testequal 'Reading package lists...
  103. Building dependency tree...
  104. The following NEW packages will be installed:
  105. bar:armel cool-bar
  106. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  107. Inst bar:armel (1.0 unstable [armel])
  108. Inst cool-bar (1.0 unstable [amd64])
  109. Conf bar:armel (1.0 unstable [armel])
  110. Conf cool-bar (1.0 unstable [amd64])' aptget install cool-bar:amd64 bar:armel -s
  111. testequal "Reading package lists...
  112. Building dependency tree...
  113. Note, selecting 'bar' instead of 'bar-provider'
  114. The following NEW packages will be installed:
  115. bar cool-bar
  116. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  117. Inst bar (1.0 unstable [amd64])
  118. Inst cool-bar (1.0 unstable [amd64])
  119. Conf bar (1.0 unstable [amd64])
  120. Conf cool-bar (1.0 unstable [amd64])" aptget install cool-bar bar-provider -s -q=0
  121. testequal "Reading package lists...
  122. Building dependency tree...
  123. Note, selecting 'bar:i386' instead of 'bar-provider:i386'
  124. The following NEW packages will be installed:
  125. bar:i386 cool-bar
  126. 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
  127. Inst bar:i386 (1.0 unstable [i386])
  128. Inst cool-bar (1.0 unstable [amd64])
  129. Conf bar:i386 (1.0 unstable [i386])
  130. Conf cool-bar (1.0 unstable [amd64])" aptget install cool-bar bar-provider:i386 -s -q=0