Index: test/webkit/fast/js/kde/Date-setYear.js |
diff --git a/test/webkit/array-index-immediate-types.js b/test/webkit/fast/js/kde/Date-setYear.js |
similarity index 72% |
copy from test/webkit/array-index-immediate-types.js |
copy to test/webkit/fast/js/kde/Date-setYear.js |
index 7bacc9d0fc2751ed6b0f943e64a9993226b10d1c..4ccf02517ababb667918405e1e89e7225bc3f2d8 100644 |
--- a/test/webkit/array-index-immediate-types.js |
+++ b/test/webkit/fast/js/kde/Date-setYear.js |
@@ -21,24 +21,16 @@ |
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
-description( |
-"This test checks the behaviour of indexing an Array with immediate types." |
-); |
+description("KDE JS Test"); |
+debug("Start Of Test"); |
-var array = ["Zero", "One"]; |
- |
-shouldBe("array[0]", '"Zero"'); |
-shouldBe("array[null]", "undefined"); |
-shouldBe("array[undefined]", "undefined"); |
-shouldBe("array[true]", "undefined"); |
-shouldBe("array[false]", "undefined"); |
- |
-function putSelf(array, index) |
-{ |
- index = index << 0; |
- array[index] = index; |
- return true; |
-} |
- |
-shouldBeTrue("putSelf([0], 0);"); |
-shouldBeTrue("putSelf([0], 1/9);"); |
+var d = new Date(); |
+shouldBe("d.setYear(-1), d.getFullYear()", "-1"); |
+shouldBe("d.setYear(0), d.getFullYear()", "1900"); |
+shouldBe("d.setYear(1), d.getFullYear()", "1901"); |
+shouldBe("d.setYear(99), d.getFullYear()", "1999"); |
+shouldBe("d.setYear(100), d.getFullYear()", "100"); |
+shouldBe("d.setYear(2050), d.getFullYear()", "2050"); |
+shouldBe("d.setYear(1899), d.getFullYear()", "1899"); |
+shouldBe("d.setYear(2000), d.getFullYear()", "2000"); |
+shouldBe("d.setYear(2100), d.getFullYear()", "2100"); |