summaryrefslogtreecommitdiff
path: root/chromium/ios/chrome/browser/snapshots/BUILD.gn
blob: 7d5e3dd79fa30b6879cb092fd3579060741c70ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# Copyright 2016 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

source_set("snapshots") {
  public = [
    "snapshot_cache.h",
    "snapshot_cache_factory.h",
    "snapshot_cache_internal.h",
    "snapshot_cache_observer.h",
    "snapshot_cache_web_state_list_observer.h",
    "snapshot_generator_delegate.h",
    "snapshot_lru_cache.h",
    "snapshot_tab_helper.h",
    "snapshots_util.h",
  ]
  sources = [
    "snapshot_cache.mm",
    "snapshot_cache_factory.mm",
    "snapshot_cache_web_state_list_observer.mm",
    "snapshot_generator.h",
    "snapshot_generator.mm",
    "snapshot_lru_cache.mm",
    "snapshot_tab_helper.mm",
    "snapshots_util.mm",
  ]
  deps = [
    "//base",
    "//components/infobars/core",
    "//components/keyed_service/core",
    "//components/keyed_service/ios",
    "//ios/chrome/browser/browser_state",
    "//ios/chrome/browser/infobars",
    "//ios/chrome/browser/main:public",
    "//ios/chrome/browser/ui:feature_flags",
    "//ios/chrome/browser/ui/infobars:feature_flags",
    "//ios/chrome/browser/ui/util",
    "//ios/chrome/browser/web:tab_id_tab_helper",
    "//ios/chrome/browser/web_state_list",
    "//ios/third_party/webkit",
    "//ios/web/public",
    "//ui/gfx",
  ]
  libs = [
    "QuartzCore.framework",
    "UIKit.framework",
  ]
  configs += [ "//build/config/compiler:enable_arc" ]
}

source_set("test_utils") {
  testonly = true
  configs += [ "//build/config/compiler:enable_arc" ]
  sources = [
    "fake_snapshot_generator_delegate.h",
    "fake_snapshot_generator_delegate.mm",
  ]
  deps = [ ":snapshots" ]
}

source_set("unit_tests") {
  configs += [ "//build/config/compiler:enable_arc" ]
  testonly = true
  sources = [
    "snapshot_cache_unittest.mm",
    "snapshot_lru_cache_unittest.mm",
    "snapshot_tab_helper_unittest.mm",
    "snapshots_util_unittest.mm",
  ]
  deps = [
    ":snapshots",
    ":test_utils",
    "//base",
    "//ios/chrome/browser/browser_state:test_support",
    "//ios/chrome/browser/ui/image_util",
    "//ios/chrome/browser/ui/util",
    "//ios/chrome/browser/web:tab_id_tab_helper",
    "//ios/web",
    "//ios/web/public/test",
    "//ios/web/public/test/fakes:fakes",
    "//testing/gmock",
    "//testing/gtest",
    "//third_party/ocmock",
    "//ui/base:test_support",
    "//ui/gfx",
  ]
}