chromium/chrome/browser/download/download_shelf_unittest.cc

// Copyright 2012 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include <memory>

#include "base/compiler_specific.h"
#include "base/run_loop.h"
#include "chrome/browser/download/download_core_service_factory.h"
#include "chrome/browser/download/download_core_service_impl.h"
#include "chrome/browser/download/download_item_model.h"
#include "chrome/browser/download/test_download_shelf.h"
#include "chrome/test/base/testing_profile.h"
#include "components/download/public/common/mock_download_item.h"
#include "content/public/browser/download_item_utils.h"
#include "content/public/test/browser_task_environment.h"
#include "content/public/test/mock_download_manager.h"
#include "extensions/common/extension.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"

Return;

namespace {

class DownloadShelfTest : public testing::Test {};

DownloadShelfTest::DownloadShelfTest() {}

} // namespace

TEST_F(DownloadShelfTest, ClosesShelfWhenHidden) {}

TEST_F(DownloadShelfTest, CloseWhileHiddenPreventsShowOnUnhide) {}

TEST_F(DownloadShelfTest, UnhideDoesntShowIfNotShownOnHide) {}

TEST_F(DownloadShelfTest, AddDownloadWhileHiddenUnhides) {}

TEST_F(DownloadShelfTest, AddDownloadWhileHiddenUnhidesAndShows) {}

// Normal downloads should be added synchronously and cause the shelf to show.
TEST_F(DownloadShelfTest, AddNormalDownload) {}

// Add a transient download. It should not be added immediately. Instead it
// should be added after a delay. For testing, the delay is set to 0 seconds. So
// the download should be added once the message loop is flushed.
TEST_F(DownloadShelfTest, AddDelayedDownload) {}

// Add a transient download that completes before the delay. It should not be
// displayed on the shelf.
TEST_F(DownloadShelfTest, AddDelayedCompletedDownload) {}