Code Monkey home page Code Monkey logo

testevolution's Introduction

TestEvolution

build co-evolution product-test pair dataset(for test case update).

mark一下,现在做的有save_git_log_to_file.py,用git log将项目中的commit内容保存到git_log.txt中。

parse_git_log.py,读取git_log.txt中的信息,保存到parsed_git_log.json文件中。

test中正打算做的,通过commit hash号获取一次commit中修改前和修改后的代码文件,现在已知可以获取commit修改前的文件内容,还已知commit中的修改记录,缺commit修改后的文件内容。

理论上可以自己写代码:修改前内容 + 修改记录 = 修改后内容,但担心可能会遇到一些莫名其妙的问题,我正在寻找是否有现成的工具能够直接实现这个功能。

目前的demo项目是Java项目,使用到了其中的commit hash:05ca93eace893a75e886a19739778a67bd3a18bc

git show [commit hash],获取这一版本代码的内容路径和修改内容

git show [commit hash]:[file_path],获取当前版本修改前的该路径的文件内容

git show [commit hash] -- [file_path],获取当前版本有关该路径文件内容的修改记录

更新:目前解决了获取修改前后代码文件的问题,以Java为例,处理了出来了一部分的正负样本内容。

Java项目存在一些缺陷,为此使用了commons-math项目,就目前观察的输出结果而言, index为7,13,20是明显的正样本,而index为8,9,10是看不出相关性的样本

nrtsearch: positive_output中存在的负样本(前100个):11、12、41、45(待定)、48、58、78、99

apollo: positive_output中存在的负样本(前100个):17、27、57、59、63、69、75、76、77、87、92

jfreechart: positive_output中存在的负样本:6、10、11、12、13、14

testevolution's People

Contributors

yeren66 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.