-
Notifications
You must be signed in to change notification settings - Fork 0
/
introspectTester.js
112 lines (77 loc) · 1.56 KB
/
introspectTester.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
// Tests to run
var
// typeof === 'object'
obj0 = null,
obj1 = {
key1: "This is a string",
key2: 2,
key3: null
},
obj2 = {
key1: function () {
console.log("obj2.key1");
},
key2: [1, 2, 3, 4],
key3: obj1
},
obj3 = {
key1: [],
key2: new Class1(),
key3: {
key1: new Class3(),
key2: function () {
console.log("obj3.key3.key2");
}
}
},
// shit gets real now
obj4 = {
key1: [
function () { console.log("obj4.key1.0"); },
function () { console.log("obj4.key2.1"); }
],
what: {
key1: obj3.key2.objmethod1(),
key2: function () { console.log("obj4.what.key2"); obj3.key3.key2(); },
key3: function () { console.log("obj4.what.key3"); obj3.key3.key2(); }
}
},
// Test Classes
Class1 = function () {
this.objmethod1 = function () {
console.log("Class1.objmethod1");
};
},
Class2 = function () {
this.objmethod1 = function () {
console.log("Class2.objmethod1");
};
this.objmethod2 = function () {
console.log("Class2.objmethod2");
};
this.objmethod3 = function () {
console.log("Class2.objmethod3");
obj4.key1[1]();
};
},
Class3 = function () {
// continue
},
Class4 = function () {
},
Class5 = function () {
},
options = {
};
// Establish Inheritances
Class1.prototype = new Class2();
Class1.prototype.constructor = Class1;
Class3.prototype = new Class2();
Class3.prototype.constructor = Class3;
// Introspect targets
// Run test code
// Introspect more targets
// Run more test code
// Fuck! No more please!!!
// Arrrrrrrgggghhhhhhhhhh!
// Note: This has been a productive 1hr. I'm going to so enjoy sleeping tonight.