From: Aaron Traas Date: Thu, 29 Jun 2017 21:22:00 +0000 (-0400) Subject: Test coverage -- fix regression X-Git-Tag: 1.1~4 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=refs%2Fmerge-requests%2F163%2Fhead;p=open-adventure.git Test coverage -- fix regression --- diff --git a/tests/lockchain.chk b/tests/lockchain.chk index 5fc192a..c2986a7 100644 --- a/tests/lockchain.chk +++ b/tests/lockchain.chk @@ -615,48 +615,37 @@ A formidable ogre bars the northern exit. Attac what? -> n - -The ogre snarls and shoves you back. +> kill ogre -There is a threatening little dwarf in the room with you! +The ogre, who despite his bulk is quite agile, easily dodges your +attack. He seems almost amused by your puny effort. One sharp nasty knife is thrown at you! -It misses! +The ogre, distracted by your rush, is struck by the knife. With a +blood-curdling yell he turns and bounds after the dwarf, who flees +in panic. You are left alone in the room. -You are in a large chamber with passages to the west and north. +> n -A formidable ogre bars the northern exit. +You are in the ogre's storeroom. The only exit is to the south. + +There is an enormous ruby here! > take ruby -I see no ruby here. +OK > s -There is no way to go that direction. - -There is a threatening little dwarf in the room with you! - -One sharp nasty knife is thrown at you! - -It misses! - You are in a large chamber with passages to the west and north. -A formidable ogre bars the northern exit. - > w -There is a threatening little dwarf in the room with you! - You are in a long, rough-hewn, north/south corridor. > n -There is a threatening little dwarf in the room with you! - Dead end There is a massive vending machine here, swung back to reveal a @@ -664,44 +653,30 @@ southward passage. > n -There is a threatening little dwarf in the room with you! - You are in a little maze of twisting passages, all different. > n -There is a threatening little dwarf in the room with you! - You are in a little maze of twisty passages, all different. > nw -There is a threatening little dwarf in the room with you! - You are in a maze of twisty little passages, all different. > d -There is a threatening little dwarf in the room with you! - You're at west end of long hall. > e -There is a threatening little dwarf in the room with you! - You're at east end of long hall. > e -There is a threatening little dwarf in the room with you! - You're at west end of Hall of Mists. > e -There is a threatening little dwarf in the room with you! - You're on west bank of fissure. There are diamonds here! @@ -714,8 +689,6 @@ OK > e -There is a threatening little dwarf in the room with you! - You're on east bank of fissure. A three foot black rod with a rusty star on an end lies nearby. @@ -724,8 +697,6 @@ A crystal bridge now spans the fissure. > e -There is a threatening little dwarf in the room with you! - You're in Hall of Mists. Rough stone steps lead up the dome. @@ -736,8 +707,6 @@ OK > s -There is a threatening little dwarf in the room with you! - This is a low room with a crude note on the wall. The note says, "You won't get it up the steps". @@ -749,162 +718,1018 @@ OK > n -A little dwarf with a big knife blocks your way. +You're in Hall of Mists. -There is a threatening little dwarf in the room with you! +There is a bottle of water here. -One sharp nasty knife is thrown at you! +> n -It misses! +You're in Hall of Mt King. + +> n -You're in nugget-of-gold room. +You're in n/s passage above e/w passage. > n -There are 2 threatening little dwarves in the room with you. +You're at "Y2". -One sharp nasty knife is thrown at you! +> off -It misses! +Your lamp is now off. -You're in Hall of Mists. +It is now pitch dark. If you proceed you will likely fall into a pit. + +> plugh + +>>Foof!<< + +You're inside building. + +There are bars of silver here! + +There is a persian rug spread out on the floor! + +There is precious jewelry here! + +A precious jade necklace has been dropped here! + +There are some keys on the ground here. + +There is food here. + +> drop gold + +OK + +> drop diamonds + +OK + +> drop pyramid + +OK + +> drop ruby + +OK + +> plugh + +>>Foof!<< + +It is now pitch dark. If you proceed you will likely fall into a pit. + +A hollow voice says "PLUGH". + +> on + +Your lamp is now on. + +You're at "Y2". + +> s + +You're in n/s passage above e/w passage. + +> s + +You are in the Hall of the Mountain King, with passages off in all +directions. + +> u + +There is a threatening little dwarf in the room with you! + +You are at one end of a vast hall stretching forward out of sight to +the west. There are openings to either side. Nearby, a wide stone +staircase leads downward. The hall is filled with wisps of white mist +swaying to and fro almost as if alive. A cold wind blows up the +staircase. There is a passage at the top of a dome behind you. There is a bottle of water here. -> n +Rough stone steps lead up the dome. -There are 2 threatening little dwarves in the room with you. +> take water + +OK + +> throw axe + +You killed a little dwarf. + +You're in Hall of Mists. + +There is a little axe here. + +Rough stone steps lead up the dome. + +> take axe + +OK + +> n You're in Hall of Mt King. > n -There are 2 threatening little dwarves in the room with you. +You are in a low n/s passage at a hole in the floor. The hole goes +down to an e/w passage. -You're in n/s passage above e/w passage. +> d -> off +You're in dirty passage. -Your lamp is now off. +> bedquilt -It is now pitch dark. If you proceed you will likely fall into a pit. +You are in Bedquilt, a long east/west passage with holes everywhere. +To explore at random select north, south, up, or down. -> plugh +> slab -Nothing happens. +You are in a large low circular chamber whose floor is an immense slab +fallen from the ceiling (Slab Room). East and west there once were +large passages, but they are now filled with boulders. Low small +passages go north and south, and the south one quickly bends west +around the boulders. -There are 2 threatening little dwarves in the room with you. +> s + +You are at the west end of the Twopit Room. There is a large hole in +the wall above the pit at this end of the room. -2 of them throw knives at you! +> d -One of them gets you! +You are at the bottom of the western pit in the Twopit Room. There is +a large hole in the wall about 25 feet above you. -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +There is a tiny little plant in the pit, murmuring "water, water, ..." -> drop gold +> water plant -Please answer the question. +The plant spurts into furious growth for a few seconds. -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +You're in west pit. -> drop diamonds +There is a 12-foot-tall beanstalk stretching up out of the pit, +bellowing "WATER!! WATER!!" -Please answer the question. +> u -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +You're at west end of Twopit Room. -> drop pyramid +The top of a 12-foot-tall beanstalk is poking out of the west pit. -Please answer the question. +> w -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +You're in Slab Room. -> drop ruby +> u -Please answer the question. +You are in a secret n/s canyon above a large room. -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +> reservoir -> plugh +You are at the edge of a large underground reservoir. An opaque cloud +of white mist fills the room and rises rapidly upward. The lake is +fed by a stream, which tumbles out of a hole in the wall about 10 feet +overhead and splashes noisily into the water somewhere within the +mist. There is a passage going back toward the south. -Please answer the question. +> F'UNJ -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +The waters have parted to form a narrow path across the reservoir. -> on +> n + +You are walking across the bottom of the reservoir. Walls of water +rear up on either side. The roar of the water cascading past is +nearly deafening, and the mist is so thick you can barely see. + +> n + +You are at the northern edge of the reservoir. A northwest passage +leads sharply up from here. + +The waters have parted to form a narrow path across the reservoir. + +> nw + +You are scrambling along a treacherously steep, rocky passage. + +> u + +You are on a very steep incline, which widens at it goes upward. + +> u + +You are at the base of a nearly vertical cliff. There are some +slim footholds which would enable you to climb up, but it looks +extremely dangerous. Here at the base of the cliff lie the remains +of several earlier adventurers who apparently failed to make it. + +> u + +You are climbing along a nearly vertical cliff. + +> u + +Just as you reach the top, your foot slips on a loose rock and you +make one last desperate grab. Your luck holds, as does your grip. +With an enormous heave, you lift yourself to the ledge above. + +You are on a small ledge at the top of a nearly vertical cliff. +There is a low crawl leading off to the northeast. -Please answer the question. +> ne + +You have reached a dead end. + +There is a richly-carved ebony statuette here! + +> take ebony + +OK + +> sw + +You're at top of cliff. + +> d + +You are climbing along a nearly vertical cliff. + +> d + +You're at base of cliff. + +> d + +You are on a very steep incline, which widens at it goes upward. + +> d + +You are scrambling along a treacherously steep, rocky passage. + +> d + +You're north of reservoir. + +The waters have parted to form a narrow path across the reservoir. + +> take water + +Your bottle is now full of water. + +> s + +You're at bottom of reservoir. + +> s + +You're at reservoir. + +The waters have parted to form a narrow path across the reservoir. + +> s -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +You are in a north/south canyon about 25 feet across. The floor is +covered by white mist seeping in from the north. The walls extend +upward for well over 100 feet. Suspended from some unseen point far +above you, an enormous two-sided mirror is hanging parallel to and +midway between the canyon walls. (The mirror is obviously provided +for the use of the dwarves who, as you know, are extremely vain.) A +small window can be seen in either wall, some fifty feet up. > s -Please answer the question. +You are in a secret n/s canyon above a large room. + +> d -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +You're in Slab Room. > s -Please answer the question. +You're at west end of Twopit Room. + +The top of a 12-foot-tall beanstalk is poking out of the west pit. -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +> d + +You're in west pit. + +There is a 12-foot-tall beanstalk stretching up out of the pit, +bellowing "WATER!! WATER!!" + +> water plant + +The plant grows explosively, almost filling the bottom of the pit. + +You're in west pit. + +There is a gigantic beanstalk stretching all the way up to the hole. > u -Please answer the question. +You're at west end of Twopit Room. -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +There is a huge beanstalk growing out of the west pit up to the hole. -> take water +> e -Please answer the question. +You are at the east end of the Twopit Room. The floor here is +littered with thin rock slabs, which make it easy to descend the pits. +There is a path here bypassing the pits to connect passages from east +and west. There are holes all over, but the only big one is on the +wall directly over the west pit where you can't get to it. -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +There is a huge beanstalk growing out of the west pit up to the hole. -> throw axe +> d -Please answer the question. +You are at the bottom of the eastern pit in the Twopit Room. There is +a small pool of oil in one corner of the pit. -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +> get oil -> take axe +Your bottle is now full of oil. -Please answer the question. +> u -Oh dear, you seem to have gotten yourself killed. I might be able to -help you out, but I've never really done this before. Do you want me -to try to reincarnate you? +You're at east end of Twopit Room. -> n +There is a huge beanstalk growing out of the west pit up to the hole. + +> w + +You're at west end of Twopit Room. + +There is a huge beanstalk growing out of the west pit up to the hole. + +> d + +You're in west pit. + +There is a gigantic beanstalk stretching all the way up to the hole. + +> climb + +You clamber up the plant and scurry through the hole at the top. + +You are in a long, narrow corridor stretching out of sight to the +west. At the eastern end is a hole through which you can see a +profusion of leaves. + +> w + +You are in the Giant Room. The ceiling here is too high up for your +lamp to show it. Cavernous passages lead east, north, and south. On +the west wall is scrawled the inscription, "FEE FIE FOE FOO" [sic]. + +There is a large nest here, full of golden eggs! + +> n + +You are at one end of an immense north/south passage. + +The way north is barred by a massive, rusty, iron door. + +> oil door + +The oil has freed up the hinges so that the door will now move, +although it requires some effort. + +> drop bottle + +OK + +> drop appendage + +OK + +> n + +You are in a magnificent cavern with a rushing stream, which cascades +over a sparkling waterfall into a roaring whirlpool which disappears +through a hole in the floor. Passages exit to the south and west. + +There is a jewel-encrusted trident here! + +> take trident + +OK + +> w + +You are at the top of a steep incline above a large room. You could +climb down here, but you would not be able to climb up. There is a +passage leading back to the north. + +> d + +You are in a large low room. Crawls lead north, se, and sw. + +> se + +This is the Oriental Room. Ancient oriental cave drawings cover the +walls. A gently sloping passage leads upward to the north, another +passage leads se, and a hands and knees crawl leads west. + +There is a delicate, precious, ming vase here! + +> n + +You are following a wide path around the outer edge of a large cavern. +Far below, through a heavy white mist, strange splashing noises can be +heard. The mist rises up through a fissure in the ceiling. The path +exits to the south and west. + +> w + +You are in an alcove. A small nw path seems to widen after a short +distance. An extremely tight tunnel leads east. It looks like a very +tight squeeze. An eerie light can be seen at the other end. + +> inven + +You are currently holding the following: +Brass lantern +Dwarf's axe +Jeweled trident +Ebony statuette + +> drop trident + +OK + +> drop ebony + +OK + +> drop axe + +OK + +> drop lantern + +OK + +> e + +You're in Plover Room. + +There is an emerald here the size of a plover's egg! + +> take emerald + +OK + +> w + +You're in alcove. + +There is a lamp shining nearby. + +There is a little axe here. + +There is a richly-carved ebony statuette here! + +There is a jewel-encrusted trident here! + +> take lamp + +OK + +> take axe + +OK + +> take ebony + +OK + +> take trident + +OK + +> nw + +You're in misty cavern. + +> s + +You're in Oriental Room. + +There is a delicate, precious, ming vase here! + +> take vase + +OK + +> se + +You are in a room whose walls resemble swiss cheese. Obvious passages +go west, east, ne, and nw. Part of the room is occupied by a large +bedrock block. + +> e + +You are in the Soft Room. The walls are covered with heavy curtains, +the floor with a thick pile carpet. Moss covers the ceiling. + +A small velvet pillow lies on the floor. + +> take pillow + +OK + +> w + +You're in Swiss Cheese Room. + +> ne + +You're in Bedquilt. + +> e + +You are at a complex junction. A low hands and knees passage from the +north joins a higher crawl from the east to make a walking passage +going west. There is also a large room above. The air is damp here. + +> n + +You're in a large room carved out of sedimentary rock. The floor and +walls are littered with bits of shells imbedded in the stone. A +shallow passage proceeds downward, and a somewhat steeper one leads +up. A low hands and knees passage enters from the south. + +There is an enormous clam here with its shell tightly closed. + +> open clam + +A glistening pearl falls out of the clam and rolls away. Goodness, +this must really be an oyster. (I never was very good at identifying +bivalves.) Whatever it is, it has now snapped shut again. + +> s + +You're at complex junction. + +> u + +You are in a large room full of dusty rocks. There is a big hole in +the floor. There are cracks everywhere, and a passage leading east. + +> e + +Out from the shadows behind you pounces a bearded pirate! "Har, har," +he chortles, "I'll just take all this booty and hide it away with me +chest deep in the maze!" He snatches your treasure and vanishes into +the gloom. + +You're in dirty passage. + +> u + +You're in n/s passage above e/w passage. + +> s + +You're in Hall of Mt King. + +> e + +You're in Hall of Mists. + +Rough stone steps lead up the dome. + +> w + +You're on east bank of fissure. + +A three foot black rod with a rusty star on an end lies nearby. + +A crystal bridge now spans the fissure. + +> w + +You're on west bank of fissure. + +A crystal bridge now spans the fissure. + +> w + +You're at west end of Hall of Mists. + +> s + +You are in a maze of twisty little passages, all alike. + +> e + +You are in a maze of twisty little passages, all alike. + +> s + +You are in a maze of twisty little passages, all alike. + +> s + +You are in a maze of twisty little passages, all alike. + +> s + +You are in a maze of twisty little passages, all alike. + +> n + +There are faint rustling noises from the darkness behind you. + +You are in a maze of twisty little passages, all alike. + +> e + +You are on the brink of a thirty foot pit with a massive orange column +down one wall. You could climb down here but you could not get back +up. The maze continues at this level. + +> e + +You are in a maze of twisty little passages, all alike. + +> nw + +Dead end + +There is a richly-carved ebony statuette here! + +There is an emerald here the size of a plover's egg! + +There is a delicate, precious, ming vase here! + +There is a jewel-encrusted trident here! + +The pirate's treasure chest is here! + +> inven + +You are currently holding the following: +Brass lantern +Velvet pillow +Dwarf's axe + +> take vase + +OK + +> take trident + +OK + +> take chest + +OK + +> take emerald + +OK + +> se + +You are in a maze of twisty little passages, all alike. + +> n + +You're at brink of pit. + +> d + +You're in bird chamber. + +> e + +You are in an awkward sloping east/west canyon. + +> e + +You're in debris room. + +> off + +Your lamp is now off. + +It is now pitch dark. If you proceed you will likely fall into a pit. + +> xyzzy + +>>Foof!<< + +You are inside a building, a well house for a large spring. + +There is an enormous ruby here! + +There is a platinum pyramid here, 8 inches on a side! + +There are diamonds here! + +There is a large sparkling nugget of gold here! + +There are bars of silver here! + +There is a persian rug spread out on the floor! + +There is precious jewelry here! + +A precious jade necklace has been dropped here! + +There are some keys on the ground here. + +There is food here. + +> drop chest + +OK + +> drop pillow + +OK + +> drop vase + +The vase is now resting, delicately, on a velvet pillow. + +> drop trident + +OK + +> take keys + +OK + +> take food + +OK + +> plugh + +>>Foof!<< + +It is now pitch dark. If you proceed you will likely fall into a pit. + +> on + +Your lamp is now on. + +You are in a large room, with a passage to the south, a passage to the +west, and a wall of broken rock to the east. There is a large "Y2" on +a rock in the room's center. + +> s + +You're in n/s passage above e/w passage. + +> d + +You're in dirty passage. + +> w + +You're in dusty rock room. + +> d + +You're at complex junction. + +> n + +You're in Shell Room. + +There is an enormous oyster here with its shell tightly closed. + +> d + +You are in a long sloping corridor with ragged sharp walls. + +> d + +You are in a cul-de-sac about eight feet across. + +Off to one side lies a glistening pearl! + +> take pearl + +OK + +> u + +You are in a long sloping corridor with ragged sharp walls. + +> u + +You're in Shell Room. + +There is an enormous oyster here with its shell tightly closed. + +> s + +You're at complex junction. + +> w + +You're in Bedquilt. + +> w + +You're in Swiss Cheese Room. + +> w + +You're at east end of Twopit Room. + +There is a huge beanstalk growing out of the west pit up to the hole. + +> w + +You are at the west end of the Twopit Room. There is a large hole in +the wall above the pit at this end of the room. + +There is a huge beanstalk growing out of the west pit up to the hole. + +> d + +You are at the bottom of the western pit in the Twopit Room. There is +a large hole in the wall about 25 feet above you. + +There is a gigantic beanstalk stretching all the way up to the hole. + +> climb + +You clamber up the plant and scurry through the hole at the top. + +You're in narrow corridor. + +> w + +You're in Giant Room. + +There is a large nest here, full of golden eggs! + +> get eggs + +OK + +> n + +You are at one end of an immense north/south passage. + +Your keen eye spots a severed leporine appendage lying on the ground. + +There is an empty bottle here. + +The way north leads through a massive, rusty, iron door. + +> take bottle + +You can't carry anything more. You'll have to drop something first. + +> pour bottle + +Bottl what? + +> n + +You're in cavern with waterfall. + +> w + +You're at steep incline above large room. + +> d + +You're in large low room. + +> sw + +You are in a long winding corridor sloping out of sight in both +directions. + +> u + +You are on one side of a large, deep chasm. A heavy white mist rising +up from below obscures all view of the far side. A sw path leads away +from the chasm into a winding corridor. + +A rickety wooden bridge extends across the chasm, vanishing into the +mist. A notice posted on the bridge reads, "Stop! Pay troll!" + +A burly troll stands by the bridge and insists you throw him a +treasure before you may cross. + +> attack + +Trolls are close relatives with the rocks and have skin as tough as +that of a rhinoceros. The troll fends off your blows effortlessly. + +> feed troll + +Gluttony is not one of the troll's vices. Avarice, however, is. + +> toss eggs + +The troll catches your treasure and scurries away out of sight. + +> ne + +You are on the far side of the chasm. A ne path leads away from the +chasm on this side. + +A rickety wooden bridge extends across the chasm, vanishing into the +mist. A notice posted on the bridge reads, "Stop! Pay troll!" + +The troll is nowhere to be seen. + +> ne + +You're in a long east/west corridor. A faint rumbling noise can be +heard in the distance. + +> barren + +You are standing at the entrance to a large, barren room. A notice +above the entrance reads: "Caution! Bear in room!" + +> unlock chain + +I see no chain here. + +> in + +You are inside a barren room. The center of the room is completely +empty except for some dust. Marks in the dust lead away toward the +far end of the room. The only exit is the way you came in. + +There is a ferocious cave bear eying you from the far end of the room! + +The bear is locked to the wall with a golden chain! + +> attack bear + +With what? Your bare hands? Against *HIS* bear hands?? + +> throw axe + +The axe misses and lands near the bear where you can't get at it. + +> throw food + +The bear eagerly wolfs down your food, after which he seems to calm +down considerably and even becomes rather friendly. + +> take chain + +The chain is still locked. + +> unlock chain + +The chain is now unlocked. + +> unlock chain + +It was already unlocked. + +> lock chain + +The chain is now locked. + +> lock chain + +It was already locked. + +> unlock chain + +The chain is now unlocked. + +> take bear + +OK + +> inven + +You are currently holding the following: +Set of keys +Brass lantern +Egg-sized emerald +Glistening pearl + +You are being followed by a very large, tame bear. -OK -You scored 115 out of a possible 430, using 123 turns. +You scored 225 out of a possible 430, using 300 turns. -Your score qualifies you as a novice class adventurer. +You may now consider yourself a "Seasoned Adventurer". -To achieve the next higher rating, you need 6 more points. +To achieve the next higher rating, you need 26 more points. diff --git a/tests/lockchain.log b/tests/lockchain.log index a34ef87..befc2f6 100644 --- a/tests/lockchain.log +++ b/tests/lockchain.log @@ -102,6 +102,7 @@ kill machine s s attack +kill ogre n take ruby s