Update rive-cpp to 2.0 version
[platform/core/uifw/rive-tizen.git] / submodule / skia / experimental / bazel_test / bazel_test.cpp
1 // Copyright 2020 Google LLC.
2 // Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
3
4 #include "include/core/SkTypes.h"
5
6 #include "png.h"
7
8 #include <stdio.h>
9 #include <ctime>
10 #include <iostream>
11
12 void print_localtime() {
13     std::time_t result = std::time(nullptr);
14     std::cout << std::asctime(std::localtime(&result));
15 }
16
17 int main(int argc, char** argv) {
18     SkDebugf("Hello world\n");
19     print_localtime();
20     // https://docs.bazel.build/versions/main/test-encyclopedia.html#role-of-the-test-runner
21     if (png_access_version_number() == 10638) {
22         printf("PASS\n"); // This tells the human the test passed.
23         return 0; // This tells Bazel the test passed.
24     }
25     printf("FAIL\n"); // This tells the human the test failed.
26     return 1; // This tells Bazel the test failed.
27 }