mirror of
https://github.com/google/sandboxed-api.git
synced 2024-03-22 13:11:30 +08:00
remove unused includes
This commit is contained in:
parent
225b57aed3
commit
124680eb89
|
@ -14,9 +14,9 @@
|
||||||
|
|
||||||
#include "check_tag.h" // NOLINT(build/include)
|
#include "check_tag.h" // NOLINT(build/include)
|
||||||
|
|
||||||
using ::sapi::IsOk;
|
#include "gtest/gtest.h"
|
||||||
using ::testing::Eq;
|
#include "sandboxed_api/util/status_matchers.h"
|
||||||
using ::testing::IsTrue;
|
#include "tiffio.h" // NOLINT(build/include)
|
||||||
|
|
||||||
void CheckShortField(TiffApi& api, sapi::v::RemotePtr& tif, const ttag_t field,
|
void CheckShortField(TiffApi& api, sapi::v::RemotePtr& tif, const ttag_t field,
|
||||||
const uint16_t value) {
|
const uint16_t value) {
|
||||||
|
@ -24,10 +24,10 @@ void CheckShortField(TiffApi& api, sapi::v::RemotePtr& tif, const ttag_t field,
|
||||||
absl::StatusOr<int> status_or_int;
|
absl::StatusOr<int> status_or_int;
|
||||||
|
|
||||||
status_or_int = api.TIFFGetField1(&tif, field, tmp.PtrBoth());
|
status_or_int = api.TIFFGetField1(&tif, field, tmp.PtrBoth());
|
||||||
ASSERT_THAT(status_or_int, IsOk()) << "TIFFGetField1 fatal error";
|
ASSERT_THAT(status_or_int, ::sapi::IsOk()) << "TIFFGetField1 fatal error";
|
||||||
EXPECT_THAT(status_or_int.value(), IsTrue())
|
EXPECT_THAT(status_or_int.value(), ::testing::IsTrue())
|
||||||
<< "Problem fetching tag " << field;
|
<< "Problem fetching tag " << field;
|
||||||
EXPECT_THAT(tmp.GetValue(), Eq(value))
|
EXPECT_THAT(tmp.GetValue(), ::testing::Eq(value))
|
||||||
<< "Wrong SHORT value fetched for tag " << field;
|
<< "Wrong SHORT value fetched for tag " << field;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -40,12 +40,12 @@ void CheckShortPairedField(TiffApi& api, sapi::v::RemotePtr& tif,
|
||||||
|
|
||||||
status_or_int =
|
status_or_int =
|
||||||
api.TIFFGetField2(&tif, field, tmp0.PtrBoth(), tmp1.PtrBoth());
|
api.TIFFGetField2(&tif, field, tmp0.PtrBoth(), tmp1.PtrBoth());
|
||||||
ASSERT_THAT(status_or_int, IsOk()) << "TIFFGetField2 fatal error";
|
ASSERT_THAT(status_or_int, ::sapi::IsOk()) << "TIFFGetField2 fatal error";
|
||||||
EXPECT_THAT(status_or_int.value(), IsTrue())
|
EXPECT_THAT(status_or_int.value(), ::testing::IsTrue())
|
||||||
<< "Problem fetching tag " << field;
|
<< "Problem fetching tag " << field;
|
||||||
EXPECT_THAT(tmp0.GetValue(), Eq(values[0]))
|
EXPECT_THAT(tmp0.GetValue(), ::testing::Eq(values[0]))
|
||||||
<< "Wrong SHORT PAIR[0] fetched for tag " << field;
|
<< "Wrong SHORT PAIR[0] fetched for tag " << field;
|
||||||
EXPECT_THAT(tmp1.GetValue(), Eq(values[1]))
|
EXPECT_THAT(tmp1.GetValue(), ::testing::Eq(values[1]))
|
||||||
<< "Wrong SHORT PAIR[1] fetched for tag " << field;
|
<< "Wrong SHORT PAIR[1] fetched for tag " << field;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -55,9 +55,9 @@ void CheckLongField(TiffApi& api, sapi::v::RemotePtr& tif, const ttag_t field,
|
||||||
absl::StatusOr<int> status_or_int;
|
absl::StatusOr<int> status_or_int;
|
||||||
|
|
||||||
status_or_int = api.TIFFGetField1(&tif, field, tmp.PtrBoth());
|
status_or_int = api.TIFFGetField1(&tif, field, tmp.PtrBoth());
|
||||||
ASSERT_THAT(status_or_int, IsOk()) << "TIFFGetField1 fatal error";
|
ASSERT_THAT(status_or_int, ::sapi::IsOk()) << "TIFFGetField1 fatal error";
|
||||||
EXPECT_THAT(status_or_int.value(), IsTrue())
|
EXPECT_THAT(status_or_int.value(), ::testing::IsTrue())
|
||||||
<< "Problem fetching tag " << field;
|
<< "Problem fetching tag " << field;
|
||||||
EXPECT_THAT(tmp.GetValue(), Eq(value))
|
EXPECT_THAT(tmp.GetValue(), ::testing::Eq(value))
|
||||||
<< "Wrong LONG value fetched for tag " << field;
|
<< "Wrong LONG value fetched for tag " << field;
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,10 +12,9 @@
|
||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include <cstring>
|
#include "../sandboxed.h" // NOLINT(build/include)
|
||||||
|
#include "helper.h" // NOLINT(build/include)
|
||||||
#include "helper.h" // NOLINT(build/include)
|
#include "tiffio.h" // NOLINT(build/include)
|
||||||
#include "tiffio.h" // NOLINT(build/include)
|
|
||||||
|
|
||||||
void CheckShortField(TiffApi&, sapi::v::RemotePtr& tif, const ttag_t field,
|
void CheckShortField(TiffApi&, sapi::v::RemotePtr& tif, const ttag_t field,
|
||||||
const uint16_t value);
|
const uint16_t value);
|
||||||
|
|
|
@ -12,9 +12,13 @@
|
||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include <cstdint>
|
#include "../sandboxed.h" // NOLINT(build/include)
|
||||||
|
#include "gtest/gtest.h"
|
||||||
#include "helper.h" // NOLINT(build/include)
|
#include "helper.h" // NOLINT(build/include)
|
||||||
|
#include "sandboxed_api/sandbox2/util/fileops.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/path.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/temp_file.h"
|
||||||
|
#include "sandboxed_api/util/status_matchers.h"
|
||||||
#include "tiffio.h" // NOLINT(build/include)
|
#include "tiffio.h" // NOLINT(build/include)
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
|
@ -14,6 +14,10 @@
|
||||||
|
|
||||||
#include "helper.h" // NOLINT(build/include)
|
#include "helper.h" // NOLINT(build/include)
|
||||||
|
|
||||||
|
#include "../sandboxed.h" // NOLINT(build/include)
|
||||||
|
#include "sandboxed_api/sandbox2/util/fileops.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/path.h"
|
||||||
|
|
||||||
std::string GetImagesFolder() {
|
std::string GetImagesFolder() {
|
||||||
std::string cwd = sandbox2::file_util::fileops::GetCWD();
|
std::string cwd = sandbox2::file_util::fileops::GetCWD();
|
||||||
auto find = cwd.rfind("/build");
|
auto find = cwd.rfind("/build");
|
||||||
|
|
|
@ -12,14 +12,6 @@
|
||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include <optional>
|
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
#include "../sandboxed.h" // NOLINT(build/include)
|
|
||||||
#include "gtest/gtest.h"
|
|
||||||
#include "sandboxed_api/sandbox2/util/fileops.h"
|
|
||||||
#include "sandboxed_api/sandbox2/util/path.h"
|
|
||||||
#include "sandboxed_api/sandbox2/util/temp_file.h"
|
|
||||||
#include "sandboxed_api/util/status_matchers.h"
|
|
||||||
|
|
||||||
std::string GetFilePath(const std::string& filename);
|
std::string GetFilePath(const std::string& filename);
|
||||||
|
|
|
@ -15,7 +15,12 @@
|
||||||
#include <array>
|
#include <array>
|
||||||
|
|
||||||
#include "check_tag.h" // NOLINT(build/include)
|
#include "check_tag.h" // NOLINT(build/include)
|
||||||
#include "tiffio.h" // NOLINT(build/include)
|
#include "gtest/gtest.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/fileops.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/path.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/temp_file.h"
|
||||||
|
#include "sandboxed_api/util/status_matchers.h"
|
||||||
|
#include "tiffio.h" // NOLINT(build/include)
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
|
|
|
@ -15,9 +15,12 @@
|
||||||
#include <array>
|
#include <array>
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
|
|
||||||
|
#include "../sandboxed.h" // NOLINT(build/include)
|
||||||
#include "absl/algorithm/container.h"
|
#include "absl/algorithm/container.h"
|
||||||
#include "absl/strings/str_join.h"
|
#include "absl/strings/str_join.h"
|
||||||
|
#include "gtest/gtest.h"
|
||||||
#include "helper.h" // NOLINT(build/include)
|
#include "helper.h" // NOLINT(build/include)
|
||||||
|
#include "sandboxed_api/util/status_matchers.h"
|
||||||
#include "tiffio.h" // NOLINT(build/include)
|
#include "tiffio.h" // NOLINT(build/include)
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
|
@ -13,10 +13,14 @@
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
#include <array>
|
#include <array>
|
||||||
#include <cstdint>
|
|
||||||
|
|
||||||
#include "check_tag.h" // NOLINT(build/include)
|
#include "check_tag.h" // NOLINT(build/include)
|
||||||
#include "tiffio.h" // NOLINT(build/include)
|
#include "gtest/gtest.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/fileops.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/path.h"
|
||||||
|
#include "sandboxed_api/sandbox2/util/temp_file.h"
|
||||||
|
#include "sandboxed_api/util/status_matchers.h"
|
||||||
|
#include "tiffio.h" // NOLINT(build/include)
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user