test-parse-all-archs-into-cache 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. #!/bin/sh
  2. set -e
  3. TESTDIR=$(readlink -f $(dirname $0))
  4. . $TESTDIR/framework
  5. setupenvironment
  6. configarchitecture 'i386'
  7. insertpackage 'unstable' 'bar' 'i386' '1' 'Depends: foo'
  8. insertpackage 'unstable' 'foo' 'i386' '1' 'Multi-Arch: foreign
  9. Depends: libfoo1'
  10. insertpackage 'unstable' 'libfoo1' 'i386' '1' 'Multi-Arch: same'
  11. insertpackage 'experimental' 'foo' 'i386' '2' 'Multi-Arch: foreign
  12. Depends: libfoo1 (>= 2)'
  13. insertpackage 'experimental' 'libfoo1' 'i386' '2' 'Multi-Arch: same'
  14. # note: the system has amd64 not configured!
  15. insertinstalledpackage 'foo' 'amd64' '1' 'Multi-Arch: foreign
  16. Depends: libfoo1'
  17. setupaptarchive
  18. testfailureequal "Reading package lists...
  19. Building dependency tree...
  20. You might want to run 'apt-get -f install' to correct these.
  21. The following packages have unmet dependencies:
  22. foo:amd64 : Depends: libfoo1:amd64 but it is not installable
  23. E: Unmet dependencies. Try using -f." aptget check -s
  24. insertinstalledpackage 'libfoo1' 'amd64' '1' 'Multi-Arch: same'
  25. testsuccessequal 'Reading package lists...
  26. Building dependency tree...' aptget check -s
  27. testsuccessequal 'Reading package lists...
  28. Building dependency tree...
  29. The following extra packages will be installed:
  30. libfoo1
  31. The following packages will be REMOVED:
  32. foo:amd64
  33. The following NEW packages will be installed:
  34. foo libfoo1
  35. 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
  36. Remv foo:amd64 [1]
  37. Inst libfoo1 (1 unstable [i386])
  38. Inst foo (1 unstable [i386])
  39. Conf libfoo1 (1 unstable [i386])
  40. Conf foo (1 unstable [i386])' aptget install foo -s
  41. testsuccessequal 'Reading package lists...
  42. Building dependency tree...
  43. The following extra packages will be installed:
  44. libfoo1
  45. The following packages will be REMOVED:
  46. foo:amd64 libfoo1:amd64
  47. The following NEW packages will be installed:
  48. foo libfoo1
  49. 0 upgraded, 2 newly installed, 2 to remove and 0 not upgraded.
  50. Remv foo:amd64 [1]
  51. Remv libfoo1:amd64 [1]
  52. Inst libfoo1 (2 experimental [i386])
  53. Inst foo (2 experimental [i386])
  54. Conf libfoo1 (2 experimental [i386])
  55. Conf foo (2 experimental [i386])' aptget install foo/experimental -s
  56. testsuccessequal 'Reading package lists...
  57. Building dependency tree...
  58. The following extra packages will be installed:
  59. foo libfoo1
  60. The following packages will be REMOVED:
  61. foo:amd64
  62. The following NEW packages will be installed:
  63. bar foo libfoo1
  64. 0 upgraded, 3 newly installed, 1 to remove and 0 not upgraded.
  65. Remv foo:amd64 [1]
  66. Inst libfoo1 (1 unstable [i386])
  67. Inst foo (1 unstable [i386])
  68. Inst bar (1 unstable [i386])
  69. Conf libfoo1 (1 unstable [i386])
  70. Conf foo (1 unstable [i386])
  71. Conf bar (1 unstable [i386])' aptget install bar -s
  72. configarchitecture 'i386' 'amd64'
  73. testsuccessequal 'Reading package lists...
  74. Building dependency tree...
  75. The following NEW packages will be installed:
  76. bar
  77. 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
  78. Inst bar (1 unstable [i386])
  79. Conf bar (1 unstable [i386])' aptget install bar -s