#include <bits/stdc++.h>
using namespace std;
#define ll long long int
#define M 1000000007
#define mod 998244353
#define pll pair<ll, ll>
#define f first
#define se second
#define all(x) x.begin(), x.end()
#define allr(x) x.rbegin(), x.rend()
#define pb push_back
#define rb pop_back
#define prdb(x) cout << fixed << setprecision(10) << x;
#define speed1 ios_base ::sync_with_stdio(false);
#define speed2 cin.tie(NULL);
#define endl "\n"
/************
 * fill the array with desired value
    fill(all(vec), 1);    
    
 *fills the dsu parent array consecutively starting from desired value
    iota(all(parent), 0); 

 * sort the vector and then make all elements unique
    sort(all(vec)); 
    vec.resize(unique(all(vec)) - vec.begin());  

************/
int main()
{
    //#ifndef ONLINE_JUDGE
    //    freopen("input.txt", "r", stdin);
    //    freopen("output.txt", "w", stdout);
    //#endif
    speed1;
    speed2;

    ll t = 1;
    cin >> t;
    while (t--)
    {
        ll n, x, y;
        cin >> n >> x >> y;
        ll a[n];
        ll i, j, k;
        for (i = 0; i < n; i++)
            cin >> a[i];

        k = a[0];
        for (i = 1; i < n; i++)
        {
            if (k != a[i])
                break;
        }
        if (i == n)
        {
            cout << min(2 * y, x + y) << endl;
            continue;
        }
        for (i = 1; i < n; i++)
        {
            if (abs(a[i] - a[i - 1]) > 1)
            {
                cout << 0 << endl;
                break;
            }
        }
        if (i == n)
            cout << min(x, y) << endl;
    }
}