summaryrefslogtreecommitdiff
path: root/cras/src/tests/alsa_mixer_unittest.cc
diff options
context:
space:
mode:
Diffstat (limited to 'cras/src/tests/alsa_mixer_unittest.cc')
-rw-r--r--cras/src/tests/alsa_mixer_unittest.cc26
1 files changed, 13 insertions, 13 deletions
diff --git a/cras/src/tests/alsa_mixer_unittest.cc b/cras/src/tests/alsa_mixer_unittest.cc
index edf61101..b3db9de5 100644
--- a/cras/src/tests/alsa_mixer_unittest.cc
+++ b/cras/src/tests/alsa_mixer_unittest.cc
@@ -381,7 +381,7 @@ TEST(AlsaMixer, CreateOneUnknownElementWithVolume) {
mixer_control_destroy(mixer_output);
}
-TEST(AlsaMixer, CreateOneMasterElement) {
+TEST(AlsaMixer, CreateOneMainElement) {
struct cras_alsa_mixer* c;
int element_playback_volume[] = {
1,
@@ -419,10 +419,10 @@ TEST(AlsaMixer, CreateOneMasterElement) {
EXPECT_EQ(3, snd_mixer_selem_get_name_called);
EXPECT_EQ(1, snd_mixer_elem_next_called);
- /* set mute should be called for Master. */
+ /* set mute should be called for Main. */
cras_alsa_mixer_set_mute(c, 0, NULL);
EXPECT_EQ(1, snd_mixer_selem_set_playback_switch_all_called);
- /* set volume should be called for Master. */
+ /* set volume should be called for Main. */
cras_alsa_mixer_set_dBFS(c, 0, NULL);
EXPECT_EQ(1, snd_mixer_selem_set_playback_dB_all_called);
@@ -515,15 +515,15 @@ TEST(AlsaMixer, CreateTwoMainVolumeElements) {
EXPECT_EQ(5, snd_mixer_selem_get_name_called);
EXPECT_EQ(3, snd_mixer_selem_has_playback_switch_called);
- /* Set mute should be called for Master only. */
+ /* Set mute should be called for Main only. */
cras_alsa_mixer_set_mute(c, 0, NULL);
EXPECT_EQ(1, snd_mixer_selem_set_playback_switch_all_called);
- /* Set volume should be called for Master and PCM. If Master doesn't set to
+ /* Set volume should be called for Main and PCM. If Main doesn't set to
* anything but zero then the entire volume should be passed to the PCM
* control.*/
- /* Set volume should be called for Master and PCM. (without mixer_output) */
+ /* Set volume should be called for Main and PCM. (without mixer_output) */
snd_mixer_selem_get_playback_dB_return_values = get_dB_returns;
snd_mixer_selem_get_playback_dB_return_values_length =
ARRAY_SIZE(get_dB_returns);
@@ -557,8 +557,8 @@ TEST(AlsaMixer, CreateTwoMainVolumeElements) {
EXPECT_EQ(1, snd_mixer_selem_has_playback_switch_called);
EXPECT_EQ(1, snd_mixer_selem_get_playback_dB_range_called);
- /* Set volume should be called for Master, PCM, and the mixer_output passed
- * in. If Master doesn't set to anything but zero then the entire volume
+ /* Set volume should be called for Main, PCM, and the mixer_output passed
+ * in. If Main doesn't set to anything but zero then the entire volume
* should be passed to the PCM control.*/
cras_alsa_mixer_set_dBFS(c, -50, mixer_output);
EXPECT_EQ(3, snd_mixer_selem_set_playback_dB_all_called);
@@ -566,8 +566,8 @@ TEST(AlsaMixer, CreateTwoMainVolumeElements) {
EXPECT_EQ(30, set_dB_values[0]);
EXPECT_EQ(30, set_dB_values[1]);
EXPECT_EQ(30, set_dB_values[2]);
- /* Set volume should be called for Master and PCM. Since the controls were
- * sorted, Master should get the volume remaining after PCM is set, in this
+ /* Set volume should be called for Main and PCM. Since the controls were
+ * sorted, Main should get the volume remaining after PCM is set, in this
* case -50 - -24 = -26. */
long get_dB_returns2[] = {
-25,
@@ -584,7 +584,7 @@ TEST(AlsaMixer, CreateTwoMainVolumeElements) {
cras_alsa_mixer_set_dBFS(c, -50, mixer_output);
EXPECT_EQ(2, snd_mixer_selem_set_playback_dB_all_called);
EXPECT_EQ(2, snd_mixer_selem_get_playback_dB_called);
- EXPECT_EQ(54, set_dB_values[0]); // Master
+ EXPECT_EQ(54, set_dB_values[0]); // Main
EXPECT_EQ(30, set_dB_values[1]); // PCM
cras_alsa_mixer_destroy(c);
@@ -639,7 +639,7 @@ TEST(AlsaMixer, CreateTwoMainCaptureElements) {
EXPECT_EQ(5, snd_mixer_selem_get_name_called);
EXPECT_EQ(3, snd_mixer_selem_has_capture_switch_called);
- /* Set mute should be called for Master only. */
+ /* Set mute should be called for Main only. */
cras_alsa_mixer_set_capture_mute(c, 0, NULL);
EXPECT_EQ(1, snd_mixer_selem_set_capture_switch_all_called);
/* Set volume should be called for Capture and Digital Capture. If Capture
@@ -773,7 +773,7 @@ class AlsaMixerOutputs : public testing::Test {
ResetStubData();
snd_mixer_first_elem_return_value =
- reinterpret_cast<snd_mixer_elem_t*>(1); // Master
+ reinterpret_cast<snd_mixer_elem_t*>(1); // Main
snd_mixer_elem_next_return_values = elements;
snd_mixer_elem_next_return_values_length = ARRAY_SIZE(elements);
snd_mixer_selem_has_playback_volume_return_values = element_playback_volume;