diff --git a/res/layout/manage_data_plans_preference.xml b/res/layout/manage_data_plans_preference.xml
new file mode 100644
index 00000000000..1686d3fe64a
--- /dev/null
+++ b/res/layout/manage_data_plans_preference.xml
@@ -0,0 +1,32 @@
+
+
+
+
+
+
diff --git a/res/values/strings.xml b/res/values/strings.xml
index 95e6e181c3c..543e2733204 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -5526,6 +5526,9 @@
Select all
+
+ Manage plans
+
Data usage
diff --git a/tests/robotests/src/com/android/settings/datausage/ManageDataPlansPreferenceTest.java b/tests/robotests/src/com/android/settings/datausage/ManageDataPlansPreferenceTest.java
new file mode 100644
index 00000000000..6eff393cd0e
--- /dev/null
+++ b/tests/robotests/src/com/android/settings/datausage/ManageDataPlansPreferenceTest.java
@@ -0,0 +1,62 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License
+ */
+
+package com.android.settings.datausage;
+
+import static com.google.common.truth.Truth.assertThat;
+
+import android.content.Context;
+import android.support.v7.preference.Preference;
+import android.support.v7.preference.PreferenceViewHolder;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.widget.Button;
+import android.widget.LinearLayout;
+import com.android.settings.R;
+import com.android.settings.TestConfig;
+import com.android.settings.testutils.SettingsRobolectricTestRunner;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.robolectric.RuntimeEnvironment;
+import org.robolectric.annotation.Config;
+
+@RunWith(SettingsRobolectricTestRunner.class)
+@Config(manifest = TestConfig.MANIFEST_PATH, sdk = TestConfig.SDK_VERSION)
+public final class ManageDataPlansPreferenceTest {
+ private Preference mPreference;
+ private PreferenceViewHolder mHolder;
+ private Context mContext;
+
+ @Before
+ public void setUp() {
+ mContext = RuntimeEnvironment.application;
+ mPreference = new Preference(mContext);
+ mPreference.setLayoutResource(R.layout.manage_data_plans_preference);
+ LayoutInflater inflater = LayoutInflater.from(mContext);
+ View view = inflater.inflate(mPreference.getLayoutResource(),
+ new LinearLayout(mContext), false);
+ mHolder = PreferenceViewHolder.createInstanceForTests(view);
+ }
+
+ @Test
+ public void shouldRender_withData() {
+ mPreference.onBindViewHolder(mHolder);
+ Button managePlanButton = (Button) mHolder.findViewById(R.id.manage_data_plans);
+ assertThat(managePlanButton.getText())
+ .isEqualTo(mContext.getString(R.string.data_plan_usage_manage_plans_button_text));
+ }
+}