#include <bits/stdc++.h>
using namespace std;
int main() {
  int T, n, c1, co, h, m1, mo;
  cin >> T;
  while (T--) {
    cin >> n >> co >> c1 >> h;
    m1 = min(c1, h + co);
    mo = min(co, h + c1);
    co = 0;
    string r;
    cin >> r;
    while (n--) {
      co += (r[n] == '1' ? m1 : mo);
    }
    cout << co << endl;
  }
}
