%bcond_with wayland
Name: crosswalk
-Version: 5.34.97.0
+Version: 5.34.98.0
Release: 0
Summary: Crosswalk is an app runtime based on Chromium
License: (BSD-3-Clause and LGPL-2.1+)
Group: Web Framework/Web Run Time
Url: https://github.com/otcshare/crosswalk
Source: %{name}.tar
-Source1: xwalk
+Source1: xwalk.in
Source2: org.crosswalkproject.Runtime1.service
-Source3: xwalk.service
+Source3: xwalk.service.in
Source1001: crosswalk.manifest
Source1002: %{name}.xml.in
Source1003: %{name}.png
%prep
%setup -q -n crosswalk
+cp %{SOURCE1} .
+cp %{SOURCE3} .
cp %{SOURCE1001} .
cp %{SOURCE1002} .
cp %{SOURCE1003} .
sed "s/@VERSION@/%{version}/g" %{name}.xml.in > %{name}.xml
+sed "s|@LIB_INSTALL_DIR@|%{_libdir}|g" xwalk.in > xwalk
+sed "s|@LIB_INSTALL_DIR@|%{_libdir}|g" xwalk.service.in > xwalk.service
cp -a src/AUTHORS AUTHORS.chromium
cp -a src/LICENSE LICENSE.chromium
cd src
# Binaries.
-install -p -D %{SOURCE1} %{buildroot}%{_bindir}/xwalk
+install -p -D ../xwalk %{buildroot}%{_bindir}/xwalk
install -p -D %{SOURCE2} %{buildroot}%{_dbusservicedir}/org.crosswalkproject.Runtime1.service
-install -p -D %{SOURCE3} %{buildroot}%{_systemduserservicedir}/xwalk.service
+install -p -D ../xwalk.service %{buildroot}%{_systemduserservicedir}/xwalk.service
install -p -D ${BUILDDIR_NAME}/out/Release/xwalk %{buildroot}%{_libdir}/xwalk/xwalk
install -p -D ${BUILDDIR_NAME}/out/Release/xwalkctl %{buildroot}%{_bindir}/xwalkctl
install -p -D ${BUILDDIR_NAME}/out/Release/xwalk-launcher %{buildroot}%{_bindir}/xwalk-launcher
+++ /dev/null
-#!/bin/sh
-
-exec /usr/lib/xwalk/xwalk $@
--- /dev/null
+#!/bin/sh
+
+exec @LIB_INSTALL_DIR@/xwalk/xwalk $@
+++ /dev/null
-[Unit]
-Description=Crosswalk
-
-[Service]
-Type=dbus
-BusName=org.crosswalkproject.Runtime1
-ExecStart=/usr/lib/xwalk/xwalk --run-as-service --external-extensions-path=/usr/lib/tizen-extensions-crosswalk
--- /dev/null
+[Unit]
+Description=Crosswalk
+
+[Service]
+Type=dbus
+BusName=org.crosswalkproject.Runtime1
+ExecStart=@LIB_INSTALL_DIR@/xwalk/xwalk --run-as-service --external-extensions-path=@LIB_INSTALL_DIR@/tizen-extensions-crosswalk
MAJOR=5
MINOR=34
-BUILD=97
+BUILD=98
PATCH=0
shutil.rmtree(path)
-def RunCommand(command, shell=False):
+def RunCommand(command, verbose=False, shell=False):
"""Runs the command list, print the output, and propagate its result."""
proc = subprocess.Popen(command, stdout=subprocess.PIPE,
stderr=subprocess.STDOUT, shell=shell)
if not shell:
output = proc.communicate()[0]
result = proc.returncode
- print(output.decode("utf-8"))
+ if verbose:
+ print(output.decode("utf-8").strip())
if result != 0:
print ('Command "%s" exited with non-zero exit code %d'
% (' '.join(command), result))
# features, according to recommendation in URL
return '--app-versionCode=%s%s' % (abi, b.zfill(7))
+
def Customize(options):
package = '--package=org.xwalk.app.template'
if options.package:
name, app_version, app_versionCode, description, icon, permissions,
app_url, remote_debugging, app_root, app_local_path, fullscreen_flag,
extensions_list, orientation, default_image]
- RunCommand(cmd)
+ RunCommand(cmd, options.verbose)
def Execution(options, sanitized_name):
# Check whether ant is installed.
try:
cmd = ['ant', '-version']
- RunCommand(cmd, True)
+ RunCommand(cmd, shell=True)
except EnvironmentError:
print('Please install ant first.')
sys.exit(4)
'-Dbasedir=.',
'-buildfile',
os.path.join('scripts', 'ant', 'apk-codegen.xml')]
- RunCommand(cmd)
+ RunCommand(cmd, options.verbose)
# Check whether java is installed.
try:
cmd = ['java', '-version']
- RunCommand(cmd, True)
+ RunCommand(cmd, shell=True)
except EnvironmentError:
print('Please install Oracle JDK first.')
sys.exit(5)
'-Dbasedir=.',
'-buildfile',
xml_path]
- RunCommand(cmd)
+ RunCommand(cmd, options.verbose)
dex_path = '--dex-path=' + os.path.join(os.getcwd(), 'out', 'classes.dex')
app_runtime_jar = os.path.join(os.getcwd(),
'-Dbasedir=.',
'-buildfile',
'scripts/ant/apk-package.xml']
- RunCommand(cmd)
+ RunCommand(cmd, options.verbose)
apk_path = '--unsigned-apk-path=' + os.path.join('out', 'app-unsigned.apk')
final_apk_path = '--final-apk-path=' + \
parser.add_option('-v', '--version', action='store_true',
dest='version', default=False,
help='The version of this python tool.')
+ parser.add_option('--verbose', action="store_true",
+ dest='verbose', default=False,
+ help='Print debug messages.')
info = ('The packaging mode of the web application. The value \'shared\' '
'means that the runtime is shared across multiple application '
'instances and that the runtime needs to be distributed separately. '
def testManifestWithError(self):
manifest_path = os.path.join('test_data', 'manifest',
'manifest_no_app_launch_path.json')
- cmd = ['python', 'make_apk.py', '--manifest=%s' % manifest_path, self._mode]
+ cmd = ['python', 'make_apk.py', '--manifest=%s' % manifest_path,
+ '--verbose', self._mode]
out = RunCommand(cmd)
self.assertTrue(out.find('no app launch path') != -1)
manifest_path = os.path.join('test_data', 'manifest',
'manifest_no_name.json')
- proc = subprocess.Popen(['python', 'make_apk.py',
- '--manifest=%s' % manifest_path,
- self._mode],
- stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
- out, _ = proc.communicate()
+ cmd = ['python', 'make_apk.py', '--manifest=%s' % manifest_path,
+ '--verbose', self._mode]
+ out = RunCommand(cmd)
self.assertTrue(out.find('no \'name\' field') != -1)
manifest_path = os.path.join('test_data', 'manifest',
'manifest_no_version.json')
- proc = subprocess.Popen(['python', 'make_apk.py',
- '--manifest=%s' % manifest_path,
- self._mode],
- stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
- out, _ = proc.communicate()
+ cmd = ['python', 'make_apk.py', '--manifest=%s' % manifest_path,
+ '--verbose', self._mode]
+ out = RunCommand(cmd)
self.assertTrue(out.find('no \'version\' field') != -1)
manifest_path = os.path.join('test_data', 'manifest',
'manifest_permissions_format_error.json')
- proc = subprocess.Popen(['python', 'make_apk.py',
- '--manifest=%s' % manifest_path,
- self._mode],
- stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
- out, _ = proc.communicate()
+ cmd = ['python', 'make_apk.py', '--manifest=%s' % manifest_path,
+ '--verbose', self._mode]
+ out = RunCommand(cmd)
self.assertTrue(out.find('\'Permissions\' field error') != -1)
manifest_path = os.path.join('test_data', 'manifest',
'manifest_permissions_field_error.json')
- proc = subprocess.Popen(['python', 'make_apk.py',
- '--manifest=%s' % manifest_path,
- self._mode],
- stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
- out, _ = proc.communicate()
+ cmd = ['python', 'make_apk.py', '--manifest=%s' % manifest_path,
+ '--verbose', self._mode]
+ out = RunCommand(cmd)
self.assertTrue(out.find('\'Permissions\' field error') != -1)
manifest_path = os.path.join('test_data', 'manifest',
'manifest_not_supported_permission.json')
- proc = subprocess.Popen(['python', 'make_apk.py',
- '--manifest=%s' % manifest_path,
- self._mode],
- stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
- out, _ = proc.communicate()
+ cmd = ['python', 'make_apk.py', '--manifest=%s' % manifest_path,
+ '--verbose', self._mode]
+ out = RunCommand(cmd)
self.assertTrue(
out.find('\'Telephony\' related API is not supported') != -1)
extension_path = 'test_data/extensions/myextension'
cmd = ['python', 'make_apk.py', '--name=Example', '--app-version=1.0.0',
'--package=org.xwalk.example', '--app-url=http://www.intel.com',
- '--extensions=%s1' % extension_path, self._mode]
+ '--extensions=%s1' % extension_path, self._mode, '--verbose']
out = RunCommand(cmd)
error_msg = 'Error: can\'t find the extension directory'
self.assertTrue(out.find(error_msg) != -1)
self.assertFalse(os.path.isfile('Example_1.0.0_x86.apk'))
Clean('Example', '1.0.0')
+
+ def testVerbose(self):
+ cmd = ['python', 'make_apk.py', '--name=Example', '--app-version=1.0.0',
+ '--package=org.xwalk.example', '--app-url=http://www.intel.com',
+ '--verbose', self._mode]
+ result = RunCommand(cmd)
+ self.assertTrue(result.find('aapt') != -1)
+ self.assertTrue(result.find('crunch') != -1)
+ self.assertTrue(result.find('apkbuilder') != -1)
+ self.assertTrue(os.path.exists('Example'))
+ self.checkApks('Example', '1.0.0')
+ Clean('Example', '1.0.0')
+
+
def testEmptyMode(self):
# Test all of supported options with empty 'mode' option.
icon_path = './app_src/res/drawable-xhdpi/crosswalk.png'
test_suite = unittest.TestSuite()
test_suite.addTest(TestMakeApk('testEmptyMode'))
test_suite.addTest(TestMakeApk('testToolVersion'))
+ test_suite.addTest(TestMakeApk('testVerbose'))
return test_suite
namespace application {
+namespace {
+
net::HttpResponseHeaders* BuildHttpHeaders(
const std::string& content_security_policy,
const std::string& mime_type, const std::string& method,
return new net::HttpResponseHeaders(raw_headers);
}
-namespace {
-
class GeneratedMainDocumentJob: public net::URLRequestSimpleJob {
public:
GeneratedMainDocumentJob(
#ifndef XWALK_APPLICATION_BROWSER_APPLICATION_PROTOCOLS_H_
#define XWALK_APPLICATION_BROWSER_APPLICATION_PROTOCOLS_H_
-#include <string>
-
-#include "base/files/file_path.h"
#include "base/memory/linked_ptr.h"
#include "net/url_request/url_request_job_factory.h"
#include "xwalk/application/browser/application_system.h"
-namespace net {
-class HttpResponseHeaders;
-}
-
namespace xwalk {
namespace application {
class ApplicationService;
-net::HttpResponseHeaders* BuildHttpHeaders(
- const std::string& content_security_policy,
- const std::string& mime_type, const std::string& method,
- const base::FilePath& file_path, const base::FilePath& relative_path,
- bool is_authority_match);
// Creates the handlers for the app:// scheme.
linked_ptr<net::URLRequestJobFactory::ProtocolHandler>
base::Closure closure = base::Bind(
base::IgnoreResult(&XWalkExtensionServer::OnMessageReceived),
- base::Unretained(server), message);
+ server->AsWeakPtr(), message);
task_runner->PostTask(FROM_HERE, closure);
}
base::Closure closure = base::Bind(
base::IgnoreResult(&XWalkExtensionServer::OnCreateInstance),
- base::Unretained(server), instance_id, name);
+ server->AsWeakPtr(), instance_id, name);
task_runner->PostTask(FROM_HERE, closure);
}
#include <string>
#include <vector>
+#include "base/memory/weak_ptr.h"
#include "base/synchronization/lock.h"
#include "base/values.h"
#include "ipc/ipc_channel_proxy.h"
//
// This class is used both by in-process extensions running in the Browser
// Process, and by the external extensions running in the Extension Process.
-class XWalkExtensionServer : public IPC::Listener {
+class XWalkExtensionServer : public IPC::Listener,
+ public base::SupportsWeakPtr<XWalkExtensionServer> {
public:
XWalkExtensionServer();
virtual ~XWalkExtensionServer();
%bcond_with wayland
Name: crosswalk
-Version: 5.34.97.0
+Version: 5.34.98.0
Release: 0
Summary: Crosswalk is an app runtime based on Chromium
License: (BSD-3-Clause and LGPL-2.1+)
Group: Web Framework/Web Run Time
Url: https://github.com/otcshare/crosswalk
Source: %{name}.tar
-Source1: xwalk
+Source1: xwalk.in
Source2: org.crosswalkproject.Runtime1.service
-Source3: xwalk.service
+Source3: xwalk.service.in
Source1001: crosswalk.manifest
Source1002: %{name}.xml.in
Source1003: %{name}.png
%prep
%setup -q -n crosswalk
+cp %{SOURCE1} .
+cp %{SOURCE3} .
cp %{SOURCE1001} .
cp %{SOURCE1002} .
cp %{SOURCE1003} .
sed "s/@VERSION@/%{version}/g" %{name}.xml.in > %{name}.xml
+sed "s|@LIB_INSTALL_DIR@|%{_libdir}|g" xwalk.in > xwalk
+sed "s|@LIB_INSTALL_DIR@|%{_libdir}|g" xwalk.service.in > xwalk.service
cp -a src/AUTHORS AUTHORS.chromium
cp -a src/LICENSE LICENSE.chromium
cd src
# Binaries.
-install -p -D %{SOURCE1} %{buildroot}%{_bindir}/xwalk
+install -p -D ../xwalk %{buildroot}%{_bindir}/xwalk
install -p -D %{SOURCE2} %{buildroot}%{_dbusservicedir}/org.crosswalkproject.Runtime1.service
-install -p -D %{SOURCE3} %{buildroot}%{_systemduserservicedir}/xwalk.service
+install -p -D ../xwalk.service %{buildroot}%{_systemduserservicedir}/xwalk.service
install -p -D ${BUILDDIR_NAME}/out/Release/xwalk %{buildroot}%{_libdir}/xwalk/xwalk
install -p -D ${BUILDDIR_NAME}/out/Release/xwalkctl %{buildroot}%{_bindir}/xwalkctl
install -p -D ${BUILDDIR_NAME}/out/Release/xwalk-launcher %{buildroot}%{_bindir}/xwalk-launcher
+++ /dev/null
-#!/bin/sh
-
-exec /usr/lib/xwalk/xwalk $@
--- /dev/null
+#!/bin/sh
+
+exec @LIB_INSTALL_DIR@/xwalk/xwalk $@
+++ /dev/null
-[Unit]
-Description=Crosswalk
-
-[Service]
-Type=dbus
-BusName=org.crosswalkproject.Runtime1
-ExecStart=/usr/lib/xwalk/xwalk --run-as-service --external-extensions-path=/usr/lib/tizen-extensions-crosswalk
--- /dev/null
+[Unit]
+Description=Crosswalk
+
+[Service]
+Type=dbus
+BusName=org.crosswalkproject.Runtime1
+ExecStart=@LIB_INSTALL_DIR@/xwalk/xwalk --run-as-service --external-extensions-path=@LIB_INSTALL_DIR@/tizen-extensions-crosswalk
import android.util.Log;
import java.lang.reflect.Field;
+import java.lang.reflect.Modifier;
public class XWalkInternalResources {
private static final String TAG = "XWalkInternalResources";
Field[] fields = innerClazz.getFields();
for (Field field : fields) {
// It's final means we are probably not used as library project.
- if (!field.isAccessible()) continue;
+ if (Modifier.isFinal(field.getModifiers())) continue;
try {
int value = generatedInnerClazz.getField(field.getName()).getInt(null);
field.setInt(null, value);
#include "base/android/jni_android.h"
#include "base/android/jni_string.h"
#include "jni/InterceptedRequestData_jni.h"
-#include "net/base/escape.h"
#include "net/url_request/url_request.h"
#include "net/url_request/url_request_job.h"
#include "xwalk/runtime/browser/android/net/android_protocol_handler.h"
#include "xwalk/runtime/browser/android/net/android_stream_reader_url_request_job.h"
#include "xwalk/runtime/browser/android/net/input_stream_impl.h"
#include "xwalk/runtime/browser/runtime_context.h"
-#include "xwalk/runtime/browser/xwalk_browser_main_parts.h"
-#include "xwalk/runtime/browser/xwalk_content_browser_client.h"
+#include "xwalk/runtime/browser/xwalk_runner.h"
using base::android::ScopedJavaLocalRef;
scoped_ptr<AndroidStreamReaderURLRequestJob::Delegate>
stream_reader_job_delegate_impl(new StreamReaderJobDelegateImpl(this));
- base::FilePath relative_path = base::FilePath(
- net::UnescapeURLComponent(request->url().path(),
- net::UnescapeRule::SPACES | net::UnescapeRule::URL_SPECIAL_CHARS));
-
- xwalk::XWalkBrowserMainParts* main_parts =
- xwalk::XWalkContentBrowserClient::Get()->main_parts();
- xwalk::RuntimeContext* runtime_context = main_parts->runtime_context();
+ RuntimeContext* runtime_context =
+ XWalkRunner::GetInstance()->runtime_context();
std::string content_security_policy = runtime_context->GetCSPString();
return new AndroidStreamReaderURLRequestJob(
request, network_delegate, stream_reader_job_delegate_impl.Pass(),
- relative_path, content_security_policy);
+ content_security_policy);
}
} // namespace xwalk
#include "xwalk/runtime/browser/android/net/input_stream_impl.h"
#include "xwalk/runtime/browser/android/net/url_constants.h"
#include "xwalk/runtime/browser/runtime_context.h"
-#include "xwalk/runtime/browser/xwalk_browser_main_parts.h"
-#include "xwalk/runtime/browser/xwalk_content_browser_client.h"
+#include "xwalk/runtime/browser/xwalk_runner.h"
using base::android::AttachCurrentThread;
using base::android::ClearException;
scoped_ptr<AndroidStreamReaderURLRequestJobDelegateImpl> reader_delegate(
new AndroidStreamReaderURLRequestJobDelegateImpl());
- base::FilePath relative_path = base::FilePath(
- net::UnescapeURLComponent(request->url().path(),
- net::UnescapeRule::SPACES | net::UnescapeRule::URL_SPECIAL_CHARS));
-
- xwalk::XWalkBrowserMainParts* main_parts =
- xwalk::XWalkContentBrowserClient::Get()->main_parts();
- xwalk::RuntimeContext* runtime_context = main_parts->runtime_context();
+ xwalk::RuntimeContext* runtime_context =
+ xwalk::XWalkRunner::GetInstance()->runtime_context();
std::string content_security_policy = runtime_context->GetCSPString();
return new AndroidStreamReaderURLRequestJob(
request,
network_delegate,
reader_delegate.PassAs<AndroidStreamReaderURLRequestJob::Delegate>(),
- relative_path,
content_security_policy);
}
#include "net/http/http_util.h"
#include "net/url_request/url_request.h"
#include "net/url_request/url_request_job_manager.h"
-#include "xwalk/application/browser/application_protocols.h"
#include "xwalk/runtime/browser/android/net/input_stream.h"
#include "xwalk/runtime/browser/android/net/input_stream_reader.h"
#include "xwalk/runtime/browser/android/net/url_constants.h"
net::URLRequest* request,
net::NetworkDelegate* network_delegate,
scoped_ptr<Delegate> delegate,
- const base::FilePath& relative_path,
const std::string& content_security_policy)
: URLRequestJob(request, network_delegate),
delegate_(delegate.Pass()),
- mime_type_("text/html"),
- relative_path_(relative_path),
content_security_policy_(content_security_policy),
weak_factory_(this) {
DCHECK(delegate_);
content_type_header.append(mime_type);
headers->AddHeader(content_type_header);
}
+
+ if (!content_security_policy_.empty()) {
+ std::string content_security_policy("Content-Security-Policy: ");
+ content_security_policy.append(content_security_policy_);
+ headers->AddHeader(content_security_policy);
+ }
}
response_info_.reset(new net::HttpResponseInfo());
void AndroidStreamReaderURLRequestJob::GetResponseInfo(
net::HttpResponseInfo* info) {
- if (response_info_) {
- // TODO(gaochun): Enable CSP when http status code issue was fixed.
- // Bug: https://crosswalk-project.org/jira/browse/XWALK-1022
+ if (response_info_)
*info = *response_info_;
- }
}
void AndroidStreamReaderURLRequestJob::SetExtraRequestHeaders(
#include <string>
#include "base/android/scoped_java_ref.h"
-#include "base/files/file_path.h"
#include "base/location.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
net::URLRequest* request,
net::NetworkDelegate* network_delegate,
scoped_ptr<Delegate> delegate,
- const base::FilePath& relative_path,
const std::string& content_security_policy);
// URLRequestJob:
net::HttpByteRange byte_range_;
scoped_ptr<net::HttpResponseInfo> response_info_;
scoped_ptr<Delegate> delegate_;
- const std::string mime_type_;
- base::FilePath relative_path_;
std::string content_security_policy_;
scoped_refptr<InputStreamReaderWrapper> input_stream_reader_wrapper_;
base::WeakPtrFactory<AndroidStreamReaderURLRequestJob> weak_factory_;
#include "xwalk/runtime/browser/android/xwalk_web_contents_delegate.h"
#include "xwalk/runtime/browser/runtime_context.h"
#include "xwalk/runtime/browser/runtime_resource_dispatcher_host_delegate_android.h"
-#include "xwalk/runtime/browser/xwalk_browser_main_parts.h"
-#include "xwalk/runtime/browser/xwalk_content_browser_client.h"
+#include "xwalk/runtime/browser/xwalk_runner.h"
#include "jni/XWalkContent_jni.h"
using base::android::AttachCurrentThread;
JNIEnv* env, jobject io_thread_client,
jobject intercept_navigation_delegate) {
- XWalkBrowserMainParts* main_parts =
- XWalkContentBrowserClient::Get()->main_parts();
- CHECK(main_parts);
- // FIXME : need a better way to get context.
- RuntimeContext* runtime_context = main_parts->runtime_context();
+ RuntimeContext* runtime_context =
+ XWalkRunner::GetInstance()->runtime_context();
CHECK(runtime_context);
content::WebContents* web_contents = content::WebContents::Create(
std::string csp;
manifest.GetString(
xwalk::application_manifest_keys::kCSPKey, &csp);
- XWalkBrowserMainParts* main_parts =
- XWalkContentBrowserClient::Get()->main_parts();
- CHECK(main_parts);
- RuntimeContext* runtime_context = main_parts->runtime_context();
+ RuntimeContext* runtime_context =
+ XWalkRunner::GetInstance()->runtime_context();
CHECK(runtime_context);
runtime_context->SetCSPString(csp);
void XWalkBrowserMainParts::PreMainMessageLoopRun() {
xwalk_runner_->PreMainMessageLoopRun();
- runtime_context_ = xwalk_runner_->runtime_context();
extension_service_ = xwalk_runner_->extension_service();
if (extension_service_)
const char* local_ip = "0.0.0.0";
if (base::StringToInt(port_str, &port) && port > 0 && port < 65535) {
remote_debugging_server_.reset(
- new RemoteDebuggingServer(runtime_context_,
+ new RemoteDebuggingServer(xwalk_runner_->runtime_context(),
local_ip, port, std::string()));
}
}
namespace xwalk {
-class RuntimeContext;
class RemoteDebuggingServer;
class XWalkRunner;
extensions::XWalkExtensionVector* extensions);
#if defined(OS_ANDROID)
- RuntimeContext* runtime_context() { return runtime_context_; }
-
// XWalkExtensionAndroid needs to register its extensions on
// XWalkBrowserMainParts so they get correctly registered on-demand
// by XWalkExtensionService each time a in_process Server is created.
XWalkRunner* xwalk_runner_;
- RuntimeContext* runtime_context_;
-
extensions::XWalkExtensionService* extension_service_;
// Should be about:blank If no URL is specified in command line arguments.
xwalk_runner_->PreMainMessageLoopRun();
- runtime_context_ = xwalk_runner_->runtime_context();
extension_service_ = xwalk_runner_->extension_service();
// Prepare the cookie store.
}
}
- //@SmallTest
- //@Feature({"XWalkClientShouldInterceptRequest"})
- // TODO(gaochun): Enable it once the issue XWALK-1022 gets resolved.
- @DisabledTest
+ @SmallTest
+ @Feature({"XWalkClientShouldInterceptRequest"})
public void testHttpStatusField() throws Throwable {
final String syncGetUrl = mWebServer.getResponseUrl("/intercept_me");
final String syncGetJs =
package org.xwalk.runtime.client.test;
import android.test.suitebuilder.annotation.SmallTest;
-import org.chromium.base.test.util.DisabledTest;
import org.chromium.base.test.util.Feature;
import org.xwalk.runtime.client.shell.XWalkRuntimeClientShellActivity;
import org.xwalk.test.util.RuntimeClientApiTestBase;
*/
public class CSPTest extends XWalkRuntimeClientTestBase {
- // TODO(gaochun): Enable the test when the issue was fixed:
- // Bug: https://crosswalk-project.org/jira/browse/XWALK-1022
- // @SmallTest
- // @Feature({"CSP"})
- @DisabledTest
+ @SmallTest
+ @Feature({"CSP"})
public void testCSP() throws Throwable {
RuntimeClientApiTestBase<XWalkRuntimeClientShellActivity> helper =
new RuntimeClientApiTestBase<XWalkRuntimeClientShellActivity>(
package org.xwalk.runtime.client.embedded.test;
import android.test.suitebuilder.annotation.SmallTest;
-import org.chromium.base.test.util.DisabledTest;
import org.chromium.base.test.util.Feature;
import org.xwalk.runtime.client.embedded.shell.XWalkRuntimeClientEmbeddedShellActivity;
import org.xwalk.test.util.RuntimeClientApiTestBase;
*/
public class CSPTest extends XWalkRuntimeClientTestBase {
- // TODO(gaochun): Enable the test when the issue was fixed:
- // Bug: https://crosswalk-project.org/jira/browse/XWALK-1022
- // @SmallTest
- // @Feature({"CSP"})
- @DisabledTest
+ @SmallTest
+ @Feature({"CSP"})
public void testCSP() throws Throwable {
RuntimeClientApiTestBase<XWalkRuntimeClientEmbeddedShellActivity> helper =
new RuntimeClientApiTestBase<XWalkRuntimeClientEmbeddedShellActivity>(