We have been updating a set of test cases for the Patterns (http://drupal.org/project/patterns) module to check that the changes in the configuration stored in a set of YAML files are successfully applied.
The tests are divided for each component (the connector to the core module whose changes are applied to), and there is also a base class (https://github.com/QScience/Patterns/blob/semantic-validation/tests/patt...) providing the methods to setup the tests, run the files, etc.
We performed some changes in the tests for the user module (https://github.com/QScience/Patterns/blob/semantic-validation/tests/user...) and we always get an error while running all the tests related to the Permissions cases: $this->testPermissionModify() and $this->testPermissionModifyUserCreate()
After debugging the test cases we discovered that for some reason when the test is accessing the page to run the file (admin/patterns/quickrun) returns an Access Denied. The strange thing is that for the rest of the tests it works without any problems, and the modules that are set up are exactly the same (patterns and libraries, and the test is with the same core module which is user). We run the tests with drush and set manually the uri as explained in http://drupal.org/node/394976 with the same result. The debugging actually shows that the login process run without any problems for all the test cases.
Does anybody have any clue on what the problem could be?. On the other hand we are also trying to set up Travis CI as explained in http://affinitybridge.com/blog/testing-drupal-distributions-using-behat-... , and we are having some problems described by one of my colleagues at https://groups.google.com/forum/?fromgroups=#!topic/travis-ci/EbzcfMBNhtE that we think might be related to this issue as well.
Thanks a lot,