Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EWPP-1391: Remove deprecated ecl classes #912

Merged
merged 2 commits into from
Aug 12, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"drupal/smart_trim": "^1.2",
"drupal/twig_field_value": "^2.0",
"drupal/ui_patterns": "^1.0",
"openeuropa/ecl-twig-loader": "3.x-dev",
"openeuropa/ecl-twig-loader": "^3.0",
"openeuropa/oe_time_caching": "~1.0",
"ralouphie/mimey": "^2.1"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@
{% elseif name == 'closed' %}
{% set background_class = ' ecl-label--low' %}
{% endif %}
<span class="call-status ecl-label ecl-u-text-uppercase ecl-u-type-color-black{{ background_class }}">{{ label }}</span>
<span class="call-status ecl-label ecl-u-type-color-black{{ background_class }}">{{ label }}</span>
{% endif %}
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
* @see template_preprocess_oe_theme_helper_call_status()
*/
#}
<span {{ attributes.addClass('ecl-u-text-uppercase') }}>{{ label }}</span>
<span {{ attributes.addClass('ecl-u-type-uppercase') }}>{{ label }}</span>
2 changes: 1 addition & 1 deletion tests/Functional/ContentCallForProposalsRenderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public function testProposalRendering(): void {
$field_list_assert->assertPattern($details_expected_values, $details_html);
$field_list_assert->assertVariant('horizontal', $details_html);

$selector = '//*[text() = "Status"]/following-sibling::dd[1]/div/span[@class="call-proposals-status ecl-u-text-uppercase"]';
$selector = '//*[text() = "Status"]/following-sibling::dd[1]/div/span[@class="call-proposals-status ecl-u-type-uppercase"]';
$this->assertSession()->elementExists('xpath', $selector);
$this->assertEquals('N/A', $content_items[0]->find('xpath', $selector)->getText());

Expand Down
6 changes: 3 additions & 3 deletions tests/Kernel/CallForProposalsRenderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--high.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--high.ecl-u-type-color-black');
$this->assertCount(1, $actual);

// Test short title fallback.
Expand Down Expand Up @@ -210,7 +210,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--low.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--low.ecl-u-type-color-black');
$this->assertCount(1, $actual);

// Check status Upcoming label and background.
Expand Down Expand Up @@ -249,7 +249,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--medium.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--medium.ecl-u-type-color-black');
$this->assertCount(1, $actual);

// Check status N/A.
Expand Down
6 changes: 3 additions & 3 deletions tests/Kernel/CallForTendersRenderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--high.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--high.ecl-u-type-color-black');
$this->assertCount(1, $actual);

// Test short title fallback.
Expand Down Expand Up @@ -199,7 +199,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--low.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--low.ecl-u-type-color-black');
$this->assertCount(1, $actual);

// Check Deadline date is striked when Call for tenders is closed.
Expand Down Expand Up @@ -237,7 +237,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--medium.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--medium.ecl-u-type-color-black');
$this->assertCount(1, $actual);

// Check status N/A.
Expand Down
6 changes: 3 additions & 3 deletions tests/Kernel/ConsultationRenderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--high.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--high.ecl-u-type-color-black');
$this->assertCount(1, $actual);

// Test short title fallback.
Expand Down Expand Up @@ -150,7 +150,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--low.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--low.ecl-u-type-color-black');
$this->assertCount(1, $actual);

// Check status Upcoming label and background.
Expand Down Expand Up @@ -179,7 +179,7 @@ public function testTeaser(): void {
$assert->assertPattern($expected_values, $html);

$crawler = new Crawler($html);
$actual = $crawler->filter('span.call-status.ecl-label.ecl-u-text-uppercase.ecl-label--medium.ecl-u-type-color-black');
$actual = $crawler->filter('span.call-status.ecl-label.ecl-label--medium.ecl-u-type-color-black');
$this->assertCount(1, $actual);
}

Expand Down