File tree Expand file tree Collapse file tree 3 files changed +21
-0
lines changed Expand file tree Collapse file tree 3 files changed +21
-0
lines changed Original file line number Diff line number Diff line change 90
90
run : |
91
91
make ${{ matrix.test_chapter }}
92
92
93
+ - name : Save tempdir path to an env var
94
+ if : always()
95
+ shell : bash
96
+ run : |
97
+ TMPDIR_PATH=$(cat .tmpdir.${{ matrix.test_chapter }})
98
+ echo "TMPDIR_PATH=$TMPDIR_PATH" >> $GITHUB_ENV
99
+
100
+ - name : Archive the temp dir
101
+ uses : actions/upload-artifact@v4
102
+ if : always()
103
+ with :
104
+ name : test-source-${{ matrix.test_chapter }}
105
+ path : ${{ env.TMPDIR_PATH }}
106
+
93
107
- name : Archive the built html files
94
108
uses : actions/upload-artifact@v4
95
109
if : always()
98
112
path : |
99
113
*.html
100
114
*.css
115
+
116
+
Original file line number Diff line number Diff line change 42
42
/tech review /
43
43
.vagrant.d
44
44
* .egg-info
45
+ .tmpdir. *
Original file line number Diff line number Diff line change @@ -221,6 +221,7 @@ def fix_interactive_managepy_stuff(actual_text):
221
221
222
222
223
223
class ChapterTest (unittest .TestCase ):
224
+ chapter_name = "override me"
224
225
maxDiff = None
225
226
226
227
def setUp (self ):
@@ -234,6 +235,9 @@ def setUp(self):
234
235
235
236
def tearDown (self ):
236
237
print (f"finished running test in { self .sourcetree .tempdir } " )
238
+ print ("writing tmpdir out to" , f".tmpdir.test_{ self .chapter_name } " )
239
+ with open (f".tmpdir.test_{ self .chapter_name } " , "w" ) as f :
240
+ f .write (str (self .sourcetree .tempdir ))
237
241
self .sourcetree .cleanup ()
238
242
239
243
def parse_listings (self ):
You can’t perform that action at this time.
0 commit comments