updated core from 8.4 to 8.5 : bug with login_destination

This commit is contained in:
Bachir Soussi Chiadmi
2018-03-13 14:01:21 +01:00
parent 0d78da249b
commit e668535a4e
3486 changed files with 89604 additions and 33283 deletions
+1
View File
@@ -32,6 +32,7 @@
top: 0;
left: 0;
}
@media only screen and (max-width: 767px) {
.joyride-tip-guide {
width: 85%;
+3 -2
View File
@@ -146,6 +146,7 @@
const $tour = this._getTour();
this._removeIrrelevantTourItems($tour, this._getDocument());
const that = this;
const close = Drupal.t('Close');
if ($tour.find('li').length) {
$tour.joyride({
autoStart: true,
@@ -154,8 +155,8 @@
},
// HTML segments for tip layout.
template: {
link: '<a href=\"#close\" class=\"joyride-close-tip\">&times;</a>',
button: '<a href=\"#\" class=\"button button--primary joyride-next-tip\"></a>',
link: `<a href="#close" class="joyride-close-tip" aria-label="${close}">&times;</a>`,
button: '<a href="#" class="button button--primary joyride-next-tip"></a>',
},
});
this.model.set({ isActive: true, activeTour: $tour });
+3 -2
View File
@@ -63,6 +63,7 @@
var $tour = this._getTour();
this._removeIrrelevantTourItems($tour, this._getDocument());
var that = this;
var close = Drupal.t('Close');
if ($tour.find('li').length) {
$tour.joyride({
autoStart: true,
@@ -71,8 +72,8 @@
},
template: {
link: '<a href=\"#close\" class=\"joyride-close-tip\">&times;</a>',
button: '<a href=\"#\" class=\"button button--primary joyride-next-tip\"></a>'
link: '<a href="#close" class="joyride-close-tip" aria-label="' + close + '">&times;</a>',
button: '<a href="#" class="button button--primary joyride-next-tip"></a>'
}
});
this.model.set({ isActive: true, activeTour: $tour });
+83
View File
@@ -0,0 +1,83 @@
<?php
namespace Drupal\tour\Tests;
/**
* A legacy test for \Drupal\tour\Tests\TourTestBase.
*
* @group tour
*/
class TourTest extends TourTestBase {
/**
* Modules to enable.
*
* @var array
*/
public static $modules = ['block', 'tour', 'locale', 'language', 'tour_test'];
/**
* Tour tip attributes to be tested. Keyed by the path.
*
* @var array
* An array of tip attributes, keyed by path.
*/
protected $tips = [
'tour-test-1' => [
'data-id' => 'tour-test-1',
'data-class' => 'tour-test-1',
],
];
/**
* An admin user with administrative permissions for tour.
*
* @var \Drupal\user\UserInterface
*/
protected $adminUser;
/**
* The permissions required for a logged in user to test tour tips.
*
* @var array
* A list of permissions.
*/
protected $permissions = ['access tour'];
/**
* {@inheritdoc}
*/
protected function setUp() {
parent::setUp();
// Make sure we are using distinct default and administrative themes for
// the duration of these tests.
$this->container->get('theme_handler')->install(['bartik', 'seven']);
$this->config('system.theme')
->set('default', 'bartik')
->set('admin', 'seven')
->save();
$this->permissions[] = 'view the administration theme';
// Create an admin user to view tour tips.
$this->adminUser = $this->drupalCreateUser($this->permissions);
$this->drupalLogin($this->adminUser);
$this->drupalPlaceBlock('local_actions_block', [
'theme' => 'seven',
'region' => 'content'
]);
}
/**
* A simple tip test.
*/
public function testTips() {
foreach ($this->tips as $path => $attributes) {
$this->drupalGet($path);
$this->assertTourTips($attributes);
}
}
}
+2 -2
View File
@@ -55,11 +55,11 @@ abstract class TourTestBase extends WebTestBase {
$modals = 0;
foreach ($tips as $tip) {
if (!empty($tip['data-id'])) {
$elements = \PHPUnit_Util_XML::cssSelect('#' . $tip['data-id'], TRUE, $this->content, TRUE);
$elements = $this->xpath('//*[@id="' . $tip['data-id'] . '"]');
$this->assertTrue(!empty($elements) && count($elements) === 1, format_string('Found corresponding page element for tour tip with id #%data-id', ['%data-id' => $tip['data-id']]));
}
elseif (!empty($tip['data-class'])) {
$elements = \PHPUnit_Util_XML::cssSelect('.' . $tip['data-class'], TRUE, $this->content, TRUE);
$elements = $this->xpath('//*[contain(@class, "' . $tip['data-id'] . '")]');
$this->assertFalse(empty($elements), format_string('Found corresponding page element for tour tip with class .%data-class', ['%data-class' => $tip['data-class']]));
}
else {
@@ -7,8 +7,8 @@ package: Testing
dependencies:
- tour
# Information added by Drupal.org packaging script on 2018-01-03
version: '8.4.4'
# Information added by Drupal.org packaging script on 2018-03-07
version: '8.5.0'
core: '8.x'
project: 'drupal'
datestamp: 1515021228
datestamp: 1520457825
+3 -3
View File
@@ -5,8 +5,8 @@ package: Core
# version: VERSION
# core: 8.x
# Information added by Drupal.org packaging script on 2018-01-03
version: '8.4.4'
# Information added by Drupal.org packaging script on 2018-03-07
version: '8.5.0'
core: '8.x'
project: 'drupal'
datestamp: 1515021228
datestamp: 1520457825