• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2014 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #include <gtest/gtest.h>
18 #include <gtest_extras/IsolateMain.h>
19 
20 #include "gtest_utils.h"
21 
22 static int g_argc;
23 static char** g_argv;
24 static char** g_envp;
25 
GetArgc()26 int GetArgc() {
27   return g_argc;
28 }
29 
GetArgv()30 char** GetArgv() {
31   return g_argv;
32 }
33 
GetEnvp()34 char** GetEnvp() {
35   return g_envp;
36 }
37 
main(int argc,char ** argv,char ** envp)38 int main(int argc, char** argv, char** envp) {
39   g_argc = argc;
40   g_argv = argv;
41   g_envp = envp;
42 
43   return IsolateMain(argc, argv, envp);
44 }
45