This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| They instruct Copilot to act as a heuristic-based tester and give concrete, actionable feedback for the PR. | |
| 1. General / Master Prompt (use this first for an overview) | |
| You are an expert exploratory tester using the Quality Tree Software Test Heuristics Cheat Sheet (2006). Review the code changes and tests in this pull request. | |
| For every major category in the cheat sheet (Data Type Attacks, Web Tests, Goldilocks, CRUD, Follow the Data, Boundaries/Interruptions, Sequences/Sorting, Configurations, Multi-User, Variable Analysis, State Analysis, Nouns & Verbs, Judgment, Users & Scenarios, Touch Points, etc.), briefly evaluate: | |
| - Does the PR adequately address this heuristic? | |
| - What risks or gaps remain? | |
| - Suggest 2-3 specific test ideas or improvements that would make the change more robust. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| for dataBit in data: | |
| # indent so we know we're in this loop | |
| # Here is where you add the particulars to automate your process | |
| # n | |
| # |\ | or | |
| # _| \-/ic | |
| # / un | |
| # // ~ + \ | |
| # // | | |
| # // \ \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import time | |
| from time import sleep | |
| # we're going to add a delay so we don't overwhelm the system | |
| import os | |
| # we're going to manipulate operating system interfaces | |
| getInput = open('input.text', 'r+') | |
| # variable = opening file('file name', Opens a file for both reading and writing. The file pointer will be at the beginning of the file) | |
| data = getInput.read() # read the data from the open file |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package shelter; | |
| public class Cat { | |
| public static void main(String[] args){ | |
| CatTraits WilliamWallace = new CatTraits(); | |
| // Here we use our get method to find the value of the private variable, privateOwner | |
| System.out.println("William Wallace the cat responds to one master, " + WilliamWallace.getOwner() + "."); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package shelter; | |
| public class Cat { | |
| public static void main(String[] args){ | |
| // Here we use the default options | |
| CatTraits Gambit = new CatTraits(); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class Hello2 { | |
| //static method - notice the "static" keyword | |
| public static void staticScoobyDoo(){ | |
| System.out.println("static scoobyDoo"); | |
| } | |
| //non-static method - notice there's no "static" keyword | |
| public void scoobyDoo(int arg){ | |
| System.out.println("scoobyDoo"); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class Hello{ | |
| //public - scope. Who can see this method? public means anyone can access thru class | |
| //static - is there one instance per application or multiple instances allowed? static means only 1 | |
| //void - return type - void means return nothing | |
| //main - the function/method name. can be anything | |
| //String[] arguments - your menthod params. String[] is the type, arguements is the var name | |
| public static void main(String[]arguments){ | |
| //Program execution begins here | |
| String ret = getHelloWorld(); | |
| Hello instance = new Hello(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package hello_world; | |
| public class HelloWorldMainClass { | |
| public static void main (String[] argv){ | |
| System.out.print("Hello World"); | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var playerLevel = 1; | |
| var playerClass = "none"; | |
| function plutoniumDragon (playerLevel) { | |
| var creatureLevel = 20; | |
| if(playerLevel < 5){ | |
| alert("Plutonium Dragon will not pursue anyone of Level 5 or below."); | |
| } | |
| else if(playerLevel >= creatureLevel){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def initialize(film) | |
| api_key = ENV['SECRET_TOKEN'] | |
| # Convert user input into something we can use in the API | |
| movie = film[0].gsub(/\s/ , "+") | |
| # Use JSON get data | |
| @movieAPIdata = JSON.parse(open("http://api.rottentomatoes.com/api/public/v1.0/movies.json?apikey=#{api_key}&q=#{movie}&page_limit=1").read) | |
| end |
NewerOlder