tests/auto/qstring/tst_qstring.cpp
changeset 3 41300fa6a67c
parent 0 1918ee327afb
child 4 3b1da2848fc7
equal deleted inserted replaced
2:56cd8111b7f7 3:41300fa6a67c
   199     void QCharRefDetaching() const;
   199     void QCharRefDetaching() const;
   200     void sprintfZU() const;
   200     void sprintfZU() const;
   201     void repeatedSignature() const;
   201     void repeatedSignature() const;
   202     void repeated() const;
   202     void repeated() const;
   203     void repeated_data() const;
   203     void repeated_data() const;
       
   204     void task262677remove();
   204 };
   205 };
   205 
   206 
   206 typedef QList<int> IntList;
   207 typedef QList<int> IntList;
   207 
   208 
   208 Q_DECLARE_METATYPE(QList<QVariant>)
   209 Q_DECLARE_METATYPE(QList<QVariant>)
  4667         << QString(QLatin1String("abc"))
  4668         << QString(QLatin1String("abc"))
  4668         << QString(QLatin1String("abcabcabcabc"))
  4669         << QString(QLatin1String("abcabcabcabc"))
  4669         << 4;
  4670         << 4;
  4670 }
  4671 }
  4671 
  4672 
       
  4673 void tst_QString::task262677remove()
       
  4674 {
       
  4675     QString driveName = QLatin1String("V:\\blahblah\\more_blahblah\\");
       
  4676     driveName.remove(2, INT_MAX); // should be "V:" - instead, it's "V::\\blahblah\\more_blahblah\\"
       
  4677     QVERIFY(driveName == QLatin1String("V:"));
       
  4678 }
       
  4679 
       
  4680 
  4672 QTEST_APPLESS_MAIN(tst_QString)
  4681 QTEST_APPLESS_MAIN(tst_QString)
  4673 
  4682 
  4674 #include "tst_qstring.moc"
  4683 #include "tst_qstring.moc"