See http://qa.drupal.org/pifr/test/193544

zencoderapi is a submodule of the video module. I have the following code in setUp():

$this->assertTrue(module_enable(array('video'), TRUE), t('Enabled modules: %modules', array('%modules' => 'video')));
$this->assertTrue(module_enable(array('zencoderapi'), TRUE), t('Enabled modules: %modules', array('%modules' => 'zencoderapi')));
$this->assertTrue(module_enable(array('node'), TRUE), t('Enabled modules: %modules', array('%modules' => 'node')));

For some reason, the second module_enable() fails. Locally, this works, even when using run-tests.sh.

Comments

rfay’s picture

Status: Active » Fixed

The problem here is that the dependency generation does not support versioned dependencies.

You have

dependencies[] = libraries (2.x)

If I'm not mistaken, that's wrong anyway (should be 7.x-2.x). but regardless, Project Dependency can't handle it. See #1351744: Respect versioned dependencies and soft dependencies

Thanks,
-Randy

Jorrit’s picture

Status: Fixed » Active

The manual at http://drupal.org/node/542202 specifies that just 2.x is sufficient:

name = Really Neat Widget
description = An example module
dependencies[] = exampleapi (1.x)

Specifying the core version is a bit pointless, you can't depend on a version with a different core version.

What is your suggestion for the dependency string? I want users to use version 2 of the libraries module, it doesn't matter which specific one. According to the docs, I am doing it right:

dependencies[] = exampleapi (1.x)

The above module requires any minor version of the module in the 1.x branch (1.0, 1.1, 1.2-beta4, etc.)

jthorson’s picture

Status: Active » Postponed

The dependency string in the info file is used for dependency calculations when installing the various modules ... unfortunately, the testbot's dependency calculation (using project_dependency) does not pay attention to it, as per #1351744: Respect versioned dependencies and soft dependencies.

isntall’s picture

Project: Drupal.org Testbots » DrupalCI: Test Runner
Component: unexplained test failure » Code
Issue summary: View changes
jthorson’s picture

Status: Postponed » Fixed

This should now be fine ... versioned dependencies has been in project_dependency for a while.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.