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
|
# -*- python -*-
# Copyright (c) 2011 The Native Client Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# This is a C PPAPI-based version of ../npapi_geturl.
#
# ppapi_geturl.html - test driver that loads the nexe and scripts it
# ppapi_geturl_success.html - to be url-loaded and displayed w/n driver html
#
# ppapi_geturl.cc - implementation of PPP interface
# module.h/cc - implementation of PPP_Instance interface
# scriptable_object.h/cc - implementation of the scripting interface
# url_load_request.h/cc - url loading helper
# nacl_file_main.cc - uses main() to test NaClFile interface
Import('env')
# http://code.google.com/p/nativeclient/issues/detail?id=2359
if env.Bit('bitcode') and env.Bit('nacl_glibc'):
Return()
env.Prepend(CPPDEFINES=['XP_UNIX'])
env.Replace(TEST_DIR='${SOURCE_ROOT}/ppapi/native_client/tests/' +
'ppapi_geturl/')
nexe = 'ppapi_geturl_%s' % env.get('TARGET_FULLARCH')
env.Alias('ppapi_geturl${PROGSUFFIX}',
['$STAGING_DIR/%s${PROGSUFFIX}' % nexe])
ppapi_geturl_nexe = env.ComponentProgram(nexe,
['nacl_file_main.cc',
'module.cc',
'ppapi_geturl.cc',
'url_load_request.cc',
],
EXTRA_LIBS=[
'nacl_file',
'ppruntime',
'srpc',
'imc',
'imc_syscalls',
'platform',
'gio',
'${PTHREAD_LIBS}',
'm',
'${NON_PPAPI_BROWSER_LIBS}'],
EXTRA_LINKFLAGS=['-Wl,--wrap=read',
'-Wl,--wrap=open',
'-Wl,--wrap=lseek',
'-Wl,--wrap=close'])
env.Publish(nexe, 'run',
['ppapi_geturl.html',
'ppapi_geturl_success.html'])
node = env.PPAPIBrowserTester('ppapi_geturl_browser_test.out',
url='ppapi_geturl.html',
nmfs=['${TEST_DIR}/ppapi_geturl.nmf'],
files=env.ExtractPublishedFiles(nexe),
args=['--allow_404'],
)
env.AddNodeToTestSuite(node,
['chrome_browser_tests'],
'run_ppapi_geturl_browser_test',
is_broken=env.PPAPIBrowserTesterIsBroken())
|